Index: Source/platform/heap/ThreadState.h |
diff --git a/Source/platform/heap/ThreadState.h b/Source/platform/heap/ThreadState.h |
index d44c39c32daa7d57547ba208aebe2b50c0593265..213170db701f44d52e20cb88735a751a38d74add 100644 |
--- a/Source/platform/heap/ThreadState.h |
+++ b/Source/platform/heap/ThreadState.h |
@@ -144,11 +144,11 @@ using EphemeronCallback = VisitorCallback; |
#define TypedHeapEnumName(Type) Type##HeapIndex, |
enum HeapIndices { |
- NormalPage1HeapIndex = 0, |
+ EagerSweepHeapIndex = 0, |
+ NormalPage1HeapIndex, |
NormalPage2HeapIndex, |
NormalPage3HeapIndex, |
NormalPage4HeapIndex, |
- EagerSweepHeapIndex, |
Vector1HeapIndex, |
Vector2HeapIndex, |
Vector3HeapIndex, |
@@ -161,6 +161,20 @@ enum HeapIndices { |
NumberOfHeaps, |
}; |
+#if defined(ADDRESS_SANITIZER) |
+// Heaps can have their object payloads be poisoned, or cleared |
+// of their poisoning. |
+enum Poisoning { |
+ SetPoison, |
+ ClearPoison, |
+}; |
+ |
+enum ObjectsToPoison { |
+ UnmarkedOnly, |
+ MarkedAndUnmarked, |
+}; |
+#endif |
+ |
#if ENABLE(GC_PROFILING) |
const size_t numberOfGenerationsToTrack = 8; |
const size_t maxHeapObjectAge = numberOfGenerationsToTrack - 1; |
@@ -646,6 +660,11 @@ private: |
void eagerSweep(); |
+#if defined(ADDRESS_SANITIZER) |
+ void poisonEagerHeap(Poisoning); |
+ void poisonAllHeaps(); |
+#endif |
+ |
// When ThreadState is detaching from non-main thread its |
// heap is expected to be empty (because it is going away). |
// Perform registered cleanup tasks and garbage collection |