The SBModule copy constructor has fast execution, and is high firing. Fast and
frequent functions are not good candidates for timers.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
There's two issues with this patch:
- LLDB_INSTRUMENT_VA is not the same as LLDB_SCOPED_TIMER. It's used for logging and tracks ABI boundaries. This breaks boundary tracking.
- Next time someone runs lldb-instr on this file, the tool will just add this again.
If we want to avoid the overhead from the timer, we'll need to adjust the macro.
Comment Actions
What about adding a trivial parameter to the macro that has the effect of skipping it in instrumentation if the instrumentation is the costly signpost mechanism?
Comment Actions
The _VA macro is variadic so you'd have to define a new macro, but yeah that's the idea. As discussed offline with Dave, we probably never want timers/signposts for constructors. My suggestion is to re-instrument all constructors with that new "trivial" macro. During the reproducer era constructs required different macros, so there should be code in lldb-instr that can already tell the two apart.