Skip to content

Commit

Permalink
Merge pull request #546 from ocaml/fix_mpr7228
Browse files Browse the repository at this point in the history
Avoid overflow on 32-bit architectures causing bad GC behavior
  • Loading branch information
damiendoligez committed Apr 18, 2016
2 parents 9b8f068 + ca41a86 commit 9642c70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion byterun/major_gc.c
Expand Up @@ -755,7 +755,7 @@ void caml_major_collection_slice (intnat howmuch)
}

if (caml_gc_phase == Phase_mark || caml_gc_phase == Phase_clean){
computed_work = (intnat) (p * (caml_stat_heap_wsz * 250
computed_work = (intnat) (p * ((double) caml_stat_heap_wsz * 250
/ (100 + caml_percent_free)
+ caml_incremental_roots_count));
}else{
Expand Down

0 comments on commit 9642c70

Please sign in to comment.