Open Bug 1373200 Opened 7 years ago Updated 2 years ago

Consider renaming sweep related functions

Categories

(Core :: JavaScript: GC, enhancement, P5)

55 Branch
enhancement

Tracking

()

People

(Reporter: jonco, Unassigned)

Details

We currently have a whole bunch of different ways of updating a weak edge or clearing it if the referent is dying:

 1) EdgeNeedsSweep (public)
 2) JS_UpdateWeakPointerAfterGC (public)
 3) IsAboutToBeFinalized (internal)
 4) GCPolicy<T>::needsSweep (internal)

I find these names pretty confusing.  We should refactor these and use the same names for both public and internal versions.  One suggestion would be to have:

 - IsDying(pointer) - returns whether the cell is being swept in the current sweep group
 - UpdateWeakEdge(pointer to pointer) - update or clear pointer as necessary
Priority: -- → P5
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.