Closed
Bug 515287
Opened 15 years ago
Closed 15 years ago
Don't trigger GC on every XHR completion
Categories
(Core :: DOM: Core & HTML, defect, P3)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla1.9.2
Tracking | Status | |
---|---|---|
status1.9.2 | --- | beta1-fixed |
People
(Reporter: bzbarsky, Assigned: smaug)
References
Details
(Keywords: perf)
Attachments
(1 file)
849 bytes,
patch
|
bzbarsky
:
review+
|
Details | Diff | Splinter Review |
We trigger a GC after every XHR completion. We should consider not doing that. Either only trigger it for completion of parts of a multipart request, or only trigger it every N XHR completions or something... See bug
Flags: blocking1.9.2?
See bug 515215.
Reporter | ||
Comment 2•15 years ago
|
||
er, yes. ;) I managed to paste it into the "blocks" field!
Assignee | ||
Comment 3•15 years ago
|
||
I think we can remove the whole GC call, since we call MaybeCC(PR_FALSE), and that call tries to check if there is lots possible new garbage to collect before calling CC, and CC isn't usually called if user is active. But I'll do some testing.
Assignee | ||
Comment 4•15 years ago
|
||
In my testing removing this doesn't cause any harm, though doesn't speed up things too much either. One problem is that nsJSContext::ScriptEvaluated is called very often, and that calls MaybeGC, which seems to trigger GC pretty often. But the nsJSContext::ScriptEvaluated handling is a different bug.
Attachment #399442 -
Flags: review?(peterv)
Assignee | ||
Comment 5•15 years ago
|
||
FYI, the GC call was added in Bug 237319. And I did test multipart XHR.
Assignee | ||
Comment 6•15 years ago
|
||
Based on testing in a debug build (so that I get ifdef DEBUG_smaug log about when to run CC), the patch does reduce calling CC, but yet when there are enough new suspected object, it is called. With the patch and 10 gmail tabs open CC is explicitly called about every 35s when the browser is in background.
Reporter | ||
Comment 7•15 years ago
|
||
How often does CC get called without the patch in that situation? I bet more often!
Assignee | ||
Comment 8•15 years ago
|
||
Without the patch I get "Running CC was delayed because of NS_MIN_CC_INTERVAL" message quite often. That means that someone tried to call CC more often than every 10s.
Assignee | ||
Updated•15 years ago
|
Assignee: nobody → Olli.Pettay
Comment 9•15 years ago
|
||
This is borderline blocker material IMO, but it'd be really nice to fix this...
Flags: blocking1.9.2? → blocking1.9.2+
OS: Mac OS X → All
Priority: -- → P3
Hardware: x86 → All
Target Milestone: --- → mozilla1.9.2
Assignee | ||
Updated•15 years ago
|
Attachment #399442 -
Flags: review?(peterv) → review?(bzbarsky)
Reporter | ||
Updated•15 years ago
|
Attachment #399442 -
Flags: review?(bzbarsky) → review+
Assignee | ||
Comment 10•15 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/c6bcf4347492
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 11•15 years ago
|
||
http://hg.mozilla.org/releases/mozilla-1.9.2/rev/7f3807ea3e95
status1.9.2:
--- → beta1-fixed
Updated•5 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•