Title: [206709] trunk/Source/_javascript_Core
Revision
206709
Author
[email protected]
Date
2016-10-01 14:14:19 -0700 (Sat, 01 Oct 2016)

Log Message

Get rid of isMarkedOrNewlyAllocated
https://bugs.webkit.org/show_bug.cgi?id=162842

Reviewed by Dan Bernstein.
        
This function has become dead code. This change removes it.

* heap/CellContainer.h:
* heap/CellContainerInlines.h:
(JSC::CellContainer::isMarkedOrNewlyAllocated): Deleted.
* heap/LargeAllocation.h:
(JSC::LargeAllocation::isLive):
(JSC::LargeAllocation::isMarkedOrNewlyAllocated): Deleted.
* heap/MarkedBlock.cpp:
(JSC::MarkedBlock::Handle::isMarkedOrNewlyAllocated): Deleted.
(JSC::MarkedBlock::isMarkedOrNewlyAllocated): Deleted.
* heap/MarkedBlock.h:
(JSC::MarkedBlock::Handle::isMarkedOrNewlyAllocated): Deleted.
(JSC::MarkedBlock::isMarkedOrNewlyAllocated): Deleted.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (206708 => 206709)


--- trunk/Source/_javascript_Core/ChangeLog	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/ChangeLog	2016-10-01 21:14:19 UTC (rev 206709)
@@ -1,3 +1,25 @@
+2016-10-01  Filip Pizlo  <[email protected]>
+
+        Get rid of isMarkedOrNewlyAllocated
+        https://bugs.webkit.org/show_bug.cgi?id=162842
+
+        Reviewed by Dan Bernstein.
+        
+        This function has become dead code. This change removes it.
+
+        * heap/CellContainer.h:
+        * heap/CellContainerInlines.h:
+        (JSC::CellContainer::isMarkedOrNewlyAllocated): Deleted.
+        * heap/LargeAllocation.h:
+        (JSC::LargeAllocation::isLive):
+        (JSC::LargeAllocation::isMarkedOrNewlyAllocated): Deleted.
+        * heap/MarkedBlock.cpp:
+        (JSC::MarkedBlock::Handle::isMarkedOrNewlyAllocated): Deleted.
+        (JSC::MarkedBlock::isMarkedOrNewlyAllocated): Deleted.
+        * heap/MarkedBlock.h:
+        (JSC::MarkedBlock::Handle::isMarkedOrNewlyAllocated): Deleted.
+        (JSC::MarkedBlock::isMarkedOrNewlyAllocated): Deleted.
+
 2016-10-01  Joseph Pecoraro  <[email protected]>
 
         Rename DebugHookID to DebugHookType

Modified: trunk/Source/_javascript_Core/heap/CellContainer.h (206708 => 206709)


--- trunk/Source/_javascript_Core/heap/CellContainer.h	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/heap/CellContainer.h	2016-10-01 21:14:19 UTC (rev 206709)
@@ -83,8 +83,6 @@
     
     bool isMarked(HeapCell*) const;
     bool isMarked(HeapVersion markingVersion, HeapCell*) const;
-    bool isMarkedOrNewlyAllocated(HeapCell*) const;
-    bool isMarkedOrNewlyAllocated(HeapVersion markingVersion, HeapCell*) const;
     
     void noteMarked();
     

Modified: trunk/Source/_javascript_Core/heap/CellContainerInlines.h (206708 => 206709)


--- trunk/Source/_javascript_Core/heap/CellContainerInlines.h	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/heap/CellContainerInlines.h	2016-10-01 21:14:19 UTC (rev 206709)
@@ -59,20 +59,6 @@
     return markedBlock().isMarked(markingVersion, cell);
 }
 
