Consider keeping track of preserved wrappers as an nsINode bit

RESOLVED DUPLICATE of bug 457022

Status

()

Core
DOM
RESOLVED DUPLICATE of bug 457022
11 years ago
8 years ago

People

(Reporter: bz, Unassigned)

Tracking

Trunk
x86
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

If we make AddReference/RemoveReference take an nsINode*, not a void* as the key, we could set a bit on the node when the reference is added and remove it when it's removed.

Then during cycle collection we could check that bit before hitting the hashtable.  Since most nodes don't have a preserved wrapper, this ought to be a win, I think.
Blocks: 377787
Note that with sicking's patch to short-circuit traversal of currently-displayed documents this may not be as much of a problem anymore...
Assignee: general → nobody
QA Contact: ian → general
I'm going to dupe this to bug 457022 (cached wrappers), since we only traverse to the cached wrapper if a bit is set (see WRAPPER_BIT_PRESERVED) and we only put the objects in a hash if they have a preserved wrapper.
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 457022
You need to log in before you can comment on or make changes to this bug.