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

Unified Diff: src/hydrogen.cc

Issue 21813004: Fix the loop-builder to tag the entire body as part of the loop. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 5 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 7e20aafb55825ac11de76f3b503fca0f08fcb1ff..86c6a0594a0a5cfca34d75467658a7607bb24f6a 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -957,8 +957,9 @@ void HGraphBuilder::LoopBuilder::EndBody() {
// Push the new increment value on the expression stack to merge into the phi.
builder_->environment()->Push(increment_);
- builder_->current_block()->GotoNoSimulate(header_block_);
- header_block_->loop_information()->RegisterBackEdge(body_block_);
+ HBasicBlock* last_block = builder_->current_block();
+ last_block->GotoNoSimulate(header_block_);
+ header_block_->loop_information()->RegisterBackEdge(last_block);
builder_->set_current_block(exit_block_);
// Pop the phi from the expression stack
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698