Open Bug 1810788 Opened 3 years ago Updated 5 months ago

JS demo (https://www.fxhash.xyz/generative/slug/7.356-degrees) is massively faster in Chrome compared to Nightly

Categories

(Core :: JavaScript Engine: JIT, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: mayankleoboy1, Unassigned)

References

(Blocks 1 open bug, )

Details

Looking at the profiles, I would have expected the opposite. The biggest offender in Chrome seems to be the CheckValidity function which is taking 13%, while taking only 3% in Firefox …

The frame being pointed at in the Firefox profile is some thread waiting time, at the beginning and end of the profile.

Jan, would you have a different conclusion?

Flags: needinfo?(jdemooij)

(In reply to Nicolas B. Pierron [:nbp] from comment #1)

Looking at the profiles, I would have expected the opposite. The biggest offender in Chrome seems to be the CheckValidity function which is taking 13%, while taking only 3% in Firefox …

The Chrome profile is only from the first 10 seconds or so. When I tried taking longer profiles (i.e. for the whole duration of time while the demo renders), Chrome gave me empty profiles.

My interpretatin of "massively" faster was based on the wall-clock time it takes for the demo to render completely.

Nightly took 61 seconds
Chrome takes 25 seconds

So that function is 3% of 61 seconds in Nightly, and 13% of 8 seconds in Chrome.

The frame being pointed at in the Firefox profile is some thread waiting time, at the beginning and end of the profile.

Thats just the point in the callstack my pointer was on when i uploaded the profile :)

I don't see anything obviously bad in the profile. This will be easier to analyze when we have better JIT information in the profiler.

Severity: -- → S4
Flags: needinfo?(jdemooij)
Priority: -- → P3

Latest profile :https://share.firefox.dev/4bXulZ1 (55s)

Samply profile: https://share.firefox.dev/4kYJ2Qi

Command:
samply record --browsers --breakpad-symbol-server https://symbols.mozilla.org/ --windows-symbol-server https://msdl.microsoft.com/download/symbols MOZ_DISABLE_CONTENT_SANDBOX=1 ETW_ENABLED=1 JIT_OPTION_enableICFramePointers=true JIT_OPTION_onlyInlineSelfHosted=true JIT_OPTION_emitInterpreterEntryTrampoline=true "C:\Program Files\Firefox Nightly\firefox.exe" --wait-for-browser

Jan, is this Samply profile more useful compared to the standard profiles from the gecko profiler?

Flags: needinfo?(jdemooij)

(In reply to Mayank Bansal from comment #6)

Jan, is this Samply profile more useful compared to the standard profiles from the gecko profiler?

That's a great idea but unfortunately the uploaded profile doesn't include the generated (assembly) code for the Ion functions. (Ideally we'd want the LIR instruction names + the assembly code to help diagnose these bugs.) I just asked Markus about this and he said this isn't supported yet in the profiler.

Flags: needinfo?(jdemooij)
You need to log in before you can comment on or make changes to this bug.