Closed Bug 1752861 Opened 3 years ago Closed 3 years ago

Set the flag "relevant for js" on existing label frames and add new ones for JavaScript developers

Categories

(Core :: Gecko Profiler, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
Tracking Status
firefox99 --- fixed

People

(Reporter: julienw, Assigned: julienw)

References

(Blocks 1 open bug)

Details

Attachments

(3 files, 1 obsolete file)

I noticed some label frames could be useful to show in the "javascript" tree, such as "Style Computation". Then thanks to Markus I realized that a full class of label frames could be interesting to show: the ones using their subcategory as their label. Indeed these labels should be human readable and most of the time interesting to javascript developers.

We can try to turn them on all first. If the result is that we have too many label unrelevant label frames, we could come up with different macros for these cases.

Here is a profile example: https://share.firefox.dev/3ALx5qo

After discussion we need to be more fine-grained, therefore come up with new macros so that some of them would be relevant for JS but others wouldn't.

Assignee: nobody → felash
Severity: -- → N/A
Priority: -- → P3

Here are the main "blocks" that web developers expect to see: JavaScript / Style / Layout / Paint / Composite.
(From https://developers.google.com/web/fundamentals/performance/rendering)

We could have different labels and maybe a few more blocks (or rather sub-parts of them) but this should be as simple.

Summary: Set the flag "relevant for js" on label frames that have the flag "LABEL_DETERMINED_BY_CATEGORY_PAIR" → Set the flag "relevant for js" on existing label frames and add new ones for JavaScript developers
Attachment #9261552 - Attachment is obsolete: true

Here is an example of a profile with the new patches: https://share.firefox.dev/3KkgbTc
This is a profile of the profiler UI.
As a comparison, the same scenario on the current Nightly: https://share.firefox.dev/3ty1WDx

Another example on loading a page on leboncoin.fr:

My approach has been that I didn't want any category to disappear from the activity graph or the flame chart, focusing on when this is useful for web developers. For example I added a frame label for GC happening in Web page but not for the GC happening after clicking on the button in about:memory. It's likely that I missed some cases that we'll be able to add later too.

Attachment #9266572 - Attachment description: WIP: Bug 1752861 - [profiler] Add a few new macros to add frame labels that will show up in javascript stacks r=gerald → Bug 1752861 - [profiler] Add a few new macros to add frame labels that will show up in javascript stacks r=gerald
Attachment #9266573 - Attachment description: WIP: Bug 1752861 - [profiler] Rename and expose to JS some existing frame labels as well as adding a few r=gerald!,mstange! → Bug 1752861 - [profiler] Rename and expose to JS some existing frame labels as well as adding a few r=gerald!,mstange!
Attachment #9266574 - Attachment description: WIP: Bug 1752861 - [profiler] Expose GC and CC operations to the JS view r=gerald!,sfink! → Bug 1752861 - [profiler] Expose GC and CC operations to the JS view r=gerald!,sfink!

I'm gonna add a few more things later too.

Keywords: leave-open

Comment on attachment 9266574 [details]
Bug 1752861 - [profiler] Expose GC and CC operations to the JS view r=gerald!,sfink!

Beta/Release Uplift Approval Request

  • User impact if declined: These patches add useful information to JavaScript developers using the profiler. It would be good to have that in beta earlier.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): This doesn't change the behavior for users that don't use the profiler.
    For users of the profiler, this is adding some information and removing other, but nothing is risky here.
  • String changes made/needed:
Attachment #9266574 - Flags: approval-mozilla-beta?
Attachment #9266572 - Flags: approval-mozilla-beta?
Attachment #9266573 - Flags: approval-mozilla-beta?
Pushed by jwajsberg@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/8e224b84b277 [profiler] Add a few new macros to add frame labels that will show up in javascript stacks r=gerald https://hg.mozilla.org/integration/autoland/rev/90ef854bcaf7 [profiler] Rename and expose to JS some existing frame labels as well as adding a few r=mstange https://hg.mozilla.org/integration/autoland/rev/16794e0d61b7 [profiler] Expose GC and CC operations to the JS view r=sfink,smaug

Comment on attachment 9266572 [details]
Bug 1752861 - [profiler] Add a few new macros to add frame labels that will show up in javascript stacks r=gerald

Approved for 99.0b4. Thanks.

Attachment #9266572 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Comment on attachment 9266573 [details]
Bug 1752861 - [profiler] Rename and expose to JS some existing frame labels as well as adding a few r=gerald!,mstange!

Approved for 99.0b4. Thanks.

Attachment #9266573 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Comment on attachment 9266574 [details]
Bug 1752861 - [profiler] Expose GC and CC operations to the JS view r=gerald!,sfink!

Approved for 99.0b4. Thanks.

Attachment #9266574 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

:julienw - could this bug be closed and used to only track the uplifts?
Track any follow-up work in separate bugs.

Flags: needinfo?(felash)

Sure, let's do that. Thanks for the feedback!

Flags: needinfo?(felash)
Status: NEW → RESOLVED
Closed: 3 years ago
Keywords: leave-open
Resolution: --- → FIXED
Blocks: 1329161
See Also: → 1442665
See Also: → 1749521
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: