Closed
Bug 505898
Opened 16 years ago
Closed 16 years ago
TM: Remove local root scopes and NewGCThing pigeonhole
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: gal, Unassigned)
Details
We currently have 3 ways of temporary rooting newborn JSGCThings:
- pigeon hole (we might rely on this in some places, unclear)
- LocalRootStack (used in JSXML only)
- JSAutoTempValueRooter (the new shiny thing we want to keep)
We currently pay a price of the pigeon hole and the LRS in the allocator path, and we should get rid of that overhead. Ideally we should do some static analysis that proves that we have all the right JSAutoTempValueRooters in place, and then rip out the old constructs.
Comment 1•16 years ago
|
||
Newborn roots (pigeon hole) are going, they are broken as designed.
LocalRootStack protects newborns but not oldborns who may become disconnected while a native is running, and then a GC nests.
Ergo JSAutoTempValueRooter (new name, public API if possible) is the way.
See bug 421934 and bug 353231 for static analysis work to find all extant rooting bugs. The analysis AFAIK would ignore newborn roots, but until we have it, we cannot assume newborns are not needed, even though they're hazardous as hell.
/be
Updated•16 years ago
|
Summary: TM: Remove LocalRootStack and NewGCThing pidgeon hole → TM: Remove LocalRootStack and NewGCThing pigeonhole
Updated•16 years ago
|
Summary: TM: Remove LocalRootStack and NewGCThing pigeonhole → TM: Remove local root scopes and NewGCThing pigeonhole
Comment 2•16 years ago
|
||
(In reply to comment #0)
> We currently pay a price of the pigeon hole and the LRS in the allocator path,
> and we should get rid of that overhead.
For compatibility the rooting can be done when JS API returns GC things.
| Reporter | ||
Comment 3•16 years ago
|
||
Yeah, #2 is exactly on point I think. We can take the overhead in JSAPI and that would probably help static analysis a lot since we can restrict it to the engine itself.
| Reporter | ||
Comment 4•16 years ago
|
||
This bug was obsoleted by 516832. With 516832 fixed we can now eliminate all 3 rooting methods.
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → WONTFIX
Comment 5•16 years ago
|
||
(In reply to comment #4)
> This bug was obsoleted by 516832. With 516832 fixed we can now eliminate all 3
> rooting methods.
Both newborns and local roots cannot be just eliminated since the conservative scanning covers just the stack. Thus any elimination of these roots must ensure that the code does not rely on these roots for GC things stored in malloced structures, not on the native stack.
You need to log in
before you can comment on or make changes to this bug.
Description
•