Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(539)

Side by Side Diff: runtime/vm/isolate.cc

Issue 1282423003: Enable iterating over roots from helper threads by moving stack walking. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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/isolate.h" 5 #include "vm/isolate.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "platform/json.h" 9 #include "platform/json.h"
10 #include "vm/code_observers.h" 10 #include "vm/code_observers.h"
(...skipping 1580 matching lines...) Expand 10 before | Expand all | Expand 10 after
1591 1591
1592 // Visit objects in the megamorphic cache. 1592 // Visit objects in the megamorphic cache.
1593 megamorphic_cache_table()->VisitObjectPointers(visitor); 1593 megamorphic_cache_table()->VisitObjectPointers(visitor);
1594 1594
1595 // Visit objects in per isolate stubs. 1595 // Visit objects in per isolate stubs.
1596 StubCode::VisitObjectPointers(visitor); 1596 StubCode::VisitObjectPointers(visitor);
1597 1597
1598 // Visit objects in isolate specific handles area. 1598 // Visit objects in isolate specific handles area.
1599 reusable_handles_.VisitObjectPointers(visitor); 1599 reusable_handles_.VisitObjectPointers(visitor);
1600 1600
1601 // Iterate over all the stack frames and visit objects on the stack.
1602 StackFrameIterator frames_iterator(validate_frames);
Ivan Posva 2015/08/11 17:41:31 Can you please explain how we are validating frame
1603 StackFrame* frame = frames_iterator.NextFrame();
1604 while (frame != NULL) {
1605 frame->VisitObjectPointers(visitor);
1606 frame = frames_iterator.NextFrame();
1607 }
1608
1609 // Visit the dart api state for all local and persistent handles. 1601 // Visit the dart api state for all local and persistent handles.
1610 if (api_state() != NULL) { 1602 if (api_state() != NULL) {
1611 api_state()->VisitObjectPointers(visitor, visit_prologue_weak_handles); 1603 api_state()->VisitObjectPointers(visitor, visit_prologue_weak_handles);
1612 } 1604 }
1613 1605
1614 // Visit the current tag which is stored in the isolate. 1606 // Visit the current tag which is stored in the isolate.
1615 visitor->VisitPointer(reinterpret_cast<RawObject**>(&current_tag_)); 1607 visitor->VisitPointer(reinterpret_cast<RawObject**>(&current_tag_));
1616 1608
1617 // Visit the default tag which is stored in the isolate. 1609 // Visit the default tag which is stored in the isolate.
1618 visitor->VisitPointer(reinterpret_cast<RawObject**>(&default_tag_)); 1610 visitor->VisitPointer(reinterpret_cast<RawObject**>(&default_tag_));
(...skipping 549 matching lines...) Expand 10 before | Expand all | Expand 10 after
2168 serialized_message_, serialized_message_len_); 2160 serialized_message_, serialized_message_len_);
2169 } 2161 }
2170 2162
2171 2163
2172 void IsolateSpawnState::Cleanup() { 2164 void IsolateSpawnState::Cleanup() {
2173 SwitchIsolateScope switch_scope(I); 2165 SwitchIsolateScope switch_scope(I);
2174 Dart::ShutdownIsolate(); 2166 Dart::ShutdownIsolate();
2175 } 2167 }
2176 2168
2177 } // namespace dart 2169 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/heap.cc ('k') | runtime/vm/pages.h » ('j') | runtime/vm/thread_registry.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698