A simple intrusive profiler that exports to perfetto.
To use this package, run the following command in your project's root directory:
Put the following dependency into your project's dependences section:
Profile dlang apps with [[https://ui.perfetto.dev][perfetto]]. Implements the json [[https://docs.google.com/document/d/1CvAClvFfyA5R-PhYUmn5OOQtYMH4h6I0nSsKchNAySU/edit#heading=h.lpfof2aylapb][Trace Event Format]] usable with perfetto.
- initialize =theProfiler= global variable
- augment your code with calls to =auto profileEvent = theProfiler.start=. The profetto event will last as long as profileEvent stays in the scope. Adding the event is threadsafe.
- Dump json at the end of the program or whenever you are interested with =theProfiler.dumpJson=.
** Screenshot #+CAPTION: Example perfetto view #+NAME: trace [[./screenshots/trace.png]]
- Registered by Christian Köstlin
- 0.0.2 released 5 months ago
- Copyright (c) 2022, Christian Koestlin