| 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 <memory> | 8 #include <memory> |
| 9 #include <sstream> | 9 #include <sstream> |
| 10 | 10 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 #include "src/compiler/frame-elider.h" | 28 #include "src/compiler/frame-elider.h" |
| 29 #include "src/compiler/graph-replay.h" | 29 #include "src/compiler/graph-replay.h" |
| 30 #include "src/compiler/graph-trimmer.h" | 30 #include "src/compiler/graph-trimmer.h" |
| 31 #include "src/compiler/graph-visualizer.h" | 31 #include "src/compiler/graph-visualizer.h" |
| 32 #include "src/compiler/instruction-selector.h" | 32 #include "src/compiler/instruction-selector.h" |
| 33 #include "src/compiler/instruction.h" | 33 #include "src/compiler/instruction.h" |
| 34 #include "src/compiler/js-builtin-reducer.h" | 34 #include "src/compiler/js-builtin-reducer.h" |
| 35 #include "src/compiler/js-call-reducer.h" | 35 #include "src/compiler/js-call-reducer.h" |
| 36 #include "src/compiler/js-context-specialization.h" | 36 #include "src/compiler/js-context-specialization.h" |
| 37 #include "src/compiler/js-create-lowering.h" | 37 #include "src/compiler/js-create-lowering.h" |
| 38 #include "src/compiler/js-for-in-lowering.h" |
| 38 #include "src/compiler/js-frame-specialization.h" | 39 #include "src/compiler/js-frame-specialization.h" |
| 39 #include "src/compiler/js-generic-lowering.h" | 40 #include "src/compiler/js-generic-lowering.h" |
| 40 #include "src/compiler/js-inlining-heuristic.h" | 41 #include "src/compiler/js-inlining-heuristic.h" |
| 41 #include "src/compiler/js-intrinsic-lowering.h" | 42 #include "src/compiler/js-intrinsic-lowering.h" |
| 42 #include "src/compiler/js-native-context-specialization.h" | 43 #include "src/compiler/js-native-context-specialization.h" |
| 43 #include "src/compiler/js-typed-lowering.h" | 44 #include "src/compiler/js-typed-lowering.h" |
| 44 #include "src/compiler/jump-threading.h" | 45 #include "src/compiler/jump-threading.h" |
| 45 #include "src/compiler/live-range-separator.h" | 46 #include "src/compiler/live-range-separator.h" |
| 46 #include "src/compiler/load-elimination.h" | 47 #include "src/compiler/load-elimination.h" |
| 47 #include "src/compiler/loop-analysis.h" | 48 #include "src/compiler/loop-analysis.h" |
| (...skipping 857 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 905 &graph_reducer, data->jsgraph(), | 906 &graph_reducer, data->jsgraph(), |
| 906 data->info()->is_deoptimization_enabled() | 907 data->info()->is_deoptimization_enabled() |
| 907 ? JSBuiltinReducer::kDeoptimizationEnabled | 908 ? JSBuiltinReducer::kDeoptimizationEnabled |
| 908 : JSBuiltinReducer::kNoFlags, | 909 : JSBuiltinReducer::kNoFlags, |
| 909 data->info()->dependencies(), data->native_context()); | 910 data->info()->dependencies(), data->native_context()); |
| 910 Handle<FeedbackVector> feedback_vector( | 911 Handle<FeedbackVector> feedback_vector( |
| 911 data->info()->closure()->feedback_vector()); | 912 data->info()->closure()->feedback_vector()); |
| 912 JSCreateLowering create_lowering( | 913 JSCreateLowering create_lowering( |
| 913 &graph_reducer, data->info()->dependencies(), data->jsgraph(), | 914 &graph_reducer, data->info()->dependencies(), data->jsgraph(), |
| 914 feedback_vector, data->native_context(), temp_zone); | 915 feedback_vector, data->native_context(), temp_zone); |
| 916 JSForInLowering for_in_lowering(&graph_reducer, data->jsgraph()); |
| 915 JSTypedLowering::Flags typed_lowering_flags = JSTypedLowering::kNoFlags; | 917 JSTypedLowering::Flags typed_lowering_flags = JSTypedLowering::kNoFlags; |
| 916 if (data->info()->is_deoptimization_enabled()) { | 918 if (data->info()->is_deoptimization_enabled()) { |
| 917 typed_lowering_flags |= JSTypedLowering::kDeoptimizationEnabled; | 919 typed_lowering_flags |= JSTypedLowering::kDeoptimizationEnabled; |
| 918 } | 920 } |
| 919 JSTypedLowering typed_lowering(&graph_reducer, data->info()->dependencies(), | 921 JSTypedLowering typed_lowering(&graph_reducer, data->info()->dependencies(), |
| 920 typed_lowering_flags, data->jsgraph(), | 922 typed_lowering_flags, data->jsgraph(), |
| 921 temp_zone); | 923 temp_zone); |
| 922 TypedOptimization typed_optimization( | 924 TypedOptimization typed_optimization( |
| 923 &graph_reducer, data->info()->dependencies(), | 925 &graph_reducer, data->info()->dependencies(), |
| 924 data->info()->is_deoptimization_enabled() | 926 data->info()->is_deoptimization_enabled() |
| 925 ? TypedOptimization::kDeoptimizationEnabled | 927 ? TypedOptimization::kDeoptimizationEnabled |
| 926 : TypedOptimization::kNoFlags, | 928 : TypedOptimization::kNoFlags, |
| 927 data->jsgraph()); | 929 data->jsgraph()); |
| 928 SimplifiedOperatorReducer simple_reducer(&graph_reducer, data->jsgraph()); | 930 SimplifiedOperatorReducer simple_reducer(&graph_reducer, data->jsgraph()); |
| 929 CheckpointElimination checkpoint_elimination(&graph_reducer); | 931 CheckpointElimination checkpoint_elimination(&graph_reducer); |
| 930 CommonOperatorReducer common_reducer(&graph_reducer, data->graph(), | 932 CommonOperatorReducer common_reducer(&graph_reducer, data->graph(), |
| 931 data->common(), data->machine()); | 933 data->common(), data->machine()); |
| 932 AddReducer(data, &graph_reducer, &dead_code_elimination); | 934 AddReducer(data, &graph_reducer, &dead_code_elimination); |
| 933 AddReducer(data, &graph_reducer, &builtin_reducer); | 935 AddReducer(data, &graph_reducer, &builtin_reducer); |
| 934 if (data->info()->is_deoptimization_enabled()) { | 936 if (data->info()->is_deoptimization_enabled()) { |
| 935 AddReducer(data, &graph_reducer, &create_lowering); | 937 AddReducer(data, &graph_reducer, &create_lowering); |
| 936 } | 938 } |
| 939 AddReducer(data, &graph_reducer, &for_in_lowering); |
| 937 AddReducer(data, &graph_reducer, &typed_optimization); | 940 AddReducer(data, &graph_reducer, &typed_optimization); |
| 938 AddReducer(data, &graph_reducer, &typed_lowering); | 941 AddReducer(data, &graph_reducer, &typed_lowering); |
| 939 AddReducer(data, &graph_reducer, &simple_reducer); | 942 AddReducer(data, &graph_reducer, &simple_reducer); |
| 940 AddReducer(data, &graph_reducer, &checkpoint_elimination); | 943 AddReducer(data, &graph_reducer, &checkpoint_elimination); |
| 941 AddReducer(data, &graph_reducer, &common_reducer); | 944 AddReducer(data, &graph_reducer, &common_reducer); |
| 942 graph_reducer.ReduceGraph(); | 945 graph_reducer.ReduceGraph(); |
| 943 } | 946 } |
| 944 }; | 947 }; |
| 945 | 948 |
| 946 | 949 |
| (...skipping 1077 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2024 data->DeleteRegisterAllocationZone(); | 2027 data->DeleteRegisterAllocationZone(); |
| 2025 } | 2028 } |
| 2026 | 2029 |
| 2027 CompilationInfo* PipelineImpl::info() const { return data_->info(); } | 2030 CompilationInfo* PipelineImpl::info() const { return data_->info(); } |
| 2028 | 2031 |
| 2029 Isolate* PipelineImpl::isolate() const { return info()->isolate(); } | 2032 Isolate* PipelineImpl::isolate() const { return info()->isolate(); } |
| 2030 | 2033 |
| 2031 } // namespace compiler | 2034 } // namespace compiler |
| 2032 } // namespace internal | 2035 } // namespace internal |
| 2033 } // namespace v8 | 2036 } // namespace v8 |
| OLD | NEW |