Index: Source/platform/heap/Heap.h |
diff --git a/Source/platform/heap/Heap.h b/Source/platform/heap/Heap.h |
index 07312d258e0f0ac6630af91ec587a49e7b3063b3..05e20f6ecb3cd3bf8757d002345dc8b1801a1fbf 100644 |
--- a/Source/platform/heap/Heap.h |
+++ b/Source/platform/heap/Heap.h |
@@ -1497,6 +1497,7 @@ Address HeapObjectHeader::payloadEnd() |
return reinterpret_cast<Address>(this) + size(); |
} |
+NO_SANITIZE_ADDRESS |
void HeapObjectHeader::mark() |
{ |
checkHeader(); |
@@ -1505,12 +1506,13 @@ void HeapObjectHeader::mark() |
// Multiple threads can still read the old value and all store the |
// new value. However, the new value will be the same for all of |
// the threads and the end result is therefore consistent. |
- // We need to unpoison/poison the header on ASAN since |
- // acquireLoad/releaseStore don't have the NO_SANITIZE_ADDRESS flag. |
- ASAN_UNPOISON_MEMORY_REGION(this, sizeof(this)); |
+#if defined(ADDRESS_SANITIZER) |
zerny-chromium
2014/09/09 06:01:28
I'd prefer to avoid the code duplication by defini
Mads Ager (chromium)
2014/09/09 08:22:14
Done.
|
+ unsigned size = asanAcquireLoad(&m_size); |
+ asanReleaseStore(&m_size, size | markBitMask); |
+#else |
unsigned size = acquireLoad(&m_size); |
releaseStore(&m_size, size | markBitMask); |
- ASAN_POISON_MEMORY_REGION(this, sizeof(this)); |
+#endif |
} |
Address FinalizedHeapObjectHeader::payload() |