| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 419 } | 419 } |
| 420 if (start < end) { | 420 if (start < end) { |
| 421 StaticVisitor::VisitPointers(heap, | 421 StaticVisitor::VisitPointers(heap, |
| 422 descriptors->GetDescriptorStartSlot(start), | 422 descriptors->GetDescriptorStartSlot(start), |
| 423 descriptors->GetDescriptorEndSlot(end)); | 423 descriptors->GetDescriptorEndSlot(end)); |
| 424 } | 424 } |
| 425 | 425 |
| 426 // Mark prototype dependent codes array but do not push it onto marking | 426 // Mark prototype dependent codes array but do not push it onto marking |
| 427 // stack, this will make references from it weak. We will clean dead | 427 // stack, this will make references from it weak. We will clean dead |
| 428 // codes when we iterate over maps in ClearNonLiveTransitions. | 428 // codes when we iterate over maps in ClearNonLiveTransitions. |
| 429 Object** slot = HeapObject::RawField(map, Map::kDependentCodesOffset); | 429 Object** slot = HeapObject::RawField(map, Map::kDependentCodeOffset); |
| 430 HeapObject* obj = HeapObject::cast(*slot); | 430 HeapObject* obj = HeapObject::cast(*slot); |
| 431 heap->mark_compact_collector()->RecordSlot(slot, slot, obj); | 431 heap->mark_compact_collector()->RecordSlot(slot, slot, obj); |
| 432 StaticVisitor::MarkObjectWithoutPush(heap, obj); | 432 StaticVisitor::MarkObjectWithoutPush(heap, obj); |
| 433 | 433 |
| 434 // Mark the pointer fields of the Map. Since the transitions array has | 434 // Mark the pointer fields of the Map. Since the transitions array has |
| 435 // been marked already, it is fine that one of these fields contains a | 435 // been marked already, it is fine that one of these fields contains a |
| 436 // pointer to it. | 436 // pointer to it. |
| 437 StaticVisitor::VisitPointers(heap, | 437 StaticVisitor::VisitPointers(heap, |
| 438 HeapObject::RawField(map, Map::kPointerFieldsBeginOffset), | 438 HeapObject::RawField(map, Map::kPointerFieldsBeginOffset), |
| 439 HeapObject::RawField(map, Map::kPointerFieldsEndOffset)); | 439 HeapObject::RawField(map, Map::kPointerFieldsEndOffset)); |
| (...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 716 RelocIterator it(this, mode_mask); | 716 RelocIterator it(this, mode_mask); |
| 717 for (; !it.done(); it.next()) { | 717 for (; !it.done(); it.next()) { |
| 718 it.rinfo()->template Visit<StaticVisitor>(heap); | 718 it.rinfo()->template Visit<StaticVisitor>(heap); |
| 719 } | 719 } |
| 720 } | 720 } |
| 721 | 721 |
| 722 | 722 |
| 723 } } // namespace v8::internal | 723 } } // namespace v8::internal |
| 724 | 724 |
| 725 #endif // V8_OBJECTS_VISITING_INL_H_ | 725 #endif // V8_OBJECTS_VISITING_INL_H_ |
| OLD | NEW |