Commit 251c1918 authored by verwaest@chromium.org's avatar verwaest@chromium.org

Fix the loop-builder to tag the entire body as part of the loop.

R=danno@chromium.org

Review URL: https://chromiumcodereview.appspot.com/21813004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16041 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 14ed15e7
......@@ -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
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment