Opening https://colorjs.io/ keeps the parent-process very busy for 4+seconds, spending tons of time in network-y IPC. This results in stutter while scrolling
Categories
(Core :: Networking, defect, P2)
Tracking
()
Performance Impact | low |
People
(Reporter: mayankleoboy1, Unassigned)
References
(Depends on 1 open bug, Blocks 1 open bug)
Details
(Whiteboard: [necko-triaged])
Attachments
(2 files)
- Go to https://colorjs.io/
- Wait patiently till the page loads fully (may take 10-15 seconds)
- Keep on scrolling from top-to-bottom
AR:
Nightly: https://share.firefox.dev/4bjwSLP
Chrome: https://share.firefox.dev/3xl7CqJ
ER: Maybe something to improve?
Filing this under Core:networking, but this may be DOM:PostMessages.
cc: valentin, smaug
The profile is similar to bug 1883290
Comment 1•8 months ago
|
||
This appears to all be communication with WebExtensions; likely due to ublock origin. Looks like something where the page makes a zillion small requests (~300 bytes) for js files, and ublock origin has to tell the parent process if each one is ok. Probably this is simply required due to how ublock origin works; you should ask them if there's anything they (or we) could do to improve this, but likely it's just the way it is if a page is constructed this way.
You might check if that other report is the same issue. It's always helpful to check a repeatable bug with troubleshooting mode or a new profile, which can speed diagnosis.
Thanks for reporting!
Reporter | ||
Comment 2•8 months ago
•
|
||
(Reopening only this one time)
See a profile from a fresh Nightly profile with no addons: https://share.firefox.dev/4bmM7Ue
Edit: And a profile with all threads sampled : https://share.firefox.dev/3zhnuet
Reporter | ||
Comment 3•8 months ago
|
||
Comment 4•8 months ago
|
||
Mayank - thanks for the no-extensions profile. It's possible there's something we can improve here; the site certainly stresses the network layer by a very large number of small loads. I note that Chrome is also very busy when you scroll down this page. I don't see stuttering on my system/network, but that may vary depending on CPU/network/etc.
See for example https://share.firefox.dev/4bkNrqS
Andrew, kershaw: thoughts?
Reporter | ||
Comment 5•8 months ago
•
|
||
An additional observation: In all the profiles from comment #2 (https://share.firefox.dev/4eJqFMf, https://share.firefox.dev/4cB1bi6) and comment #4(https://share.firefox.dev/3W2jhEp), the parent process appears to spend 700-800ms in font loading code (maybe not 100% but a large majority)
Comment 6•7 months ago
|
||
(In reply to Randell Jesup [:jesup] (needinfo me) from comment #4)
Mayank - thanks for the no-extensions profile. It's possible there's something we can improve here; the site certainly stresses the network layer by a very large number of small loads. I note that Chrome is also very busy when you scroll down this page. I don't see stuttering on my system/network, but that may vary depending on CPU/network/etc.
See for example https://share.firefox.dev/4bkNrqS
Andrew, kershaw: thoughts?
I think it would be difficult to reduce the main thread loading in the parent process.
However, I do see an opportunity here. From the all-thread sample, I notice that the ProxyResolution thread uses ~30% CPU resources. I think it would be beneficial to revisit bug 1392272 (which was reverted in bug 1749501) to avoid reading system proxy settings for every HTTP request.
Comment 7•7 months ago
|
||
(In reply to Kershaw Chang [:kershaw] from comment #6)
...
I think it would be difficult to reduce the main thread loading in the parent process.
However, I do see an opportunity here. From the all-thread sample, I notice that the ProxyResolution thread uses ~30% CPU resources. I think it would be beneficial to revisit bug 1392272 (which was reverted in bug 1749501) to avoid reading system proxy settings for every HTTP request.
I've logged optimizing the proxy resolution in bug 1907364
Comment 8•7 months ago
|
||
Hello Andrew, as we are planning improving our CPU utilization with Bug 1907364, I don't think we can do anything additional for this bug?
Comment 9•7 months ago
|
||
(In reply to Sunil Mayya from comment #8)
Hello Andrew, as we are planning improving our CPU utilization with Bug 1907364, I don't think we can do anything additional for this bug?
I think it's fine to leave it open as blocked by bug 1907364
Comment 10•7 months ago
|
||
The Performance Impact Calculator has determined this bug's performance impact to be low. If you'd like to request re-triage, you can reset the Performance Impact flag to "?" or needinfo the triage sheriff.
Platforms: [x] Windows [x] macOS [x] Linux [x] Android
Websites affected: Rare
Resource impact: Severe
[x] Able to reproduce locally
Updated•6 months ago
|
Reporter | ||
Comment 11•4 months ago
•
|
||
Here is a artificial testcase that i think shows similiar behaviour of stressing the parent-process.
Opening the testcase from a local server: https://share.firefox.dev/4h6OQ8k (7s)
Reporter | ||
Comment 12•3 months ago
|
||
Profile from latest Nightly containing the fix from bug 1594368:
opening the URL in comment #0 : https://share.firefox.dev/3YmqYVP
Opening the attached testcase over a local server: https://share.firefox.dev/3NH5YEe
Description
•