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

Unified Diff: src/data-flow.cc

Issue 3561012: More refactoring of class Compiler's interface. (Closed)
Patch Set: Reindent some code, change some copyright dates. Created 10 years, 2 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
« src/compiler.h ('K') | « src/data-flow.h ('k') | src/full-codegen.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/data-flow.cc
diff --git a/src/data-flow.cc b/src/data-flow.cc
index 02aacb5b81f8c20c354cf8ac0a234b42b36b74c0..be824460f0a1fb1b559cccc89391912c84ff784c 100644
--- a/src/data-flow.cc
+++ b/src/data-flow.cc
@@ -50,12 +50,13 @@ void BitVector::Print() {
#endif
-bool AssignedVariablesAnalyzer::Analyze() {
- Scope* scope = fun_->scope();
+bool AssignedVariablesAnalyzer::Analyze(CompilationInfo* info) {
+ info_ = info;
+ Scope* scope = info->scope();
int variables = scope->num_parameters() + scope->num_stack_slots();
if (variables == 0) return true;
av_.ExpandTo(variables);
- VisitStatements(fun_->body());
+ VisitStatements(info->function()->body());
return !HasStackOverflow();
}
@@ -129,7 +130,7 @@ int AssignedVariablesAnalyzer::BitIndex(Variable* var) {
if (slot->type() == Slot::PARAMETER) {
return slot->index();
} else {
- return fun_->scope()->num_parameters() + slot->index();
+ return info_->scope()->num_parameters() + slot->index();
}
}
« src/compiler.h ('K') | « src/data-flow.h ('k') | src/full-codegen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698