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

Unified Diff: src/compiler/verifier.cc

Issue 603533002: [turbofan] more verification of rpo (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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 | « no previous file | test/cctest/compiler/test-run-machops.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/verifier.cc
diff --git a/src/compiler/verifier.cc b/src/compiler/verifier.cc
index 23cec7a809794623625823e99d8f0b2688508d6b..972fec41b5dd3bcacf2152a708ec21494e36bb10 100644
--- a/src/compiler/verifier.cc
+++ b/src/compiler/verifier.cc
@@ -304,6 +304,17 @@ void ScheduleVerifier::Run(Schedule* schedule) {
for (BasicBlockVector::iterator b = rpo_order->begin(); b != rpo_order->end();
++b) {
CHECK_EQ((*b), schedule->GetBlockById((*b)->id()));
+ // All predecessors and successors should be in rpo and in this schedule.
+ BasicBlock::Predecessors p = (*b)->predecessors();
+ for (BasicBlock::Predecessors::iterator j = p.begin(); j != p.end(); ++j) {
+ CHECK_GE((*j)->rpo_number_, 0);
+ CHECK_EQ((*j), schedule->GetBlockById((*j)->id()));
+ }
+ BasicBlock::Successors s = (*b)->successors();
+ for (BasicBlock::Successors::iterator j = s.begin(); j != s.end(); ++j) {
+ CHECK_GE((*j)->rpo_number_, 0);
+ CHECK_EQ((*j), schedule->GetBlockById((*j)->id()));
+ }
}
// Verify RPO numbers of blocks.
« no previous file with comments | « no previous file | test/cctest/compiler/test-run-machops.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698