profiled 0.0.2

A simple intrusive profiler that exports to perfetto.


To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

  • Profiled

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.

** Usage

  • 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]]

Authors:
  • Christian Koestlin
Dependencies:
none
Versions:
0.0.2 2022-Sep-27
0.0.1 2022-Sep-24
~main 2022-Sep-27
Show all 3 versions
Download Stats:
  • 0 downloads today

  • 0 downloads this week

  • 2 downloads this month

  • 6 downloads total

Score:
0.3
Short URL:
profiled.dub.pm