Bug 191387 - IntersectionObserver GC-dependent tests are flaky
Summary: IntersectionObserver GC-dependent tests are flaky
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Ali Juma
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-11-07 11:38 PST by Ali Juma
Modified: 2018-11-07 13:01 PST (History)
7 users (show)

See Also:


Attachments
Patch (4.08 KB, patch)
2018-11-07 11:40 PST, Ali Juma
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ali Juma 2018-11-07 11:38:01 PST
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().
Comment 1 Ali Juma 2018-11-07 11:40:56 PST
Created attachment 354117 [details]
Patch
Comment 2 WebKit Commit Bot 2018-11-07 13:00:44 PST
Comment on attachment 354117 [details]
Patch

Clearing flags on attachment: 354117

Committed r237939: <https://trac.webkit.org/changeset/237939>
Comment 3 WebKit Commit Bot 2018-11-07 13:00:46 PST
All reviewed patches have been landed.  Closing bug.
Comment 4 Radar WebKit Bug Importer 2018-11-07 13:01:30 PST
<rdar://problem/45886176>