| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project 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 V8_HEAP_SCAVENGER_INL_H_ | 5 #ifndef V8_HEAP_SCAVENGER_INL_H_ |
| 6 #define V8_HEAP_SCAVENGER_INL_H_ | 6 #define V8_HEAP_SCAVENGER_INL_H_ |
| 7 | 7 |
| 8 #include "src/heap/scavenger.h" | 8 #include "src/heap/scavenger.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 return REMOVE_SLOT; | 63 return REMOVE_SLOT; |
| 64 } | 64 } |
| 65 | 65 |
| 66 // static | 66 // static |
| 67 void StaticScavengeVisitor::VisitPointer(Heap* heap, HeapObject* obj, | 67 void StaticScavengeVisitor::VisitPointer(Heap* heap, HeapObject* obj, |
| 68 Object** p) { | 68 Object** p) { |
| 69 Object* object = *p; | 69 Object* object = *p; |
| 70 if (!heap->InNewSpace(object)) return; | 70 if (!heap->InNewSpace(object)) return; |
| 71 Scavenger::ScavengeObject(reinterpret_cast<HeapObject**>(p), | 71 Scavenger::ScavengeObject(reinterpret_cast<HeapObject**>(p), |
| 72 reinterpret_cast<HeapObject*>(object), | 72 reinterpret_cast<HeapObject*>(object), |
| 73 DEFAULT_PROMOTION); | 73 heap->CurrentPromotionMode()); |
| 74 } | 74 } |
| 75 | 75 |
| 76 } // namespace internal | 76 } // namespace internal |
| 77 } // namespace v8 | 77 } // namespace v8 |
| 78 | 78 |
| 79 #endif // V8_HEAP_SCAVENGER_INL_H_ | 79 #endif // V8_HEAP_SCAVENGER_INL_H_ |
| OLD | NEW |