Closed
Bug 883657
Opened 11 years ago
Closed 11 years ago
Don't force a GC in mozJSComponentLoader::UnloadModules()
Categories
(Core :: XPConnect, defect)
Core
XPConnect
Tracking
()
RESOLVED
FIXED
mozilla25
People
(Reporter: mccr8, Assigned: mccr8)
References
(Blocks 1 open bug)
Details
(Whiteboard: [qa-])
Attachments
(2 files)
1.67 KB,
patch
|
benjamin
:
review+
bajaj
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
994 bytes,
patch
|
bholley
:
review+
bajaj
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
Bug 881266 revealed that mozJSComponentLoader::UnloadModules() runs JS_DestroyContext(), which forces a GC, right after we shutdown the CC. This feels archaic. Just changing this to JS_DestroyContextNoGC() causes tiny shutdown leaks, so probably we need to move UnloadModules() to before we shutdown the CC, then see if we can get away with not forcing a GC. Note that we still may end up running a GC here unless bug 881309, but it is a start. Also, once this stuff is cleaned up, it might be worth asserting if the GC ever runs after the CC shuts down.
Assignee | ||
Comment 1•11 years ago
|
||
Let's see how this works. move unload before CC shutdown: https://tbpl.mozilla.org/?tree=Try&rev=36fda2b321b3 don't force a GC in mozJSComponentLoader::UnloadModules: https://tbpl.mozilla.org/?tree=Try&rev=104b83032368
Assignee | ||
Comment 2•11 years ago
|
||
Both are green in L64 debug. I suppose I should see if this actually reduces the number of shutdown GCs in opt builds.
Assignee | ||
Comment 3•11 years ago
|
||
Assignee: nobody → continuation
Assignee | ||
Comment 4•11 years ago
|
||
Assignee | ||
Comment 5•11 years ago
|
||
Comment on attachment 766753 [details] [diff] [review] part 1: call UnloadModules before we shutdown the CC Review of attachment 766753 [details] [diff] [review]: ----------------------------------------------------------------- I'm not sure who really knows this code, but it involves shutdown, so maybe you can review this, bsmedberg.
Attachment #766753 -
Flags: review?(benjamin)
Assignee | ||
Comment 6•11 years ago
|
||
Comment on attachment 766754 [details] [diff] [review] part 2: don't force a GC in UnloadModules With UnloadModules moved before the shutdown GC+CCs, we don't need to force a GC in shutdown to avoid tiny leaks.
Attachment #766754 -
Flags: review?(bobbyholley+bmo)
Comment 7•11 years ago
|
||
Comment on attachment 766754 [details] [diff] [review] part 2: don't force a GC in UnloadModules Review of attachment 766754 [details] [diff] [review]: ----------------------------------------------------------------- Nice. r=bholley
Attachment #766754 -
Flags: review?(bobbyholley+bmo) → review+
Updated•11 years ago
|
Attachment #766753 -
Flags: review?(benjamin) → review+
Assignee | ||
Comment 8•11 years ago
|
||
Thanks for the quick reviews! remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/b05165a7a277 remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/47862004ed14 try run looked good https://tbpl.mozilla.org/?tree=Try&rev=c21852be5d44
Comment 9•11 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/b05165a7a277 https://hg.mozilla.org/mozilla-central/rev/47862004ed14
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
Comment 10•11 years ago
|
||
Congrats, mccr8! According to a lot of Try bisection and the below Try push (these patches on top of m-b tip), this is what also what made WinXP xpcshell stop timing out all the time. https://tbpl.mozilla.org/?tree=Try&rev=748c38bed260 Can you please request approval to uplift this to Fx24 so we get this in for the next ESR? :)
status-firefox24:
--- → affected
status-firefox25:
--- → fixed
Comment 11•11 years ago
|
||
Comment on attachment 766753 [details] [diff] [review] part 1: call UnloadModules before we shutdown the CC [Approval Request Comment] Bug caused by (feature/regressing bug #): n/a User impact if declined: sheriff pain on esr24 Testing completed (on m-c, etc.): missed fx24 by a day, no known regressions Risk to taking this patch (and alternatives if risky): minimal per mccr8 String or IDL/UUID changes made by this patch: none
Attachment #766753 -
Flags: approval-mozilla-beta?
Updated•11 years ago
|
Attachment #766754 -
Flags: approval-mozilla-beta?
Comment 12•11 years ago
|
||
Comment on attachment 766753 [details] [diff] [review] part 1: call UnloadModules before we shutdown the CC low risk well baked, makes sheriff's life easier :) Lets get it on !
Attachment #766753 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Updated•11 years ago
|
Attachment #766754 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 13•11 years ago
|
||
https://hg.mozilla.org/releases/mozilla-beta/rev/a4ae95d37938 https://hg.mozilla.org/releases/mozilla-beta/rev/6325125d05b3
Comment 14•11 years ago
|
||
Assuming no QA needed here. Please remove [qa-] from the whiteboard and add the verifyme keyword if this needs QA.
Whiteboard: [qa-]
You need to log in
before you can comment on or make changes to this bug.
Description
•