Closed Bug 1488462 Opened 7 years ago Closed 7 years ago

Big slowdown happening every x minutes

Categories

(Firefox :: New Tab Page, defect, P1)

defect

Tracking

()

RESOLVED FIXED
Firefox 64
Iteration:
64.3 - Oct 12
Tracking Status
firefox-esr60 --- unaffected
firefox62 --- wontfix
firefox63 + fixed
firefox64 + fixed

People

(Reporter: julienw, Assigned: Mardak)

References

Details

(Keywords: regression, Whiteboard: [fxperf:p1])

Attachments

(3 files)

Since recently I found that I got a big slowdown every some minutes. I took this profile: https://perfht.ml/2LWxzyX (sorry, it's a bit big to load, but I zoomed in the interesting part and toggled the "inverted tree" setting) This points to the direction of ActivityStream that maybe calls toHash a bit too much. Florian pointed me to this code [1]. Maybe this code could be converted to a for loop where the the filtering operation could happen just the right amount of time to get numItems items, and break early. [1] https://searchfox.org/mozilla-central/rev/c3fef66a5b211ea8038c1c132706d02db408093a/toolkit/modules/NewTabUtils.jsm#826-838
Discussing with Florian more, I realized that today I did a lot of screenshots through the devtools to review a patch, and because screenshots are data URL (so, big URLs), that's likely the reason. So maybe data-url should be handled differently too.
70% of the time here https://perfht.ml/2PBSnOn is spent in the hashing function called by BlockedLinks_isBlocked https://searchfox.org/mozilla-central/rev/c3fef66a5b211ea8038c1c132706d02db408093a/toolkit/modules/NewTabUtils.jsm#504 BlockedLinks_isBlocked should probably return early for data: urls. Is it expected that _processHighlights is called 15 times here? It seems to be in reaction to a 'messsage' DOM event, do we know what message this is?
Whiteboard: [fxperf]
Assignee: nobody → edilee
Iteration: --- → 64.1 (Sep 14)
Priority: -- → P1
Whiteboard: [fxperf] → [fxperf:p1]
Ed, this is marked as a P1 bug affecting the 63 release, do you have a status update on this one? Will you request an uplift to beta? Thanks
Flags: needinfo?(edilee)
Iteration: 64.1 (Sep 14) → 64.2 (Sep 28)
Iteration: 64.2 (Sep 28) → 64.3 (Oct 12)
This was regressed by bug 1433230 when downloads were added to highlights
Depends on: 1433230
Commit pushed to master at https://github.com/mozilla/activity-stream https://github.com/mozilla/activity-stream/commit/eb19a91c737463777b6ebcb9a0f1481b20c8335f Fix Bug 1488462 - Big slowdown happening every x minutes (#4459) Directly pick the first download result and add a type without calling processHighlights, which checks blocked links.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Depends on: 1496092
Blocks: 1433230
No longer depends on: 1433230
Blocks: 1496092
No longer depends on: 1496092
julienw, do you still have the profile that this was happening with (and was it still causing slowdown) to test with nightly 20181003223518 or newer?
Flags: qe-verify+
Flags: needinfo?(felash)
Kate, this is a tracked regression for 63, we'll need the fix to be uplifted to Beta, thanks!
Flags: needinfo?(khudson)
QA Contact: tspurway
Comment on attachment 9014851 [details] Bug 1488462 - Big slowdown happening every x minutes [Beta/Release Uplift Approval Request] Feature/Bug causing the regression: Bug 1488462 User impact if declined: Significant performance regression for users 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): Small code change String changes made/needed: no
Flags: needinfo?(khudson)
Attachment #9014851 - Flags: approval-mozilla-beta?
Comment on attachment 9014851 [details] Bug 1488462 - Big slowdown happening every x minutes Trivial patch fixing a major performance hit in Firefox 63, uplift approved for 63 beta 13, thanks.
Attachment #9014851 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
QA Contact: tspurway
This was uplifted
Flags: needinfo?(edilee)
(In reply to Ed Lee :Mardak (PTO Sep 15 - Oct 7) from comment #8) > julienw, do you still have the profile that this was happening with (and was > it still causing slowdown) to test with nightly 20181003223518 or newer? yes, that's my main profile. I just opened some data-URLs and I'll report if I see anything suspicious.
Flags: needinfo?(felash)
Component: Activity Streams: Newtab → New Tab Page
Regressions: 1559548
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: