| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VisitorImpl_h | 5 #ifndef VisitorImpl_h |
| 6 #define VisitorImpl_h | 6 #define VisitorImpl_h |
| 7 | 7 |
| 8 #include "platform/heap/Heap.h" | 8 #include "platform/heap/Heap.h" |
| 9 #include "platform/heap/ThreadState.h" | 9 #include "platform/heap/ThreadState.h" |
| 10 #include "platform/heap/Visitor.h" | 10 #include "platform/heap/Visitor.h" |
| 11 #include "wtf/Allocator.h" | 11 #include "platform/wtf/Allocator.h" |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 inline void Visitor::markHeader(HeapObjectHeader* header, | 15 inline void Visitor::markHeader(HeapObjectHeader* header, |
| 16 const void* objectPointer, | 16 const void* objectPointer, |
| 17 TraceCallback callback) { | 17 TraceCallback callback) { |
| 18 DCHECK(header); | 18 DCHECK(header); |
| 19 DCHECK(objectPointer); | 19 DCHECK(objectPointer); |
| 20 | 20 |
| 21 if (header->isMarked()) | 21 if (header->isMarked()) |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 void* callbackData) { | 109 void* callbackData) { |
| 110 if (getMarkingMode() != GlobalMarkingWithCompaction) | 110 if (getMarkingMode() != GlobalMarkingWithCompaction) |
| 111 return; | 111 return; |
| 112 heap().registerMovingObjectCallback( | 112 heap().registerMovingObjectCallback( |
| 113 reinterpret_cast<MovableReference>(backingStore), callback, callbackData); | 113 reinterpret_cast<MovableReference>(backingStore), callback, callbackData); |
| 114 } | 114 } |
| 115 | 115 |
| 116 } // namespace blink | 116 } // namespace blink |
| 117 | 117 |
| 118 #endif | 118 #endif |
| OLD | NEW |