Closed Bug 1562604 Opened 1 year ago Closed 5 months ago

[meta] Store markers and their payloads in ProfileBuffer

Categories

(Core :: Gecko Profiler, task, P2)

task

Tracking

()

RESOLVED FIXED
Tracking Status
firefox69 --- affected

People

(Reporter: gerald, Assigned: gerald)

References

(Depends on 1 open bug, Blocks 3 open bugs)

Details

(Keywords: meta)

Markers and their payloads are stored outside of the ProfileBuffer:

  1. They are allocated on the heap,
  2. They are initially attached to a list in thread local storage (TLS),
  3. They are moved to a list in ProfileBuffer during sampling, and a marker entry is added to the ProfileBuffer buffer,
  4. They need to be deleted if the ProfileBuffer entry has lapsed.

We should store markers and their payloads directly into the main ProfileBuffer buffer:
1 -> We would avoid external mallocs (using extra memory and CPU resources).
2 -> No need to manage markers in TLS memory.
3 -> No need to manage markers linked list in ProfileBuffer, and during sampling.
4 -> No need to manage marker lifetimes, their data would just get overwritten.

See details in bug 1549572 comment #6 about the proposed data structure.
This should also help separate marker storage from sampling needed for bug 1549482.

Depends on: 1562606
Depends on: 1563425
Depends on: 1565137
Depends on: 1566706
Depends on: 1567461
Depends on: 1567465
Depends on: 1567861
Depends on: 1569458
Depends on: 1571348
Depends on: 1571355
Depends on: 1571390
Depends on: 1571392
Depends on: 1572027
Depends on: 1573111
Depends on: 1574143
Depends on: 1574821
Depends on: 1574822
Depends on: 1574824
Depends on: 1574825
Depends on: 1574896
Depends on: 1575141
Depends on: 1575158
Depends on: 1575442
Depends on: 1575448
Depends on: 1575453
Depends on: 1576550
Depends on: 1576551
Depends on: 1576554
Depends on: 1576555
Depends on: 1578327
Depends on: 1578329
Depends on: 1580091
Depends on: 1581049
Depends on: 1582319
Depends on: 1582992

As of bug 1576555, we now store markers and their payloads directly into the ProfileBuffer storage, so this meta bug for the implementation is effectively done.

(There may still be dependencies to deal with bugs, more testing, and maintenance...)

Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Depends on: 1586618
You need to log in before you can comment on or make changes to this bug.