OLD | NEW |
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/gc_marker.h" | 5 #include "vm/gc_marker.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
555 if (raw_obj->IsOldObject() && !raw_obj->IsMarked()) { | 555 if (raw_obj->IsOldObject() && !raw_obj->IsMarked()) { |
556 // Object has become garbage. Replace it will null. | 556 // Object has become garbage. Replace it will null. |
557 *current = Object::null(); | 557 *current = Object::null(); |
558 } | 558 } |
559 } | 559 } |
560 } | 560 } |
561 }; | 561 }; |
562 | 562 |
563 | 563 |
564 void GCMarker::ProcessObjectIdTable(Isolate* isolate) { | 564 void GCMarker::ProcessObjectIdTable(Isolate* isolate) { |
| 565 if (!FLAG_support_service) { |
| 566 return; |
| 567 } |
565 ObjectIdRingClearPointerVisitor visitor(isolate); | 568 ObjectIdRingClearPointerVisitor visitor(isolate); |
566 ObjectIdRing* ring = isolate->object_id_ring(); | 569 ObjectIdRing* ring = isolate->object_id_ring(); |
567 ASSERT(ring != NULL); | 570 ASSERT(ring != NULL); |
568 ring->VisitPointers(&visitor); | 571 ring->VisitPointers(&visitor); |
569 } | 572 } |
570 | 573 |
571 | 574 |
572 class MarkTask : public ThreadPool::Task { | 575 class MarkTask : public ThreadPool::Task { |
573 public: | 576 public: |
574 MarkTask(GCMarker* marker, | 577 MarkTask(GCMarker* marker, |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
742 barrier.Exit(); | 745 barrier.Exit(); |
743 } | 746 } |
744 delay_set.ClearReferences(); | 747 delay_set.ClearReferences(); |
745 ProcessWeakTables(page_space); | 748 ProcessWeakTables(page_space); |
746 ProcessObjectIdTable(isolate); | 749 ProcessObjectIdTable(isolate); |
747 } | 750 } |
748 Epilogue(isolate, invoke_api_callbacks); | 751 Epilogue(isolate, invoke_api_callbacks); |
749 } | 752 } |
750 | 753 |
751 } // namespace dart | 754 } // namespace dart |
OLD | NEW |