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 740 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
751 | 751 |
752 | 752 |
753 struct GraphBuilderPhase { | 753 struct GraphBuilderPhase { |
754 static const char* phase_name() { return "graph builder"; } | 754 static const char* phase_name() { return "graph builder"; } |
755 | 755 |
756 void Run(PipelineData* data, Zone* temp_zone) { | 756 void Run(PipelineData* data, Zone* temp_zone) { |
757 bool succeeded = false; | 757 bool succeeded = false; |
758 | 758 |
759 if (data->info()->is_optimizing_from_bytecode()) { | 759 if (data->info()->is_optimizing_from_bytecode()) { |
760 BytecodeGraphBuilder graph_builder(temp_zone, data->info(), | 760 BytecodeGraphBuilder graph_builder(temp_zone, data->info(), |
761 data->jsgraph(), 1.0f); | 761 data->jsgraph(), 1.0f, |
| 762 data->source_positions()); |
762 succeeded = graph_builder.CreateGraph(); | 763 succeeded = graph_builder.CreateGraph(); |
763 } else { | 764 } else { |
764 AstGraphBuilderWithPositions graph_builder( | 765 AstGraphBuilderWithPositions graph_builder( |
765 temp_zone, data->info(), data->jsgraph(), data->loop_assignment(), | 766 temp_zone, data->info(), data->jsgraph(), data->loop_assignment(), |
766 data->type_hint_analysis(), data->source_positions()); | 767 data->type_hint_analysis(), data->source_positions()); |
767 succeeded = graph_builder.CreateGraph(); | 768 succeeded = graph_builder.CreateGraph(); |
768 } | 769 } |
769 | 770 |
770 if (!succeeded) { | 771 if (!succeeded) { |
771 data->set_compilation_failed(); | 772 data->set_compilation_failed(); |
(...skipping 1212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1984 data->DeleteRegisterAllocationZone(); | 1985 data->DeleteRegisterAllocationZone(); |
1985 } | 1986 } |
1986 | 1987 |
1987 CompilationInfo* PipelineImpl::info() const { return data_->info(); } | 1988 CompilationInfo* PipelineImpl::info() const { return data_->info(); } |
1988 | 1989 |
1989 Isolate* PipelineImpl::isolate() const { return info()->isolate(); } | 1990 Isolate* PipelineImpl::isolate() const { return info()->isolate(); } |
1990 | 1991 |
1991 } // namespace compiler | 1992 } // namespace compiler |
1992 } // namespace internal | 1993 } // namespace internal |
1993 } // namespace v8 | 1994 } // namespace v8 |
OLD | NEW |