diff --git a/coverage/index.html b/coverage/index.html
index 3e8ce78a..583692ca 100644
--- a/coverage/index.html
+++ b/coverage/index.html
@@ -419,9 +419,9 @@
-
+
-
87% (28 / 32)
+
88% (30 / 34)
src/data_structures/synchronizer.ml
@@ -430,7 +430,7 @@
77.17%
-
100% (16 / 16)
+
100% (14 / 14)
src/data_structures/wq.ml
diff --git a/coverage/src/ast/types.ml.html b/coverage/src/ast/types.ml.html
index 5008f194..49661e41 100644
--- a/coverage/src/ast/types.ml.html
+++ b/coverage/src/ast/types.ml.html
@@ -2303,8 +2303,8 @@
48.51%
|
F64 -> pf fmt "f64"
let num_type_eq t1 t2 =
-
match (t1, t2) with
- |
I32, I32 |
I64, I64 |
F32, F32 |
F64, F64 -> true
+
match (t1, t2) with
+ |
I32, I32 |
I64, I64 |
F32, F32 |
F64, F64 -> true
|
_, _ -> false
let compare_num_type t1 t2 =
@@ -2604,8 +2604,8 @@
48.51%
|
Ref_type t -> pp_ref_type fmt t
let val_type_eq t1 t2 =
-
match (t1, t2) with
- |
Num_type t1, Num_type t2 -> num_type_eq t1 t2
+
match (t1, t2) with
+ |
Num_type t1, Num_type t2 -> num_type_eq t1 t2
|
Ref_type t1, Ref_type t2 -> ref_type_eq t1 t2
|
_, _ -> false
@@ -2620,7 +2620,7 @@
48.51%
let pp_param fmt (id, vt) =
pf fmt "(param%a %a)" pp_id_opt id pp_val_type vt
-let param_eq (_, t1) (_, t2) =
val_type_eq t1 t2
+let param_eq (_, t1) (_, t2) =
val_type_eq t1 t2
let compare_param (_, t1) (_, t2) =
compare_val_type t1 t2
@@ -2628,7 +2628,7 @@
48.51%
let pp_param_type fmt params =
list ~sep:sp pp_param fmt params
-let param_type_eq t1 t2 =
List.equal param_eq t1 t2
+let param_type_eq t1 t2 =
List.equal param_eq t1 t2
let compare_param_type t1 t2 =
List.compare compare_param t1 t2
@@ -2638,7 +2638,7 @@
48.51%
let pp_result_type fmt results =
list ~sep:sp pp_result_ fmt results
-let result_type_eq t1 t2 =
List.equal val_type_eq t1 t2
+let result_type_eq t1 t2 =
List.equal val_type_eq t1 t2
let compare_result_type t1 t2 =
List.compare compare_val_type t1 t2
@@ -2677,7 +2677,7 @@
48.51%
results
let func_type_eq (pt1, rt1) (pt2, rt2) =
-
param_type_e
q pt1 pt2 &&
result_type_eq rt1 rt2
+
param_type_e
q pt1 pt2 &&
result_type_eq rt1 rt2
let compare_func_type (pt1, rt1) (pt2, rt2) =
let pt = compare_param_type pt1 pt2 in
diff --git a/coverage/src/cmd/cmd_sym.ml.html b/coverage/src/cmd/cmd_sym.ml.html
index e817d549..cf9ae3d1 100644
--- a/coverage/src/cmd/cmd_sym.ml.html
+++ b/coverage/src/cmd/cmd_sym.ml.html
@@ -369,10 +369,10 @@
90.22%
let res_queue = Wq.make () in
let path_count = ref 0 in
let callback v =
-
let open Symbolic_choice_intf in
+
let open Symbolic_choice_intf in
incr path_count;
-
match (fail_mode, v) with
- |
_, (EVal (Ok ()), _) -> ()
+
match (fail_mode, v) with
+ |
_, (EVal (Ok ()), _) -> ()
|
_, (EVal (Error e), thread) -> Wq.push (`Error e, thread) res_queue
|
(`Both |
`Trap_only), (ETrap (t, m), thread) ->
Wq.push (`ETrap (t, m), thread) res_queue
diff --git a/coverage/src/data_structures/env_id.ml.html b/coverage/src/data_structures/env_id.ml.html
index 42d2404a..22b3877d 100644
--- a/coverage/src/data_structures/env_id.ml.html
+++ b/coverage/src/data_structures/env_id.ml.html
@@ -112,14 +112,14 @@
77.78%
let last = succ last in
({ c; last }, r)
-let get i c =
Map.find i c.c
+let get i c =
Map.find i c.c
let map f c =
{ c with c = Map.ma
p f c.c }
module Tbl = Hashtbl.Make (struct
include Int
- let hash x =
x
+ let hash x =
x
end)
diff --git a/coverage/src/data_structures/func_id.ml.html b/coverage/src/data_structures/func_id.ml.html
index 61c01df0..d9aef144 100644
--- a/coverage/src/data_structures/func_id.ml.html
+++ b/coverage/src/data_structures/func_id.ml.html
@@ -105,8 +105,8 @@
@@ -74,7 +74,7 @@
87.50%
-
+
@@ -182,22 +182,22 @@
87.50%
}
let get synchro pledge =
-
let rec inner_loop synchro pledge =
-
match synchro.getter () with
- |
None when synchro.pledges =
0 || synchro.close
d ->
-
Condition.broadcast synchro.cond;
-
None
- |
None ->
+
let rec inner_loop synchro pledge =
+
match synchro.getter () with
+ |
None when synchro.pledges =
0 || synchro.close
d ->
+
Condition.broadcast synchro.cond;
+
None
+ |
None ->
Condition.wait synchro.cond synchro.mutex;
-
inner_loop synchro pledge
- |
Some _ as v ->
- if pledge then
synchro.pledges <- synchro.pledges + 1;
-
v
+
inner_loop synchro pledge
+ |
Some _ as v ->
+ if pledge then
synchro.pledges <- synchro.pledges + 1;
+
v
in
- Mutex.protect synchro.mutex (fun () ->
inner_loop synchro pledge)
+ Mutex.protect synchro.mutex (fun () ->
inner_loop synchro pledge)
let write v { writter; cond; mutex; _ } =
-
Mutex.protect mutex (fun () ->
writter v cond)
+
Mutex.protect mutex (fun () ->
writter v cond)
let make_pledge synchro =
Mutex.lock synchro.mutex;
@@ -205,10 +205,10 @@
87.50%
Mutex.unlock synchro.mutex
let end_pledge synchro =
-
Mutex.lock synchro.mutex;
-
synchro.pledges <- synchro.pledges - 1;
- Condition.broadcast synchro.cond;
-
Mutex.unlock synchro.mutex
+
Mutex.lock synchro.mutex;
+
synchro.pledges <- synchro.pledges - 1;
+ if Int.equal synchro.pledges 0 then
Condition.broadcas
t synchro.cond;
+
Mutex.unlock synchro.mutex
let fail q =
Mutex.lock q.mutex;
@@ -217,12 +217,12 @@
87.50%
Mutex.unlock q.mutex
let rec work_while f q =
-
match get q true with
- |
None -> ()
- |
Some v ->
- let () = f v (fun v ->
write v q) in
-
end_pledge q;
-
work_while f q
+
match get q true with
+ |
None -> ()
+ |
Some v ->
+ let () = f v (fun v ->
write v q) in
+
end_pledge q;
+
work_while f q
diff --git a/coverage/src/data_structures/wq.ml.html b/coverage/src/data_structures/wq.ml.html
index a5feebbd..6ebcc6f8 100644
--- a/coverage/src/data_structures/wq.ml.html
+++ b/coverage/src/data_structures/wq.ml.html
@@ -53,9 +53,8 @@
@@ -93,7 +92,6 @@
100.00%
31
32
33
-
34
(* SPDX-License-Identifier: AGPL-3.0-or-later *)
(* Copyright © 2021-2024 OCamlPro *)
@@ -117,18 +115,17 @@ 100.00%
let push v q = Synchronizer.write v q
-let work_while f q = Synchronizer.work_while f q
+let work_while f q = Synchronizer.work_while f q
let fail = Synchronizer.fail
let make () =
let q = Queue.create () in
let writter v condvar =
- let was_empty = Queue.is_empty q in
- Queue.push v q;
- if was_empty then Condition.broadcast condvar
+ Queue.push v q;
+ Condition.signal condvar
in
- Synchronizer.init (fun () -> Queue.take_opt q) writter
+ Synchronizer.init (fun () -> Queue.take_opt q) writter
diff --git a/coverage/src/interpret/interpret.ml.html b/coverage/src/interpret/interpret.ml.html
index 84a32279..48f33337 100644
--- a/coverage/src/interpret/interpret.ml.html
+++ b/coverage/src/interpret/interpret.ml.html
@@ -3253,7 +3253,7 @@