-inline bool CellContainer::isMarkedOrNewlyAllocated(HeapCell* cell) const
-{
-    if (isLargeAllocation())
-        return largeAllocation().isMarkedOrNewlyAllocated();
-    return markedBlock().isMarkedOrNewlyAllocated(cell);
-}
-
-inline bool CellContainer::isMarkedOrNewlyAllocated(HeapVersion markingVersion, HeapCell* cell) const
-{
-    if (isLargeAllocation())
-        return largeAllocation().isMarkedOrNewlyAllocated();
-    return markedBlock().isMarkedOrNewlyAllocated(markingVersion, cell);
-}
-
 inline void CellContainer::noteMarked()
 {
     if (!isLargeAllocation())

Modified: trunk/Source/_javascript_Core/heap/LargeAllocation.h (206708 => 206709)


--- trunk/Source/_javascript_Core/heap/LargeAllocation.h	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/heap/LargeAllocation.h	2016-10-01 21:14:19 UTC (rev 206709)
@@ -72,9 +72,7 @@
     ALWAYS_INLINE bool isMarked() { return m_isMarked.load(std::memory_order_relaxed); }
     ALWAYS_INLINE bool isMarked(HeapCell*) { return m_isMarked.load(std::memory_order_relaxed); }
     ALWAYS_INLINE bool isMarkedConcurrently(HeapVersion, HeapCell*) { return m_isMarked.load(std::memory_order_relaxed); }
-    bool isMarkedOrNewlyAllocated() { return isMarked() || isNewlyAllocated(); }
-    bool isMarkedOrNewlyAllocated(HeapCell*) { return isMarkedOrNewlyAllocated(); }
-    bool isLive() { return isMarkedOrNewlyAllocated(); }
+    bool isLive() { return isMarked() || isNewlyAllocated(); }
     
     bool hasValidCell() const { return m_hasValidCell; }
     

Modified: trunk/Source/_javascript_Core/heap/MarkedBlock.cpp (206708 => 206709)


--- trunk/Source/_javascript_Core/heap/MarkedBlock.cpp	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/heap/MarkedBlock.cpp	2016-10-01 21:14:19 UTC (rev 206709)
@@ -388,16 +388,6 @@
     return isMarked(vm()->heap.objectSpace().markingVersion(), p);
 }
 
-bool MarkedBlock::Handle::isMarkedOrNewlyAllocated(const HeapCell* cell)
-{
-    return isMarkedOrNewlyAllocated(vm()->heap.objectSpace().markingVersion(), cell);
-}
-
-bool MarkedBlock::isMarkedOrNewlyAllocated(const HeapCell* cell)
-{
-    return isMarkedOrNewlyAllocated(vm()->heap.objectSpace().markingVersion(), cell);
-}
-
 void MarkedBlock::Handle::didConsumeFreeList()
 {
     if (false)

Modified: trunk/Source/_javascript_Core/heap/MarkedBlock.h (206708 => 206709)


--- trunk/Source/_javascript_Core/heap/MarkedBlock.h	2016-10-01 16:31:44 UTC (rev 206708)
+++ trunk/Source/_javascript_Core/heap/MarkedBlock.h	2016-10-01 21:14:19 UTC (rev 206709)
@@ -160,9 +160,6 @@
         bool isLive(const HeapCell*);
         bool isLiveCell(const void*);
 
-        bool isMarkedOrNewlyAllocated(const HeapCell*);
-        bool isMarkedOrNewlyAllocated(HeapVersion markingVersion, const HeapCell*);
-            
         bool isNewlyAllocated(const void*);
         void setNewlyAllocated(const void*);
         void clearNewlyAllocated(const void*);
@@ -256,9 +253,6 @@
     bool isMarkedConcurrently(HeapVersion markingVersion, const void*);
     bool testAndSetMarked(const void*);
         
-    bool isMarkedOrNewlyAllocated(const HeapCell*);
-    bool isMarkedOrNewlyAllocated(HeapVersion markingVersion, const HeapCell*);
-    
     bool isAtom(const void*);
     void clearMarked(const void*);
     
@@ -549,16 +543,6 @@
     return false;
 }
 
-inline bool MarkedBlock::Handle::isMarkedOrNewlyAllocated(HeapVersion markingVersion, const HeapCell* cell)
-{
-    return m_block->isMarked(markingVersion, cell) || (m_newlyAllocated && isNewlyAllocated(cell));
-}
-
-inline bool MarkedBlock::isMarkedOrNewlyAllocated(HeapVersion markingVersion, const HeapCell* cell)
-{
-    return isMarked(markingVersion, cell) || (m_handle.m_newlyAllocated && m_handle.isNewlyAllocated(cell));
-}
-
 inline bool MarkedBlock::isAtom(const void* p)
 {
     ASSERT(MarkedBlock::isAtomAligned(p));
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to