Expose some more layout frame labels to javascript developers
Categories
(Core :: Gecko Profiler, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox104 | --- | fixed |
People
(Reporter: julienw, Assigned: julienw)
Details
Attachments
(2 files)
I noticed that some layout frame labels were not exposed to JS developers. I missed them while working on bug 1752861.
Assignee | ||
Comment 1•2 years ago
|
||
In my current patches I changed one occurrence of LAYOUT_StyleComputation
and one of LAYOUT_CSSParsing
.
I also see a non-relevant for JS LAYOUT_FrameConstruction
in:
https://searchfox.org/mozilla-central/source/layout/base/nsCSSFrameConstructor.cpp#7009-7010
But I'm not sure how to change the name to make it web-developer friendly. I'm not sure this level of details is useful to web developer, but the fact that we're doing layout and seeing this n the call tree probably is. In that case we could add another frame label that could be simply Layout higher in the call chain.
Emilio, by chance, would you have good suggestions?
Assignee | ||
Comment 2•2 years ago
|
||
I also see this one in profiles: https://searchfox.org/mozilla-central/source/layout/base/PresShell.cpp#1194
But I don't know what this does.
Assignee | ||
Comment 3•2 years ago
|
||
(In reply to Julien Wajsberg [:julienw] from comment #1)
In my current patches I changed one occurrence of
LAYOUT_StyleComputation
and one ofLAYOUT_CSSParsing
.I also see a non-relevant for JS
LAYOUT_FrameConstruction
in:
https://searchfox.org/mozilla-central/source/layout/base/nsCSSFrameConstructor.cpp#7009-7010But I'm not sure how to change the name to make it web-developer friendly. I'm not sure this level of details is useful to web developer, but the fact that we're doing layout and seeing this n the call tree probably is. In that case we could add another frame label that could be simply Layout higher in the call chain.
Emilio, by chance, would you have good suggestions?
Ah, maybe nsContentSink::StartLayout (https://searchfox.org/mozilla-central/source/dom/base/nsContentSink.cpp#520-522)
could be replaced by just Layout and make it Relevant for JS.
Assignee | ||
Comment 4•2 years ago
|
||
Here is a profile I try to make better: https://share.firefox.dev/3AcAf8s
Assignee | ||
Comment 5•2 years ago
|
||
(In reply to Julien Wajsberg [:julienw] from comment #2)
I also see this one in profiles: https://searchfox.org/mozilla-central/source/layout/base/PresShell.cpp#1194
But I don't know what this does.
Could the label frame PresShell::Destroy be replaced by LAYOUT_Cleanup (new sub-category to be created)?
Assignee | ||
Comment 6•2 years ago
|
||
Updated•2 years ago
|
Assignee | ||
Comment 7•2 years ago
|
||
The existing frame label was reusing the function name, but we already
have it when using native stacks. Renaming it to a more understandable
name should make it easier for our javascript developers users without
impairing gecko developers.
Depends on D150757
Comment 8•2 years ago
|
||
Sorry for the lag, I was on PTO. Frame construction == "layout box construction" maybe? Anyways will look at the patch asap.
Pushed by jwajsberg@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/7ed1a7a9d0fa Expose some more layout frame labels to javascript developers r=emilio https://hg.mozilla.org/integration/autoland/rev/4e13fa2ff101 Rename the frame label for PresShell::Destroy and expose to javascript developers r=emilio
Comment 10•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/7ed1a7a9d0fa
https://hg.mozilla.org/mozilla-central/rev/4e13fa2ff101
Description
•