| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 class SsaCodeGeneratorTask extends CompilerTask { | 5 class SsaCodeGeneratorTask extends CompilerTask { |
| 6 final JavaScriptBackend backend; | 6 final JavaScriptBackend backend; |
| 7 SsaCodeGeneratorTask(JavaScriptBackend backend) | 7 SsaCodeGeneratorTask(JavaScriptBackend backend) |
| 8 : this.backend = backend, | 8 : this.backend = backend, |
| 9 super(backend.compiler); | 9 super(backend.compiler); |
| 10 String get name() => 'SSA code generator'; | 10 String get name() => 'SSA code generator'; |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 generateAtUseSite = new Set<HInstruction>(), | 217 generateAtUseSite = new Set<HInstruction>(), |
| 218 controlFlowOperators = new Set<HInstruction>(), | 218 controlFlowOperators = new Set<HInstruction>(), |
| 219 breakAction = new Map<Element, ElementAction>(), | 219 breakAction = new Map<Element, ElementAction>(), |
| 220 continueAction = new Map<Element, ElementAction>(), | 220 continueAction = new Map<Element, ElementAction>(), |
| 221 unsignedShiftPrecedences = JSPrecedence.binary['>>>'] { | 221 unsignedShiftPrecedences = JSPrecedence.binary['>>>'] { |
| 222 | 222 |
| 223 Interceptors interceptors = backend.builder.interceptors; | 223 Interceptors interceptors = backend.builder.interceptors; |
| 224 equalsNullElement = interceptors.getEqualsNullInterceptor(); | 224 equalsNullElement = interceptors.getEqualsNullInterceptor(); |
| 225 boolifiedEqualsNullElement = | 225 boolifiedEqualsNullElement = |
| 226 interceptors.getBoolifiedVersionOf(equalsNullElement); | 226 interceptors.getBoolifiedVersionOf(equalsNullElement); |
| 227 parameterNames.forEach((Element element, String name) { |
| 228 declaredVariables.add(name); |
| 229 }); |
| 227 } | 230 } |
| 228 | 231 |
| 229 abstract visitTypeGuard(HTypeGuard node); | 232 abstract visitTypeGuard(HTypeGuard node); |
| 230 | 233 |
| 231 abstract beginGraph(HGraph graph); | 234 abstract beginGraph(HGraph graph); |
| 232 abstract endGraph(HGraph graph); | 235 abstract endGraph(HGraph graph); |
| 233 | 236 |
| 234 abstract beginLoop(HBasicBlock block); | 237 abstract beginLoop(HBasicBlock block); |
| 235 abstract endLoop(HBasicBlock block); | 238 abstract endLoop(HBasicBlock block); |
| 236 abstract handleLoopCondition(HLoopBranch node); | 239 abstract handleLoopCondition(HLoopBranch node); |
| (...skipping 2586 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2823 startBailoutSwitch(); | 2826 startBailoutSwitch(); |
| 2824 } | 2827 } |
| 2825 } | 2828 } |
| 2826 | 2829 |
| 2827 void endLabeledBlock(HLabeledBlockInformation labeledBlockInfo) { | 2830 void endLabeledBlock(HLabeledBlockInformation labeledBlockInfo) { |
| 2828 if (labeledBlockInfo.body.start.hasGuards()) { | 2831 if (labeledBlockInfo.body.start.hasGuards()) { |
| 2829 endBailoutSwitch(); | 2832 endBailoutSwitch(); |
| 2830 } | 2833 } |
| 2831 } | 2834 } |
| 2832 } | 2835 } |
| OLD | NEW |