2011-02-10 Geoffrey Garen <ggaren@apple.com>
authorggaren@apple.com <ggaren@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 11 Feb 2011 00:20:17 +0000 (00:20 +0000)
committerggaren@apple.com <ggaren@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 11 Feb 2011 00:20:17 +0000 (00:20 +0000)
commitfa3bfdb227aa643b71720737b77d850927bf1e6c
tree8ff8e86e016640009179b63c060a446d0969599e
parent07abed0cda45da75058bcc18c081ef10903678a3
2011-02-10  Geoffrey Garen  <ggaren@apple.com>

        Reviewed by Oliver Hunt.

        A little more encapsulation for MarkedBlock: Moved allocate() and sweep() into MarkedBlock
        https://bugs.webkit.org/show_bug.cgi?id=54253

        SunSpider reports no change.

        * runtime/CollectorHeapIterator.h: Removed DeadObjectIterator, since it
        is now unused.

        * runtime/Heap.cpp:
        (JSC::Heap::reset): Moved the call to shrink() here, since it seems a
        little more clear for MarkedSpace's client to tell it explicitly when to
        shrink.

        * runtime/JSCell.h:
        (JSC::JSCell::MarkedBlock::allocate): Split out from MarkedSpace::allocate.

        * runtime/MarkedBlock.cpp:
        (JSC::MarkedBlock::sweep): Split out from MarkedSpace::sweep, and
        converted to more directly iterate a MarkedBlock based on knowing its
        internal structure.

        * runtime/MarkedBlock.h:
        * runtime/MarkedSpace.cpp:
        (JSC::MarkedSpace::allocate):
        (JSC::MarkedSpace::sweep):
        * runtime/MarkedSpace.h: Split out the code mentioned above.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@78284 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/runtime/CollectorHeapIterator.h
Source/JavaScriptCore/runtime/Heap.cpp
Source/JavaScriptCore/runtime/JSCell.h
Source/JavaScriptCore/runtime/MarkedBlock.cpp
Source/JavaScriptCore/runtime/MarkedBlock.h
Source/JavaScriptCore/runtime/MarkedSpace.cpp
Source/JavaScriptCore/runtime/MarkedSpace.h