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

Unified Diff: runtime/vm/heap.cc

Issue 2622053002: Refactor snapshots pieces to include a section for loading instructions into the heap of a regular … (Closed)
Patch Set: . Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/heap.h ('k') | runtime/vm/isolate_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/heap.cc
diff --git a/runtime/vm/heap.cc b/runtime/vm/heap.cc
index c7ce678e19d4a5a890977be5377f5b9db85bcdda..4c9b73b1eb2bc91e3e0875b330d1d85e5efa7bf2 100644
--- a/runtime/vm/heap.cc
+++ b/runtime/vm/heap.cc
@@ -189,6 +189,17 @@ void Heap::VisitObjects(ObjectVisitor* visitor) const {
}
+void Heap::VisitObjectsNoExternalPages(ObjectVisitor* visitor) const {
+ new_space_.VisitObjects(visitor);
+ old_space_.VisitObjectsNoExternalPages(visitor);
+}
+
+
+void Heap::VisitObjectsExternalPages(ObjectVisitor* visitor) const {
+ old_space_.VisitObjectsExternalPages(visitor);
+}
+
+
HeapIterationScope::HeapIterationScope(bool writable)
: StackResource(Thread::Current()),
old_space_(isolate()->heap()->old_space()),
@@ -247,9 +258,9 @@ void Heap::IterateOldObjects(ObjectVisitor* visitor) const {
}
-void Heap::IterateOldObjectsNoEmbedderPages(ObjectVisitor* visitor) const {
+void Heap::IterateOldObjectsNoExternalPages(ObjectVisitor* visitor) const {
HeapIterationScope heap_iteration_scope;
- old_space_.VisitObjectsNoEmbedderPages(visitor);
+ old_space_.VisitObjectsNoExternalPages(visitor);
}
@@ -520,7 +531,12 @@ ObjectSet* Heap::CreateAllocatedObjectSet(
{
VerifyObjectVisitor object_visitor(isolate(), allocated_set,
mark_expectation);
- this->VisitObjects(&object_visitor);
+ this->VisitObjectsNoExternalPages(&object_visitor);
+ }
+ {
+ VerifyObjectVisitor object_visitor(isolate(), allocated_set,
+ kRequireMarked);
+ this->VisitObjectsExternalPages(&object_visitor);
}
Isolate* vm_isolate = Dart::vm_isolate();
« no previous file with comments | « runtime/vm/heap.h ('k') | runtime/vm/isolate_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698