Skip to content

Commit

Permalink
Record trace event when spawning processes
Browse files Browse the repository at this point in the history
This can take quite a long time.
  • Loading branch information
talex5 committed Aug 8, 2024
1 parent 33d4e01 commit 05fae4e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib_eio_linux/low_level.ml
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,10 @@ module Process = struct
let exit_status, set_exit_status = Promise.create () in
let t =
Fd.use_exn "errors-w" errors_w @@ fun errors_w ->
let pid, pid_fd = eio_spawn errors_w c_actions in
let pid, pid_fd =
Eio.Private.Trace.with_span "spawn" @@ fun () ->
eio_spawn errors_w c_actions
in
let pid_fd = Fd.of_unix ~sw ~seekable:false ~close_unix:true pid_fd in
{ pid; pid_fd; exit_status }
in
Expand Down

0 comments on commit 05fae4e

Please sign in to comment.