Changeset 113508 in webkit for trunk/Source/JavaScriptCore/heap/Heap.cpp
- Timestamp:
- Apr 6, 2012, 3:35:55 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/heap/Heap.cpp
r113445 r113508 324 324 , m_sharedData(globalData) 325 325 , m_slotVisitor(m_sharedData) 326 , m_weak Heap(this)327 , m_handle Heap(globalData)326 , m_weakSet(this) 327 , m_handleSet(globalData) 328 328 , m_isSafeToCollect(false) 329 329 , m_globalData(globalData) … … 376 376 clearMarks(); 377 377 378 m_weak Heap.finalizeAll();378 m_weakSet.finalizeAll(); 379 379 m_globalData->smallStrings.finalizeSmallStrings(); 380 380 shrink(); … … 661 661 { 662 662 GCPHASE(VisitStrongHandles); 663 m_handle Heap.visitStrongHandles(heapRootVisitor);663 m_handleSet.visitStrongHandles(heapRootVisitor); 664 664 visitor.donateAndDrain(); 665 665 } … … 690 690 GCPHASE(VisitingLiveWeakHandles); 691 691 while (true) { 692 m_weak Heap.visitLiveWeakImpls(heapRootVisitor);692 m_weakSet.visitLiveWeakImpls(heapRootVisitor); 693 693 harvestWeakReferences(); 694 694 if (visitor.isEmpty()) … … 706 706 { 707 707 GCPHASE(VisitingDeadWeakHandles); 708 m_weak Heap.visitDeadWeakImpls(heapRootVisitor);708 m_weakSet.visitDeadWeakImpls(heapRootVisitor); 709 709 } 710 710 … … 819 819 { 820 820 GCPHASE(FinalizeWeakHandles); 821 m_weak Heap.sweep();821 m_weakSet.sweep(); 822 822 m_globalData->smallStrings.finalizeSmallStrings(); 823 823 } … … 867 867 { 868 868 m_objectSpace.resetAllocators(); 869 m_weak Heap.resetAllocator();869 m_weakSet.resetAllocator(); 870 870 } 871 871 … … 928 928 void Heap::addFinalizer(JSCell* cell, Finalizer finalizer) 929 929 { 930 weak Heap()->allocate(cell, &m_finalizerOwner, reinterpret_cast<void*>(finalizer)); // Balanced by FinalizerOwner::finalize().930 weakSet()->allocate(cell, &m_finalizerOwner, reinterpret_cast<void*>(finalizer)); // Balanced by FinalizerOwner::finalize(). 931 931 } 932 932 … … 936 936 Finalizer finalizer = reinterpret_cast<Finalizer>(context); 937 937 finalizer(slot->asCell()); 938 Weak Heap::deallocate(WeakImpl::asWeakImpl(slot));938 WeakSet::deallocate(WeakImpl::asWeakImpl(slot)); 939 939 } 940 940
Note:
See TracChangeset
for help on using the changeset viewer.