[webkit-reviews] review granted: [Bug 57903] Introduced the concept of opaque roots, in preparation for marking the DOM with them : [Attachment 88333] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Apr 5 16:58:54 PDT 2011


Oliver Hunt <oliver at apple.com> has granted Geoffrey Garen <ggaren at apple.com>'s
request for review:
Bug 57903: Introduced the concept of opaque roots, in preparation for marking
the DOM with them
https://bugs.webkit.org/show_bug.cgi?id=57903

Attachment 88333: Patch
https://bugs.webkit.org/attachment.cgi?id=88333&action=review

------- Additional Comments from Oliver Hunt <oliver at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=88333&action=review

> Source/JavaScriptCore/collector/handles/HandleHeap.cpp:110
> +	       ASSERT(isValidWeakHandle(node->slot()));
> +	       JSCell* cell = node->slot()->asCell();
> +	       if (Heap::isMarked(cell))
> +		   continue;
> +
> +	       WeakHandleOwner* weakOwner = node->weakOwner();
> +	       if (!weakOwner)
> +		   continue;
> +
> +	       if
(!weakOwner->isReachableFromOpaqueRoots(Handle<Unknown>::wrapSlot(node->slot())
, node->weakOwnerContext(), markStack))
> +		   continue;
> +
> +	       heapRootMarker.mark(node->slot());

I wish we could do something to separate out handles that will remain alive as
we enumerate them, otherwise we end up visiting nodes repeatedly (even if just
for an isMarked check)


More information about the webkit-reviews mailing list