Open Bug 1809058 Opened 1 year ago Updated 1 year ago

Codepen demo (https://codepen.io/toshiya-marukubo/pen/podvabY) is slower in Nightly compared with Chrome

Categories

(Core :: JavaScript Engine, task, P2)

task

Tracking

()

People

(Reporter: mayankleoboy1, Unassigned)

References

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

Details

Attachments

(1 file)

Go to https://codepen.io/toshiya-marukubo/pen/podvabY
Move your mouse inside the demo pane
The shapes/circles will move

https://share.firefox.dev/3VVwqMf

Chrome is visually much more smooth

This performs well for me on Mac, but in your profile I see a ton of jemalloc lock contention in the flame graph. Can you get a profile with all background threads enabled in the profiler settings? Maybe that will tell us which thread we're waiting for...

Flags: needinfo?(mayankleoboy1)
Flags: needinfo?(mayankleoboy1) → needinfo?(jdemooij)
Attached file about:support

(In reply to Mayank Bansal from comment #2)

https://share.firefox.dev/3WWEsFR

Thanks! This shows a lot of the jemalloc lock contention on the main thread is caused by the GC freeing memory on helper threads. In particular, there's a lot of time under VirtualFree. Jon suggested we're holding the jemalloc lock at this point. It would be nice if we could unlock before releasing the memory to the OS.

Flags: needinfo?(jdemooij) → needinfo?(pbone)
See Also: → 1805644

This confirms some suspicions.

I had seen a profile where jemalloc's free() code was MUCH slower than Linux's builtin allocator. But I didn't realise it held the lock during a system call. These profiles are great, thank you!

Flags: needinfo?(pbone)
Depends on: 1809610
Severity: -- → N/A
Priority: -- → P2
Depends on: 1810953
Depends on: 1810954
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: