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

Unified Diff: runtime/vm/object.cc

Issue 1834333002: Precompilation: Don't look at embedder allocated pages when finalizing the VM isolate. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 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_test.cc ('k') | runtime/vm/pages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.cc
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index b0b4f4f57626a1215ed5c10b2efe8bfe7834c7d5..9d6b0fee82f8dbe6988e0030bdf88becf5040f2c 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -912,18 +912,10 @@ class PremarkingVisitor : public ObjectVisitor {
void VisitObject(RawObject* obj) {
// Free list elements should never be marked.
+ ASSERT(!obj->IsMarked());
if (!obj->IsFreeListElement()) {
ASSERT(obj->IsVMHeapObject());
- if (obj->IsMarked()) {
- // Precompiled objects are loaded pre-marked.
- ASSERT(Dart::IsRunningPrecompiledCode());
- ASSERT(obj->IsInstructions() ||
- obj->IsPcDescriptors() ||
- obj->IsStackmap() ||
- obj->IsOneByteString());
- } else {
- obj->SetMarkBitUnsynchronized();
- }
+ obj->SetMarkBitUnsynchronized();
}
}
};
@@ -994,11 +986,10 @@ void Object::FinalizeVMIsolate(Isolate* isolate) {
{
ASSERT(isolate == Dart::vm_isolate());
- bool include_code_pages = !Dart::IsRunningPrecompiledCode();
- WritableVMIsolateScope scope(Thread::Current(), include_code_pages);
+ WritableVMIsolateScope scope(Thread::Current());
PremarkingVisitor premarker(isolate);
ASSERT(isolate->heap()->UsedInWords(Heap::kNew) == 0);
- isolate->heap()->IterateOldObjects(&premarker);
+ isolate->heap()->IterateOldObjectsNoEmbedderPages(&premarker);
// Make the VM isolate read-only again after setting all objects as marked.
}
}
« no previous file with comments | « runtime/vm/heap_test.cc ('k') | runtime/vm/pages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698