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

Unified Diff: runtime/vm/verifier.cc

Issue 2497673004: Rehash canonical constants table for each class that can be affected by the 'become' operation (Closed)
Patch Set: Created 4 years, 1 month 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
Index: runtime/vm/verifier.cc
diff --git a/runtime/vm/verifier.cc b/runtime/vm/verifier.cc
index 5bc47657c107261cc2e1ae74b2218ed1d2de3b8c..fc1186764e5331819f20d61aa226e22b4575cdde 100644
--- a/runtime/vm/verifier.cc
+++ b/runtime/vm/verifier.cc
@@ -92,7 +92,12 @@ void VerifyCanonicalVisitor::VisitObject(RawObject* obj) {
if (obj->GetClassId() >= kInstanceCid) {
if (obj->IsCanonical()) {
instanceHandle_ ^= obj;
- ASSERT(instanceHandle_.CheckIsCanonical(thread_));
+ const bool is_canonical = instanceHandle_.CheckIsCanonical(thread_);
+ if (!is_canonical) {
+ OS::PrintErr("Instance `%s` is not canonical!\n",
+ instanceHandle_.ToCString());
+ }
+ ASSERT(is_canonical);
}
}
}

Powered by Google App Engine
This is Rietveld 408576698