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

Side by Side Diff: src/compiler/pipeline.cc

Issue 1162563002: [turbofan] Remove the useless SimplifiedOperatorReducer. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « BUILD.gn ('k') | src/compiler/simplified-operator-reducer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/compiler/pipeline.h" 5 #include "src/compiler/pipeline.h"
6 6
7 #include <fstream> // NOLINT(readability/streams) 7 #include <fstream> // NOLINT(readability/streams)
8 #include <sstream> 8 #include <sstream>
9 9
10 #include "src/base/adapters.h" 10 #include "src/base/adapters.h"
(...skipping 25 matching lines...) Expand all
36 #include "src/compiler/machine-operator-reducer.h" 36 #include "src/compiler/machine-operator-reducer.h"
37 #include "src/compiler/move-optimizer.h" 37 #include "src/compiler/move-optimizer.h"
38 #include "src/compiler/osr.h" 38 #include "src/compiler/osr.h"
39 #include "src/compiler/pipeline-statistics.h" 39 #include "src/compiler/pipeline-statistics.h"
40 #include "src/compiler/register-allocator.h" 40 #include "src/compiler/register-allocator.h"
41 #include "src/compiler/register-allocator-verifier.h" 41 #include "src/compiler/register-allocator-verifier.h"
42 #include "src/compiler/schedule.h" 42 #include "src/compiler/schedule.h"
43 #include "src/compiler/scheduler.h" 43 #include "src/compiler/scheduler.h"
44 #include "src/compiler/select-lowering.h" 44 #include "src/compiler/select-lowering.h"
45 #include "src/compiler/simplified-lowering.h" 45 #include "src/compiler/simplified-lowering.h"
46 #include "src/compiler/simplified-operator-reducer.h"
47 #include "src/compiler/tail-call-optimization.h" 46 #include "src/compiler/tail-call-optimization.h"
48 #include "src/compiler/typer.h" 47 #include "src/compiler/typer.h"
49 #include "src/compiler/value-numbering-reducer.h" 48 #include "src/compiler/value-numbering-reducer.h"
50 #include "src/compiler/verifier.h" 49 #include "src/compiler/verifier.h"
51 #include "src/compiler/zone-pool.h" 50 #include "src/compiler/zone-pool.h"
52 #include "src/ostreams.h" 51 #include "src/ostreams.h"
53 #include "src/type-info.h" 52 #include "src/type-info.h"
54 #include "src/utils.h" 53 #include "src/utils.h"
55 54
56 namespace v8 { 55 namespace v8 {
(...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after
562 void Run(PipelineData* data, Zone* temp_zone) { 561 void Run(PipelineData* data, Zone* temp_zone) {
563 GraphReducer graph_reducer(data->graph(), temp_zone); 562 GraphReducer graph_reducer(data->graph(), temp_zone);
564 LoadElimination load_elimination; 563 LoadElimination load_elimination;
565 JSBuiltinReducer builtin_reducer(data->jsgraph()); 564 JSBuiltinReducer builtin_reducer(data->jsgraph());
566 JSTypedLowering typed_lowering(&graph_reducer, data->jsgraph(), temp_zone); 565 JSTypedLowering typed_lowering(&graph_reducer, data->jsgraph(), temp_zone);
567 JSIntrinsicLowering intrinsic_lowering( 566 JSIntrinsicLowering intrinsic_lowering(
568 &graph_reducer, data->jsgraph(), 567 &graph_reducer, data->jsgraph(),
569 data->info()->is_deoptimization_enabled() 568 data->info()->is_deoptimization_enabled()
570 ? JSIntrinsicLowering::kDeoptimizationEnabled 569 ? JSIntrinsicLowering::kDeoptimizationEnabled
571 : JSIntrinsicLowering::kDeoptimizationDisabled); 570 : JSIntrinsicLowering::kDeoptimizationDisabled);
572 SimplifiedOperatorReducer simple_reducer(data->jsgraph());
573 CommonOperatorReducer common_reducer(data->jsgraph()); 571 CommonOperatorReducer common_reducer(data->jsgraph());
574 AddReducer(data, &graph_reducer, &builtin_reducer); 572 AddReducer(data, &graph_reducer, &builtin_reducer);
575 AddReducer(data, &graph_reducer, &typed_lowering); 573 AddReducer(data, &graph_reducer, &typed_lowering);
576 AddReducer(data, &graph_reducer, &intrinsic_lowering); 574 AddReducer(data, &graph_reducer, &intrinsic_lowering);
577 AddReducer(data, &graph_reducer, &load_elimination); 575 AddReducer(data, &graph_reducer, &load_elimination);
578 AddReducer(data, &graph_reducer, &simple_reducer);
579 AddReducer(data, &graph_reducer, &common_reducer); 576 AddReducer(data, &graph_reducer, &common_reducer);
580 graph_reducer.ReduceGraph(); 577 graph_reducer.ReduceGraph();
581 } 578 }
582 }; 579 };
583 580
584 581
585 struct SimplifiedLoweringPhase { 582 struct SimplifiedLoweringPhase {
586 static const char* phase_name() { return "simplified lowering"; } 583 static const char* phase_name() { return "simplified lowering"; }
587 584
588 void Run(PipelineData* data, Zone* temp_zone) { 585 void Run(PipelineData* data, Zone* temp_zone) {
589 SimplifiedLowering lowering(data->jsgraph(), temp_zone, 586 SimplifiedLowering lowering(data->jsgraph(), temp_zone,
590 data->source_positions()); 587 data->source_positions());
591 lowering.LowerAllNodes(); 588 lowering.LowerAllNodes();
592 ValueNumberingReducer vn_reducer(temp_zone); 589 ValueNumberingReducer vn_reducer(temp_zone);
593 SimplifiedOperatorReducer simple_reducer(data->jsgraph());
594 MachineOperatorReducer machine_reducer(data->jsgraph()); 590 MachineOperatorReducer machine_reducer(data->jsgraph());
595 CommonOperatorReducer common_reducer(data->jsgraph()); 591 CommonOperatorReducer common_reducer(data->jsgraph());
596 GraphReducer graph_reducer(data->graph(), temp_zone); 592 GraphReducer graph_reducer(data->graph(), temp_zone);
597 AddReducer(data, &graph_reducer, &vn_reducer); 593 AddReducer(data, &graph_reducer, &vn_reducer);
598 AddReducer(data, &graph_reducer, &simple_reducer);
599 AddReducer(data, &graph_reducer, &machine_reducer); 594 AddReducer(data, &graph_reducer, &machine_reducer);
600 AddReducer(data, &graph_reducer, &common_reducer); 595 AddReducer(data, &graph_reducer, &common_reducer);
601 graph_reducer.ReduceGraph(); 596 graph_reducer.ReduceGraph();
602 } 597 }
603 }; 598 };
604 599
605 600
606 struct ControlFlowOptimizationPhase { 601 struct ControlFlowOptimizationPhase {
607 static const char* phase_name() { return "control flow optimization"; } 602 static const char* phase_name() { return "control flow optimization"; }
608 603
609 void Run(PipelineData* data, Zone* temp_zone) { 604 void Run(PipelineData* data, Zone* temp_zone) {
610 ControlFlowOptimizer optimizer(data->jsgraph(), temp_zone); 605 ControlFlowOptimizer optimizer(data->jsgraph(), temp_zone);
611 optimizer.Optimize(); 606 optimizer.Optimize();
612 } 607 }
613 }; 608 };
614 609
615 610
616 struct ChangeLoweringPhase { 611 struct ChangeLoweringPhase {
617 static const char* phase_name() { return "change lowering"; } 612 static const char* phase_name() { return "change lowering"; }
618 613
619 void Run(PipelineData* data, Zone* temp_zone) { 614 void Run(PipelineData* data, Zone* temp_zone) {
620 ValueNumberingReducer vn_reducer(temp_zone); 615 ValueNumberingReducer vn_reducer(temp_zone);
621 SimplifiedOperatorReducer simple_reducer(data->jsgraph());
622 ChangeLowering lowering(data->jsgraph()); 616 ChangeLowering lowering(data->jsgraph());
623 MachineOperatorReducer machine_reducer(data->jsgraph()); 617 MachineOperatorReducer machine_reducer(data->jsgraph());
624 CommonOperatorReducer common_reducer(data->jsgraph()); 618 CommonOperatorReducer common_reducer(data->jsgraph());
625 GraphReducer graph_reducer(data->graph(), temp_zone); 619 GraphReducer graph_reducer(data->graph(), temp_zone);
626 AddReducer(data, &graph_reducer, &vn_reducer); 620 AddReducer(data, &graph_reducer, &vn_reducer);
627 AddReducer(data, &graph_reducer, &simple_reducer);
628 AddReducer(data, &graph_reducer, &lowering); 621 AddReducer(data, &graph_reducer, &lowering);
629 AddReducer(data, &graph_reducer, &machine_reducer); 622 AddReducer(data, &graph_reducer, &machine_reducer);
630 AddReducer(data, &graph_reducer, &common_reducer); 623 AddReducer(data, &graph_reducer, &common_reducer);
631 graph_reducer.ReduceGraph(); 624 graph_reducer.ReduceGraph();
632 } 625 }
633 }; 626 };
634 627
635 628
636 struct EarlyControlReductionPhase { 629 struct EarlyControlReductionPhase {
637 static const char* phase_name() { return "early control reduction"; } 630 static const char* phase_name() { return "early control reduction"; }
(...skipping 688 matching lines...) Expand 10 before | Expand all | Expand 10 after
1326 tcf << AsC1VRegisterAllocationData("CodeGen", 1319 tcf << AsC1VRegisterAllocationData("CodeGen",
1327 data->register_allocation_data()); 1320 data->register_allocation_data());
1328 } 1321 }
1329 1322
1330 data->DeleteRegisterAllocationZone(); 1323 data->DeleteRegisterAllocationZone();
1331 } 1324 }
1332 1325
1333 } // namespace compiler 1326 } // namespace compiler
1334 } // namespace internal 1327 } // namespace internal
1335 } // namespace v8 1328 } // namespace v8
OLDNEW
« no previous file with comments | « BUILD.gn ('k') | src/compiler/simplified-operator-reducer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698