biglybt: 3.5.0.0 -> 3.6.0.0
[NixPkgs.git] / pkgs / development / ocaml-modules / hack_parallel / hack_parallel.patch
blob174803a348182ca32ca7d27b5c3fbf72cec0f3bd
1 diff --git a/src/heap/sharedMem.ml b/src/heap/sharedMem.ml
2 index 600e272..511b724 100644
3 --- a/src/heap/sharedMem.ml
4 +++ b/src/heap/sharedMem.ml
5 @@ -521,7 +521,7 @@ end = struct
7 let stack: t option ref = ref None
9 - let has_local_changes () = Core_kernel.Option.is_some (!stack)
10 + let has_local_changes () = Core.Option.is_some (!stack)
12 let rec mem stack_opt key =
13 match stack_opt with
14 diff --git a/src/interface/memory.ml b/src/interface/memory.ml
15 index 3554b17..09aa1f5 100644
16 --- a/src/interface/memory.ml
17 +++ b/src/interface/memory.ml
18 @@ -66,10 +66,10 @@ let get_heap_handle () =
21 let heap_use_ratio () =
22 - Core_kernel.Float.of_int (SharedMemory.heap_size ()) /.
23 - Core_kernel.Float.of_int initial_heap_size
24 + Core.Float.of_int (SharedMemory.heap_size ()) /.
25 + Core.Float.of_int initial_heap_size
28 let slot_use_ratio () =
29 let { SharedMemory.used_slots; slots; _ } = SharedMemory.hash_stats () in
30 - Core_kernel.Float.of_int used_slots /. Core_kernel.Float.of_int slots
31 + Core.Float.of_int used_slots /. Core.Float.of_int slots
32 diff --git a/src/interface/scheduler.ml b/src/interface/scheduler.ml
33 index 9b8282a..b5d41b5 100644
34 --- a/src/interface/scheduler.ml
35 +++ b/src/interface/scheduler.ml
36 @@ -48,7 +48,7 @@ let map_reduce
37 | Some exact_size when exact_size > 0 ->
38 (List.length work / exact_size) + 1
39 | _ ->
40 - let bucket_multiplier = Core_kernel.Int.min bucket_multiplier (1 + (List.length work / 400)) in
41 + let bucket_multiplier = Core.Int.min bucket_multiplier (1 + (List.length work / 400)) in
42 number_of_workers * bucket_multiplier
44 MultiWorker.call
45 diff --git a/src/utils/dune b/src/utils/dune
46 index 50a4c42..45e4a5a 100644
47 --- a/src/utils/dune
48 +++ b/src/utils/dune
49 @@ -15,6 +15,7 @@
50 sysinfo)
51 (libraries
52 core
53 + core_unix
54 str
55 hack_parallel.collections
56 hack_parallel.disk
57 diff --git a/src/utils/hh_logger.ml b/src/utils/hh_logger.ml
58 index 4c99f05..8075ed5 100644
59 --- a/src/utils/hh_logger.ml
60 +++ b/src/utils/hh_logger.ml
61 @@ -9,6 +9,7 @@
64 open Core
65 +module Unix = Core_unix
67 let timestamp_string () =
68 let open Unix in