ocaml-multicore / eio

Effects-based direct-style IO for multicore OCaml
Other
529 stars 67 forks source link

Tracing: add labels to switches #661

Closed talex5 closed 7 months ago

talex5 commented 7 months ago

This makes the traces easier to read. Here's the network example with the new labels:

switch

I also modified Net.run_server to use one fewer switch, to clean up the trace.

Part of #649.

SGrondin commented 7 months ago

Would it be less ambiguous to use the label Fiber.List.all instead of just all, for example? If the rendered image looks too cluttered maybe it's something visualization tools could choose to truncate to all themselves?

talex5 commented 7 months ago

It's just Fiber.all in this case. My guess is that a collection of fibers tagged "all" will be clear enough, but we'll have to get some experience with larger traces to be sure.