| OLD | NEW |
| 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 13 matching lines...) Expand all Loading... |
| 24 #include "src/compiler/greedy-allocator.h" | 24 #include "src/compiler/greedy-allocator.h" |
| 25 #include "src/compiler/instruction.h" | 25 #include "src/compiler/instruction.h" |
| 26 #include "src/compiler/instruction-selector.h" | 26 #include "src/compiler/instruction-selector.h" |
| 27 #include "src/compiler/js-builtin-reducer.h" | 27 #include "src/compiler/js-builtin-reducer.h" |
| 28 #include "src/compiler/js-context-specialization.h" | 28 #include "src/compiler/js-context-specialization.h" |
| 29 #include "src/compiler/js-frame-specialization.h" | 29 #include "src/compiler/js-frame-specialization.h" |
| 30 #include "src/compiler/js-generic-lowering.h" | 30 #include "src/compiler/js-generic-lowering.h" |
| 31 #include "src/compiler/js-inlining.h" | 31 #include "src/compiler/js-inlining.h" |
| 32 #include "src/compiler/js-intrinsic-lowering.h" | 32 #include "src/compiler/js-intrinsic-lowering.h" |
| 33 #include "src/compiler/js-type-feedback.h" | 33 #include "src/compiler/js-type-feedback.h" |
| 34 #include "src/compiler/js-type-feedback-lowering.h" | |
| 35 #include "src/compiler/js-typed-lowering.h" | 34 #include "src/compiler/js-typed-lowering.h" |
| 36 #include "src/compiler/jump-threading.h" | 35 #include "src/compiler/jump-threading.h" |
| 37 #include "src/compiler/load-elimination.h" | 36 #include "src/compiler/load-elimination.h" |
| 38 #include "src/compiler/loop-analysis.h" | 37 #include "src/compiler/loop-analysis.h" |
| 39 #include "src/compiler/loop-peeling.h" | 38 #include "src/compiler/loop-peeling.h" |
| 40 #include "src/compiler/machine-operator-reducer.h" | 39 #include "src/compiler/machine-operator-reducer.h" |
| 41 #include "src/compiler/move-optimizer.h" | 40 #include "src/compiler/move-optimizer.h" |
| 42 #include "src/compiler/osr.h" | 41 #include "src/compiler/osr.h" |
| 43 #include "src/compiler/pipeline-statistics.h" | 42 #include "src/compiler/pipeline-statistics.h" |
| 44 #include "src/compiler/register-allocator.h" | 43 #include "src/compiler/register-allocator.h" |
| (...skipping 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 571 struct TypedLoweringPhase { | 570 struct TypedLoweringPhase { |
| 572 static const char* phase_name() { return "typed lowering"; } | 571 static const char* phase_name() { return "typed lowering"; } |
| 573 | 572 |
| 574 void Run(PipelineData* data, Zone* temp_zone) { | 573 void Run(PipelineData* data, Zone* temp_zone) { |
| 575 JSGraphReducer graph_reducer(data->jsgraph(), temp_zone); | 574 JSGraphReducer graph_reducer(data->jsgraph(), temp_zone); |
| 576 DeadCodeElimination dead_code_elimination(&graph_reducer, data->graph(), | 575 DeadCodeElimination dead_code_elimination(&graph_reducer, data->graph(), |
| 577 data->common()); | 576 data->common()); |
| 578 LoadElimination load_elimination(&graph_reducer); | 577 LoadElimination load_elimination(&graph_reducer); |
| 579 JSBuiltinReducer builtin_reducer(&graph_reducer, data->jsgraph()); | 578 JSBuiltinReducer builtin_reducer(&graph_reducer, data->jsgraph()); |
| 580 JSTypedLowering typed_lowering(&graph_reducer, data->jsgraph(), temp_zone); | 579 JSTypedLowering typed_lowering(&graph_reducer, data->jsgraph(), temp_zone); |
| 581 JSTypeFeedbackLowering type_feedback_lowering( | |
| 582 &graph_reducer, data->info()->is_deoptimization_enabled() | |
| 583 ? JSTypeFeedbackLowering::kDeoptimizationEnabled | |
| 584 : JSTypeFeedbackLowering::kNoFlags, | |
| 585 data->jsgraph()); | |
| 586 JSIntrinsicLowering intrinsic_lowering( | 580 JSIntrinsicLowering intrinsic_lowering( |
| 587 &graph_reducer, data->jsgraph(), | 581 &graph_reducer, data->jsgraph(), |
| 588 data->info()->is_deoptimization_enabled() | 582 data->info()->is_deoptimization_enabled() |
| 589 ? JSIntrinsicLowering::kDeoptimizationEnabled | 583 ? JSIntrinsicLowering::kDeoptimizationEnabled |
| 590 : JSIntrinsicLowering::kDeoptimizationDisabled); | 584 : JSIntrinsicLowering::kDeoptimizationDisabled); |
| 591 CommonOperatorReducer common_reducer(&graph_reducer, data->graph(), | 585 CommonOperatorReducer common_reducer(&graph_reducer, data->graph(), |
| 592 data->common(), data->machine()); | 586 data->common(), data->machine()); |
| 593 AddReducer(data, &graph_reducer, &dead_code_elimination); | 587 AddReducer(data, &graph_reducer, &dead_code_elimination); |
| 594 AddReducer(data, &graph_reducer, &builtin_reducer); | 588 AddReducer(data, &graph_reducer, &builtin_reducer); |
| 595 AddReducer(data, &graph_reducer, &typed_lowering); | 589 AddReducer(data, &graph_reducer, &typed_lowering); |
| 596 AddReducer(data, &graph_reducer, &intrinsic_lowering); | 590 AddReducer(data, &graph_reducer, &intrinsic_lowering); |
| 597 AddReducer(data, &graph_reducer, &type_feedback_lowering); | |
| 598 AddReducer(data, &graph_reducer, &load_elimination); | 591 AddReducer(data, &graph_reducer, &load_elimination); |
| 599 AddReducer(data, &graph_reducer, &common_reducer); | 592 AddReducer(data, &graph_reducer, &common_reducer); |
| 600 graph_reducer.ReduceGraph(); | 593 graph_reducer.ReduceGraph(); |
| 601 } | 594 } |
| 602 }; | 595 }; |
| 603 | 596 |
| 604 | 597 |
| 605 struct SimplifiedLoweringPhase { | 598 struct SimplifiedLoweringPhase { |
| 606 static const char* phase_name() { return "simplified lowering"; } | 599 static const char* phase_name() { return "simplified lowering"; } |
| 607 | 600 |
| (...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1357 tcf << AsC1VRegisterAllocationData("CodeGen", | 1350 tcf << AsC1VRegisterAllocationData("CodeGen", |
| 1358 data->register_allocation_data()); | 1351 data->register_allocation_data()); |
| 1359 } | 1352 } |
| 1360 | 1353 |
| 1361 data->DeleteRegisterAllocationZone(); | 1354 data->DeleteRegisterAllocationZone(); |
| 1362 } | 1355 } |
| 1363 | 1356 |
| 1364 } // namespace compiler | 1357 } // namespace compiler |
| 1365 } // namespace internal | 1358 } // namespace internal |
| 1366 } // namespace v8 | 1359 } // namespace v8 |
| OLD | NEW |