intersection-observer/root-element-deleted.html is flaky on Sierra Release WK2 bot. intersection-observer/target-deleted.html is flaky on the GTK bots. These two tests try to trigger GC, but if they happen to do this while the GC thread is already active, the call to GC will early-out in GCController::garbageCollectNow. This is problematic for two reasons: 1) The test will continue before the already-underway GC is finished; 2) Objects whose last reference was only just released might not be freed by the already-underway GC. To make these tests more robust, we need to do something like what intersection-observer/no-document-leak.html does, and repeatedly trigger GC inside a setInterval().
Created attachment 354117 [details] Patch
Comment on attachment 354117 [details] Patch Clearing flags on attachment: 354117 Committed r237939: <https://trac.webkit.org/changeset/237939>
All reviewed patches have been landed. Closing bug.
<rdar://problem/45886176>