File tree Expand file tree Collapse file tree 10 files changed +5
-132
lines changed Expand file tree Collapse file tree 10 files changed +5
-132
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ All notable changes to this project will be documented in this file.
44
55Next version:
66
7+ - Move ` Backoff ` module to its own ` backoff ` package (@lyrm , @polytypic )
78- Support padding to avoid false sharing (@polytypic )
89- Pass through ` ?timeoutf ` to blocking operations on data structures
910 (@polytypic )
Original file line number Diff line number Diff line change 1111 ( description " A software transactional memory (STM) implementation based on an atomic lock-free multi-word compare-and-set (MCAS) algorithm enhanced with read-only compare operations and ability to block awaiting for changes." )
1212 ( depends
1313 ( ocaml ( >= 4 .13.0) )
14+ ( backoff ( >= 0 .1.0) )
1415 ( domain-local-await ( >= 0 .2.0) )
1516 ( domain-local-timeout ( >= 0 .1.0) )
1617 ( multicore-magic ( >= 1 .0.0) )
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ bug-reports: "https://github.com/ocaml-multicore/kcas/issues"
1515depends: [
1616 "dune" {>= "3.3"}
1717 "ocaml" {>= "4.13.0"}
18+ "backoff" {>= "0.1.0"}
1819 "domain-local-await" {>= "0.2.0"}
1920 "domain-local-timeout" {>= "0.1.0"}
2021 "multicore-magic" {>= "1.0.0"}
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11(library
22 (name kcas)
33 (public_name kcas)
4- (libraries domain-local-await domain-local-timeout multicore-magic))
5-
6- (rule
7- (targets domain.ml)
8- (deps domain.ocaml4.ml)
9- (enabled_if
10- (< %{ocaml_version} 5.0.0))
11- (action
12- (progn
13- (copy domain.ocaml4.ml domain.ml))))
4+ (libraries domain-local-await domain-local-timeout backoff multicore-magic))
145
156(mdx
167 (package kcas)
178 (deps
189 (package kcas))
1910 (preludes kcas.prelude.ml)
20- (libraries kcas domain_shims)
11+ (libraries kcas backoff domain_shims)
2112 (files kcas.mli))
Original file line number Diff line number Diff line change @@ -17,8 +17,6 @@ let fenceless_get = Atomic.get
1717let fenceless_set = Atomic.set
1818*)
1919
20- module Backoff = Backoff
21-
2220module Timeout = struct
2321 exception Timeout
2422
Original file line number Diff line number Diff line change 101101 can skip over these. The documentation links back to these modules where
102102 appropriate. *)
103103
104- module Backoff : module type of Backoff
105-
106104(* * Timeout support. *)
107105module Timeout : sig
108106 exception Timeout
Original file line number Diff line number Diff line change @@ -348,18 +348,6 @@ let test_post_commit () =
348348
349349(* *)
350350
351- let test_backoff () =
352- let b = Backoff. create ~lower_wait_log: 5 ~upper_wait_log: 6 () in
353- assert (Backoff. get_wait_log b = 5 );
354- let b = Backoff. once b in
355- assert (Backoff. get_wait_log b = 6 );
356- let b = Backoff. once b in
357- assert (Backoff. get_wait_log b = 6 );
358- let b = Backoff. reset b in
359- assert (Backoff. get_wait_log b = 5 )
360-
361- (* *)
362-
363351let test_blocking () =
364352 let state = Loc. make `Spawned in
365353 let await state' =
@@ -674,7 +662,6 @@ let () =
674662 [ Alcotest. test_case " " `Quick test_presort_and_is_in_log_xt ] );
675663 (" updates" , [ Alcotest. test_case " " `Quick test_updates ]);
676664 (" post commit" , [ Alcotest. test_case " " `Quick test_post_commit ]);
677- (" backoff" , [ Alcotest. test_case " " `Quick test_backoff ]);
678665 (" blocking" , [ Alcotest. test_case " " `Quick test_blocking ]);
679666 ( " no unnecessary wakeups" ,
680667 [ Alcotest. test_case " " `Quick test_no_unnecessary_wakeups ] );
You can’t perform that action at this time.
0 commit comments