Refactored the Heap to move more MarkedSpace logic into MarkedSpace
authorggaren@apple.com <ggaren@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 May 2012 00:40:30 +0000 (00:40 +0000)
committerggaren@apple.com <ggaren@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 May 2012 00:40:30 +0000 (00:40 +0000)
commit05a539f4f78d18520399dc565c727f889d305dd1
tree64b071956d0339f57f51a64c57635d4c152b71d2
parentbd12a0541421c81cd2640ad9906ead63ca1a4b9e
Refactored the Heap to move more MarkedSpace logic into MarkedSpace
https://bugs.webkit.org/show_bug.cgi?id=86790

Reviewed by Gavin Barraclough.

* heap/Heap.cpp:
(JSC::Heap::lastChanceToFinalize):
(JSC::Heap::markRoots):
(JSC):
(JSC::Heap::objectCount):
(JSC::Heap::size):
(JSC::Heap::capacity):
(JSC::Heap::collect):
* heap/Heap.h:
(Heap): Took all the functors from here...

* heap/MarkedBlock.h:
(CountFunctor):
(JSC::MarkedBlock::CountFunctor::CountFunctor):
(JSC::MarkedBlock::CountFunctor::count):
(JSC::MarkedBlock::CountFunctor::returnValue):
(MarkedBlock):
* heap/MarkedSpace.h:
(JSC::ClearMarks::operator()):
(JSC):
(JSC::Sweep::operator()):
(JSC::MarkCount::operator()):
(JSC::Size::operator()):
(JSC::Capacity::operator()):
(MarkedSpace):
(JSC::MarkedSpace::clearMarks):
(JSC::MarkedSpace::sweep):
(JSC::MarkedSpace::objectCount):
(JSC::MarkedSpace::size):
(JSC::MarkedSpace::capacity): and put them here.

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