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

Unified Diff: src/compiler/pipeline.cc

Issue 726513002: [turbofan] Smartify the GraphReducer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE Created 6 years, 1 month 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/compiler/graph-reducer.cc ('k') | src/zone-containers.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/pipeline.cc
diff --git a/src/compiler/pipeline.cc b/src/compiler/pipeline.cc
index 3fdf826543557d2ed745635e0fe91740e6719f12..53a0afc8c5cdd137d242e7bb7f8d49e8e7162c48 100644
--- a/src/compiler/pipeline.cc
+++ b/src/compiler/pipeline.cc
@@ -384,12 +384,13 @@ Handle<Code> Pipeline::GenerateCode() {
{
// Lower JSOperators where we can determine types.
PhaseScope phase_scope(pipeline_statistics.get(), "typed lowering");
+ ZonePool::Scope zone_scope(data.zone_pool());
SourcePositionTable::Scope pos(data.source_positions(),
SourcePosition::Unknown());
ValueNumberingReducer vn_reducer(data.graph_zone());
JSTypedLowering lowering(data.jsgraph());
SimplifiedOperatorReducer simple_reducer(data.jsgraph());
- GraphReducer graph_reducer(data.graph());
+ GraphReducer graph_reducer(data.graph(), zone_scope.zone());
graph_reducer.AddReducer(&vn_reducer);
graph_reducer.AddReducer(&lowering);
graph_reducer.AddReducer(&simple_reducer);
@@ -400,13 +401,14 @@ Handle<Code> Pipeline::GenerateCode() {
{
// Lower simplified operators and insert changes.
PhaseScope phase_scope(pipeline_statistics.get(), "simplified lowering");
+ ZonePool::Scope zone_scope(data.zone_pool());
SourcePositionTable::Scope pos(data.source_positions(),
SourcePosition::Unknown());
SimplifiedLowering lowering(data.jsgraph());
lowering.LowerAllNodes();
ValueNumberingReducer vn_reducer(data.graph_zone());
SimplifiedOperatorReducer simple_reducer(data.jsgraph());
- GraphReducer graph_reducer(data.graph());
+ GraphReducer graph_reducer(data.graph(), zone_scope.zone());
graph_reducer.AddReducer(&vn_reducer);
graph_reducer.AddReducer(&simple_reducer);
graph_reducer.ReduceGraph();
@@ -416,6 +418,7 @@ Handle<Code> Pipeline::GenerateCode() {
{
// Lower changes that have been inserted before.
PhaseScope phase_scope(pipeline_statistics.get(), "change lowering");
+ ZonePool::Scope zone_scope(data.zone_pool());
SourcePositionTable::Scope pos(data.source_positions(),
SourcePosition::Unknown());
Linkage linkage(data.graph_zone(), info());
@@ -423,7 +426,7 @@ Handle<Code> Pipeline::GenerateCode() {
SimplifiedOperatorReducer simple_reducer(data.jsgraph());
ChangeLowering lowering(data.jsgraph(), &linkage);
MachineOperatorReducer mach_reducer(data.jsgraph());
- GraphReducer graph_reducer(data.graph());
+ GraphReducer graph_reducer(data.graph(), zone_scope.zone());
// TODO(titzer): Figure out if we should run all reducers at once here.
graph_reducer.AddReducer(&vn_reducer);
graph_reducer.AddReducer(&simple_reducer);
@@ -451,11 +454,12 @@ Handle<Code> Pipeline::GenerateCode() {
{
// Lower any remaining generic JSOperators.
PhaseScope phase_scope(pipeline_statistics.get(), "generic lowering");
+ ZonePool::Scope zone_scope(data.zone_pool());
SourcePositionTable::Scope pos(data.source_positions(),
SourcePosition::Unknown());
JSGenericLowering generic(info(), data.jsgraph());
SelectLowering select(data.jsgraph()->graph(), data.jsgraph()->common());
- GraphReducer graph_reducer(data.graph());
+ GraphReducer graph_reducer(data.graph(), zone_scope.zone());
graph_reducer.AddReducer(&generic);
graph_reducer.AddReducer(&select);
graph_reducer.ReduceGraph();
« no previous file with comments | « src/compiler/graph-reducer.cc ('k') | src/zone-containers.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698