| Index: src/heap/heap.cc
|
| diff --git a/src/heap/heap.cc b/src/heap/heap.cc
|
| index a358feafe592c488ee1e0681da2e08790bde2945..6b460b93a2624c9ecfecbce14438edc392d63987 100644
|
| --- a/src/heap/heap.cc
|
| +++ b/src/heap/heap.cc
|
| @@ -1667,9 +1667,11 @@ void Heap::Scavenge() {
|
| {
|
| // Copy objects reachable from the old generation.
|
| TRACE_GC(tracer(), GCTracer::Scope::SCAVENGER_OLD_TO_NEW_POINTERS);
|
| - RememberedSet<OLD_TO_NEW>::Iterate(this, [this](Address addr) {
|
| - return Scavenger::CheckAndScavengeObject(this, addr, DEFAULT_PROMOTION);
|
| - });
|
| + PromotionMode promotion_mode = CurrentPromotionMode();
|
| + RememberedSet<OLD_TO_NEW>::Iterate(
|
| + this, [this, promotion_mode](Address addr) {
|
| + return Scavenger::CheckAndScavengeObject(this, addr, promotion_mode);
|
| + });
|
|
|
| RememberedSet<OLD_TO_NEW>::IterateTyped(
|
| this, [this](SlotType type, Address addr) {
|
|
|