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

Unified Diff: src/hydrogen.cc

Issue 6691058: Restart AST node numbering when we enter a function. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Incorporate codereview suggestions. Created 9 years, 8 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 | « src/ast.h ('k') | src/ia32/full-codegen-ia32.cc » ('j') | 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 fb2a287c9b991ed73abdc685e17bc89f05c833e5..189e326f0d9c215ceefb66717432ace8ed90cbbf 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -582,7 +582,7 @@ HGraph::HGraph(CompilationInfo* info)
phi_list_(NULL) {
start_environment_ =
new(zone()) HEnvironment(NULL, info->scope(), info->closure());
- start_environment_->set_ast_id(info->function()->id());
+ start_environment_->set_ast_id(AstNode::kFunctionEntryId);
entry_block_ = CreateBasicBlock();
entry_block_->SetInitialEnvironment(start_environment_);
}
@@ -2203,7 +2203,7 @@ HGraph* HGraphBuilder::CreateGraph() {
HEnvironment* initial_env = environment()->CopyWithoutHistory();
HBasicBlock* body_entry = CreateBasicBlock(initial_env);
current_block()->Goto(body_entry);
- body_entry->SetJoinId(info()->function()->id());
+ body_entry->SetJoinId(AstNode::kFunctionEntryId);
set_current_block(body_entry);
VisitStatements(info()->function()->body());
if (HasStackOverflow()) return NULL;
@@ -5663,7 +5663,7 @@ HEnvironment* HEnvironment::CopyForInlining(Handle<JSFunction> target,
inner->SetValueAt(local_base + i, undefined);
}
- inner->set_ast_id(function->id());
+ inner->set_ast_id(AstNode::kFunctionEntryId);
return inner;
}
« no previous file with comments | « src/ast.h ('k') | src/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698