File tree Expand file tree Collapse file tree 7 files changed +8
-7
lines changed
Expand file tree Collapse file tree 7 files changed +8
-7
lines changed Original file line number Diff line number Diff line change 4141 default: https://github.com/ocaml/opam-repository.git
4242 cache-prefix : ${{ steps.multicore_hash.outputs.commit }}
4343
44- - run : opam install . --deps-only
44+ - run : opam install . --deps-only --with-test
4545
4646 - run : opam exec -- make all
4747
Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ depends: [
1212 "base-domains"
1313 "ocamlfind" {build}
1414 "dune" {build}
15+ "mirage-clock-unix" {with-test}
1516]
1617depopts: []
1718build: [
Original file line number Diff line number Diff line change @@ -149,7 +149,7 @@ let rec recv_poll_repeated mchan dls repeats =
149149 | Exit ->
150150 if repeats = 1 then raise Exit
151151 else begin
152- Domain.Sync. cpu_relax () ;
152+ Domain. cpu_relax () ;
153153 recv_poll_repeated mchan dls (repeats - 1 )
154154 end
155155
Original file line number Diff line number Diff line change @@ -75,7 +75,7 @@ let rec await pool promise =
7575 | Task (t , p ) -> do_task t p
7676 | Quit -> raise TasksActive
7777 with
78- | Exit -> Domain.Sync. cpu_relax ()
78+ | Exit -> Domain. cpu_relax ()
7979 end ;
8080 await pool promise
8181 | Some (Ok v ) -> v
Original file line number Diff line number Diff line change @@ -189,7 +189,7 @@ module M : S = struct
189189 if Atomic. compare_and_set q.top t (t + 1 ) then
190190 release out
191191 else begin
192- Domain.Sync. cpu_relax () ;
192+ Domain. cpu_relax () ;
193193 steal q
194194 end
195195
Original file line number Diff line number Diff line change 5959
6060(test
6161 (name task_throughput)
62- (libraries domainslib)
62+ (libraries domainslib mirage-clock-unix )
6363 (modules task_throughput)
6464 (modes native))
6565
Original file line number Diff line number Diff line change @@ -54,9 +54,9 @@ let _ =
5454
5555 let hist = TimingHist. make 5 25 in
5656 for _ = 1 to n_iterations do
57- let t0 = Domain. timer_ticks () in
57+ let t0 = Mclock. elapsed_ns () in
5858 T. parallel_for pool ~start: 1 ~finish: n_tasks ~body: (fun _ -> () );
59- let t = Int64. sub (Domain. timer_ticks () ) t0 in
59+ let t = Int64. sub (Mclock. elapsed_ns () ) t0 in
6060 TimingHist. add_point hist (Int64. to_int t);
6161 done ;
6262
You can’t perform that action at this time.
0 commit comments