Closed
Bug 1277036
Opened 7 years ago
Closed 6 years ago
Re-enable the UsefulToMergeZones implementation in XPCJSRuntime
Categories
(Core :: XPConnect, defect)
Core
XPConnect
Tracking
()
RESOLVED
WONTFIX
Tracking | Status | |
---|---|---|
firefox49 | --- | affected |
People
(Reporter: bzbarsky, Assigned: mccr8)
References
Details
(Whiteboard: btpp-backlog)
Attachments
(1 file, 2 obsolete files)
2.66 KB,
patch
|
Details | Diff | Splinter Review |
See discussion starting at bug 1276112 comment 16.
Assignee | ||
Updated•7 years ago
|
Whiteboard: bttp-backlog
Updated•7 years ago
|
Whiteboard: bttp-backlog → btpp-backlog
Assignee | ||
Comment 1•7 years ago
|
||
MozReview-Commit-ID: Dq73qiJ0f87
Assignee | ||
Comment 2•7 years ago
|
||
I started looking at this again. With the attached patch, we hit an assertion very quickly. nsCycleCollector::MarkRoots() now has an AutoAssertOnGC at the start of it (added in bug 1004276 which landed in 51), and the traverse function for zones makes a call to js::IterateGrayObjects(), which can trigger a minor GC, setting off the assertion in MarkRoots() (the minor GC was added in bug 945250). The comment on ZoneCellIter says "The JSObject case needs to GC, or more precisely to empty the nursery and clear out the store buffer, so that it can see all objects to iterate over (the nursery is not iterable) and remove the possibility of having pointers from the store buffer to data hanging off stuff we're iterating over that we are going to delete.". For the former part, we only want to see gray objects, and there should be no gray objects in the nursery, so I think that's not an issue. I don't understand the latter part, but this particular callback the CC uses does not destroy anything, so it doesn't seem like an issue. Maybe we could get away without the minor GC, but it doesn't look like there's any way to call into this method. One possible work around would be to always run a minor GC before we start the CC. I worry a little what this might do to the CC pause times, but maybe that's not a big issue. Also, the minor GC would have been be placed carefully to avoid reentrance if it ends up triggering a major GC (assuming that is a possibility). Passing along the "empty" token into the iterator that runs much later would also be a pain. Jon, do you have any ideas here? (I'd as sfink, but it looks like he's on PTO.)
Flags: needinfo?(jcoppeard)
Comment 3•7 years ago
|
||
(In reply to Andrew McCreight [:mccr8] from comment #2) I'll write a patch to do this without evicting the nursery first.
Assignee: nobody → jcoppeard
Flags: needinfo?(jcoppeard)
Assignee | ||
Comment 4•7 years ago
|
||
(In reply to Jon Coppeard (:jonco) from comment #3) > I'll write a patch to do this without evicting the nursery first. Thanks! You should probably spin that off into a new bug blocking this one, as the patch here had some other issues with OOMs last time bz tried to land it, so it may not be ready to go even with your fix.
Assignee | ||
Comment 5•7 years ago
|
||
MozReview-Commit-ID: Dq73qiJ0f87
Assignee | ||
Updated•7 years ago
|
Attachment #8794904 -
Attachment is obsolete: true
Assignee | ||
Comment 6•7 years ago
|
||
The XP gl mochitest issue seems okay. I think there has been some recent work to make that better: https://treeherder.mozilla.org/#/jobs?repo=try&revision=db023984a245e6be7dc3fcf532665875b8001223 But it does look like it is somehow causing bug 1262224 about half of the time.
Assignee: jcoppeard → continuation
Depends on: 1262224
Assignee | ||
Comment 7•7 years ago
|
||
Updated to call IterateGrayObjectsUnderCC.
Assignee | ||
Updated•7 years ago
|
Attachment #8799994 -
Attachment is obsolete: true
Assignee | ||
Comment 8•6 years ago
|
||
I think heuristics like this that we can't run all of the time are too difficult to get right, so I'm going to close this for now. Kind of a shame, as it was a big speedup when it worked.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•