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

Unified Diff: runtime/vm/class_finalizer.cc

Issue 2995543004: [vm, gc] Require a safepoint for heap iteration. (Closed)
Patch Set: explicit-thread Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/benchmark_test.cc ('k') | runtime/vm/class_table.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/class_finalizer.cc
diff --git a/runtime/vm/class_finalizer.cc b/runtime/vm/class_finalizer.cc
index 1e877d94021a3319202d6940f52809bb82c721a2..39d74135827b415581a2bb65669d99e9ad04ef38 100644
--- a/runtime/vm/class_finalizer.cc
+++ b/runtime/vm/class_finalizer.cc
@@ -3654,13 +3654,14 @@ class CidRewriteVisitor : public ObjectVisitor {
};
void ClassFinalizer::RemapClassIds(intptr_t* old_to_new_cid) {
- Isolate* I = Thread::Current()->isolate();
+ Thread* T = Thread::Current();
+ Isolate* I = T->isolate();
// Code, ICData, allocation stubs have now-invalid cids.
ClearAllCode();
{
- HeapIterationScope his;
+ HeapIterationScope his(T);
I->set_remapping_cids(true);
// Update the class table. Do it before rewriting cids in headers, as the
@@ -3720,7 +3721,7 @@ void ClassFinalizer::RehashTypes() {
// Clear all cached hash values.
{
- HeapIterationScope his;
+ HeapIterationScope his(T);
ClearTypeHashVisitor visitor(Z);
I->heap()->VisitObjects(&visitor);
}
« no previous file with comments | « runtime/vm/benchmark_test.cc ('k') | runtime/vm/class_table.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698