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 "src/base/platform/elapsed-timer.h" | 7 #include "src/base/platform/elapsed-timer.h" |
8 #include "src/compiler/ast-graph-builder.h" | 8 #include "src/compiler/ast-graph-builder.h" |
9 #include "src/compiler/code-generator.h" | 9 #include "src/compiler/code-generator.h" |
10 #include "src/compiler/graph-replay.h" | 10 #include "src/compiler/graph-replay.h" |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 // Lower JSOperators where we can determine types. | 163 // Lower JSOperators where we can determine types. |
164 PhaseStats lowering_stats(info(), PhaseStats::CREATE_GRAPH, | 164 PhaseStats lowering_stats(info(), PhaseStats::CREATE_GRAPH, |
165 "typed lowering"); | 165 "typed lowering"); |
166 JSTypedLowering lowering(&jsgraph, &source_positions); | 166 JSTypedLowering lowering(&jsgraph, &source_positions); |
167 lowering.LowerAllNodes(); | 167 lowering.LowerAllNodes(); |
168 | 168 |
169 VerifyAndPrintGraph(&graph, "Lowered typed"); | 169 VerifyAndPrintGraph(&graph, "Lowered typed"); |
170 } | 170 } |
171 } | 171 } |
172 | 172 |
173 { | 173 if (SupportedTarget()) { |
174 // Lower any remaining generic JSOperators. | 174 // Lower any remaining generic JSOperators. |
175 PhaseStats lowering_stats(info(), PhaseStats::CREATE_GRAPH, | 175 PhaseStats lowering_stats(info(), PhaseStats::CREATE_GRAPH, |
176 "generic lowering"); | 176 "generic lowering"); |
177 MachineOperatorBuilder machine(zone()); | 177 MachineOperatorBuilder machine(zone()); |
178 JSGenericLowering lowering(info(), &jsgraph, &machine, &source_positions); | 178 JSGenericLowering lowering(info(), &jsgraph, &machine, &source_positions); |
179 lowering.LowerAllNodes(); | 179 lowering.LowerAllNodes(); |
180 | 180 |
181 VerifyAndPrintGraph(&graph, "Lowered generic"); | 181 VerifyAndPrintGraph(&graph, "Lowered generic"); |
182 } | 182 } |
183 | 183 |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
283 } | 283 } |
284 | 284 |
285 // Generate native sequence. | 285 // Generate native sequence. |
286 CodeGenerator generator(&sequence); | 286 CodeGenerator generator(&sequence); |
287 return generator.GenerateCode(); | 287 return generator.GenerateCode(); |
288 } | 288 } |
289 | 289 |
290 } // namespace compiler | 290 } // namespace compiler |
291 } // namespace internal | 291 } // namespace internal |
292 } // namespace v8 | 292 } // namespace v8 |
OLD | NEW |