Remove Heap::setMarked()
authorfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 14 Sep 2016 20:41:31 +0000 (20:41 +0000)
committerfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 14 Sep 2016 20:41:31 +0000 (20:41 +0000)
Rubber stamped by Keith Miller.

Nobody uses this function.

* heap/Heap.h:
* heap/HeapInlines.h:
(JSC::Heap::setMarked): Deleted.
* heap/LargeAllocation.h:
(JSC::LargeAllocation::testAndSetMarked):
(JSC::LargeAllocation::setMarked): Deleted.
* heap/MarkedBlock.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@205925 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/heap/Heap.h
Source/JavaScriptCore/heap/HeapInlines.h
Source/JavaScriptCore/heap/LargeAllocation.h
Source/JavaScriptCore/heap/MarkedBlock.h

index 80f1c3d..510b84d 100644 (file)
@@ -1,3 +1,19 @@
+2016-09-14  Filip Pizlo  <fpizlo@apple.com>
+
+        Remove Heap::setMarked()
+
+        Rubber stamped by Keith Miller.
+        
+        Nobody uses this function.
+
+        * heap/Heap.h:
+        * heap/HeapInlines.h:
+        (JSC::Heap::setMarked): Deleted.
+        * heap/LargeAllocation.h:
+        (JSC::LargeAllocation::testAndSetMarked):
+        (JSC::LargeAllocation::setMarked): Deleted.
+        * heap/MarkedBlock.h:
+
 2016-09-14  Mark Lam  <mark.lam@apple.com>
 
         Use Options::validateExceptionChecks() instead of VM::m_verifyExceptionEvents.
index 5161792..f9ef6d0 100644 (file)
@@ -100,7 +100,6 @@ public:
     static bool isMarked(const void*);
     static bool isMarkedConcurrently(const void*);
     static bool testAndSetMarked(HeapVersion, const void*);
-    static void setMarked(const void*);
     
     static size_t cellSize(const void*);
 
index 6c4d0b4..1a9d076 100644 (file)
@@ -108,18 +108,6 @@ ALWAYS_INLINE bool Heap::testAndSetMarked(HeapVersion version, const void* rawCe
     return block.testAndSetMarked(cell);
 }
 
-inline void Heap::setMarked(const void* rawCell)
-{
-    HeapCell* cell = bitwise_cast<HeapCell*>(rawCell);
-    if (cell->isLargeAllocation()) {
-        cell->largeAllocation().setMarked();
-        return;
-    }
-    MarkedBlock& block = cell->markedBlock();
-    block.flipIfNecessary(block.vm()->heap.objectSpace().version());
-    block.setMarked(cell);
-}
-
 ALWAYS_INLINE size_t Heap::cellSize(const void* rawCell)
 {
     return bitwise_cast<HeapCell*>(rawCell)->cellSize();
index 03a86ea..b2bd91f 100644 (file)
@@ -119,7 +119,6 @@ public:
         return !m_isMarked.compareExchangeStrong(false, true);
     }
     ALWAYS_INLINE bool testAndSetMarked(HeapCell*) { return testAndSetMarked(); }
-    void setMarked() { m_isMarked.store(true); }
     void clearMarked() { m_isMarked.store(false); }
     
     void noteMarked() { }
index c319869..d26aff9 100644 (file)
@@ -254,7 +254,6 @@ public:
     bool isMarkedOrNewlyAllocatedDuringWeakVisiting(HeapVersion, const HeapCell*);
 
     bool isAtom(const void*);
-    void setMarked(const void*);
     void clearMarked(const void*);
         
     size_t cellSize();