| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_OBJECTS_VISITING_INL_H_ | 5 #ifndef V8_OBJECTS_VISITING_INL_H_ |
| 6 #define V8_OBJECTS_VISITING_INL_H_ | 6 #define V8_OBJECTS_VISITING_INL_H_ |
| 7 | 7 |
| 8 #include "src/heap/objects-visiting.h" | 8 #include "src/heap/objects-visiting.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 291 Heap* heap = map->GetHeap(); | 291 Heap* heap = map->GetHeap(); |
| 292 Map* map_object = Map::cast(object); | 292 Map* map_object = Map::cast(object); |
| 293 | 293 |
| 294 // Clears the cache of ICs related to this map. | 294 // Clears the cache of ICs related to this map. |
| 295 if (FLAG_cleanup_code_caches_at_gc) { | 295 if (FLAG_cleanup_code_caches_at_gc) { |
| 296 map_object->ClearCodeCache(heap); | 296 map_object->ClearCodeCache(heap); |
| 297 } | 297 } |
| 298 | 298 |
| 299 // When map collection is enabled we have to mark through map's transitions | 299 // When map collection is enabled we have to mark through map's transitions |
| 300 // and back pointers in a special way to make these links weak. | 300 // and back pointers in a special way to make these links weak. |
| 301 if (FLAG_collect_maps && map_object->CanTransition()) { | 301 if (map_object->CanTransition()) { |
| 302 MarkMapContents(heap, map_object); | 302 MarkMapContents(heap, map_object); |
| 303 } else { | 303 } else { |
| 304 StaticVisitor::VisitPointers( | 304 StaticVisitor::VisitPointers( |
| 305 heap, HeapObject::RawField(object, Map::kPointerFieldsBeginOffset), | 305 heap, HeapObject::RawField(object, Map::kPointerFieldsBeginOffset), |
| 306 HeapObject::RawField(object, Map::kPointerFieldsEndOffset)); | 306 HeapObject::RawField(object, Map::kPointerFieldsEndOffset)); |
| 307 } | 307 } |
| 308 } | 308 } |
| 309 | 309 |
| 310 | 310 |
| 311 template <typename StaticVisitor> | 311 template <typename StaticVisitor> |
| (...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 831 | 831 |
| 832 RelocIterator it(this, mode_mask); | 832 RelocIterator it(this, mode_mask); |
| 833 for (; !it.done(); it.next()) { | 833 for (; !it.done(); it.next()) { |
| 834 it.rinfo()->template Visit<StaticVisitor>(heap); | 834 it.rinfo()->template Visit<StaticVisitor>(heap); |
| 835 } | 835 } |
| 836 } | 836 } |
| 837 } | 837 } |
| 838 } // namespace v8::internal | 838 } // namespace v8::internal |
| 839 | 839 |
| 840 #endif // V8_OBJECTS_VISITING_INL_H_ | 840 #endif // V8_OBJECTS_VISITING_INL_H_ |
| OLD | NEW |