Skip to content

Commit

Permalink
Add dynamic string info to README
Browse files Browse the repository at this point in the history
  • Loading branch information
sudara authored Dec 6, 2023
1 parent 42af07a commit 9522ca4
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,17 @@ TRACE_EVENT_END ("dsp");

```
### Dynamic Names
Perfetto is optimized to be low overhead, shipping in RELEASE production builds. By default usage is via compile-time strings.
Working with strings dynamically introduces runtime overhead — but hey, sometimes you just want to look at something real quick. For those cases, Perfetto provides a helper:
```
TRACE_EVENT ("dsp", perfetto::DynamicString{my_dynamic_string});
```
### "Solo" the message or audio thread
If you are focusing on UI and want to temporarily rid of the audio thread in the trace, set `PERFETTO_ENABLE_TRACE_DSP=0` in your preprocessor definitions (or just modify the header like I do) and it will be a no-op.
Expand Down

0 comments on commit 9522ca4

Please sign in to comment.