Closed Bug 1796081 Opened 2 years ago Closed 2 years ago

Refactor WeakMap a little in preparation for parallel marking

Categories

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

task

Tracking

()

RESOLVED FIXED
108 Branch
Tracking Status
firefox108 --- fixed

People

(Reporter: jonco, Assigned: jonco)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

No description provided.

We don't need to trace weakmap values that are in the nursery because these
will be kept alive in minor GC by the store buffer entry pushed by HeapPtr.

Currently the table population is done separately from marking the entry which
means we check the key color twice, potentially getting different results if
another thread is marking at the same time. This could result in us not adding
ephemeron table entries when necessary.

The patch consolidates these two paths.

Depends on D159677

Pushed by jcoppeard@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/c7898b0dbad3
Part 1: Don't trace weak map values that are in the nursery r=sfink
https://hg.mozilla.org/integration/autoland/rev/894ad5982bff
Part 2: Only check the key color once when populating the ephemeron table r=sfink
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 108 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: