Open Bug 1311731 Opened 8 years ago Updated 2 years ago

Make GC concurrent with painting

Categories

(Core :: JavaScript: GC, defect, P3)

defect

Tracking

()

People

(Reporter: sfink, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

(Keywords: triage-deferred)

FYI: Jon has been working on putting GC on its own thread in bug 1297122 (so where we would now run GC on the main thread, we would trigger the GC thread to do it and wait for it to finish.) If we can really ensure that painting does not read JS data, then rather than yielding to painting during GC as in bug 1308039, we can let them run concurrently and join on the GC thread when the paint is complete.
Bill, does that sound feasible? I know you have the assertions against ExposeToActiveJS in place already. But I don't know if there's a risk that we might be reading JS data without barriers. (Right now, we only need the read barrier for things that might escape.)
Flags: needinfo?(wmccloskey)
This seems feasible. Presumably the main thread would be blocked on a condition var while the GC is running. The hang monitor thread could wake it up and ask it to run the interrupt callbacks while the GC is still running.

As we fix the ExposeToActiveJS assertion failures we've found so far, we can consider adding more assertions. We might want to add one to Rooted to ensure that it's never created during painting.
Flags: needinfo?(wmccloskey)
Keywords: triage-deferred
Priority: -- → P3
Blocks: 1507448
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.