Open Bug 1640987 Opened 4 years ago Updated 2 years ago

Simplify stack serialization

Categories

(Core :: Gecko Profiler, task, P2)

task

Tracking

()

People

(Reporter: gregtatum, Unassigned)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [fxp])

Right now the stacks are exported as if they are a new thread for every marker. This is very heavy handed. Markers should be emitted as an index into the stack table, and a timestamp of when the stack was taken. The reason for a timestamp is that a marker created at a point of time could be referring to some cause at a point back in time.

https://searchfox.org/mozilla-central/rev/7dafc35406b9c945189c617d427f5458933fd3fb/tools/profiler/core/ProfilerMarkerPayload.cpp#154

This will need a profile upgrader.

Priority: -- → P2

Update post 2022 Toronto work-week:
This would help with profiles getting bigger these days, with many more markers than previously.

The link in comment 0 is obsolete, marker stacks are now written from https://searchfox.org/mozilla-central/rev/170f06a720ddabee44c728b05ad30b18b066acca/mozglue/baseprofiler/public/BaseProfilerMarkersDetail.h#384

Blocks: 1329219
Severity: -- → N/A

Examining one profile, I estimated that we could save more than 30% of space by reducing stacks in markers to the minimal amount of data (timestamp, tid, stack index). So this would certainly help a lot!

You need to log in before you can comment on or make changes to this bug.