Deduplicate ProfileJSONWriter
Categories
(Core :: Gecko Profiler, task, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox81 | --- | fixed |
People
(Reporter: mozbugz, Assigned: mozbugz)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
We have both "BaseProfileJSONWriter.h" and "ProfileJSONWriter.h" that contain the same code.
Assignee | ||
Comment 1•5 years ago
|
||
Because this header will be used across libraries, it is simpler to make it fully self-contained instead of using MFBT_API.
Assignee | ||
Comment 2•5 years ago
|
||
The main change is removing ProfileJSONWriter.cpp, making ProfileJSONWriter.h point at BaseProfileJSONWriter.h, and exposing mozilla::baseprofiler::
classes in the top namespace as expected by users of ProfileJSONWriter.h (to minimize changes).
These two headers are now always present in the "mozilla" include directory, independent of MOZ_GECKO_PROFILER settings.
The rest is just needed tweaks to match the above changes.
Depends on D86503
Assignee | ||
Comment 3•5 years ago
|
||
SpliceableChunkedJSONWriter::WriteFunc was hiding base-class non-virtual JSONWriter::WriteFunc(), which made it less than ideal (for me) to reason with.
Also made SpliceableChunkedJSONWriter final, to help with possible devirtualization.
Depends on D86504
Comment 5•5 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/801e1d8c1de0
https://hg.mozilla.org/mozilla-central/rev/7ae81a4ff37e
https://hg.mozilla.org/mozilla-central/rev/61871a38eb0f
Description
•