| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 import '../common/codegen.dart' show CodegenWorkItem; | 5 import '../common/codegen.dart' show CodegenWorkItem; |
| 6 import '../compiler.dart' show Compiler; | 6 import '../compiler.dart' show Compiler; |
| 7 import '../constants/constant_system.dart'; | 7 import '../constants/constant_system.dart'; |
| 8 import '../constants/values.dart'; | 8 import '../constants/values.dart'; |
| 9 import '../elements/elements.dart'; | 9 import '../elements/elements.dart'; |
| 10 import '../js_backend/backend_helpers.dart' show BackendHelpers; | 10 import '../js_backend/backend_helpers.dart' show BackendHelpers; |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 if (element != null && backend.isNative(element)) { | 178 if (element != null && backend.isNative(element)) { |
| 179 return element; | 179 return element; |
| 180 } | 180 } |
| 181 } | 181 } |
| 182 | 182 |
| 183 return null; | 183 return null; |
| 184 } | 184 } |
| 185 | 185 |
| 186 HInstruction findDominator(Iterable<HInstruction> instructions) { | 186 HInstruction findDominator(Iterable<HInstruction> instructions) { |
| 187 HInstruction result; | 187 HInstruction result; |
| 188 L1: for (HInstruction candidate in instructions) { | 188 L1: |
| 189 for (HInstruction candidate in instructions) { |
| 189 for (HInstruction current in instructions) { | 190 for (HInstruction current in instructions) { |
| 190 if (current != candidate && !candidate.dominates(current)) continue L1; | 191 if (current != candidate && !candidate.dominates(current)) continue L1; |
| 191 } | 192 } |
| 192 result = candidate; | 193 result = candidate; |
| 193 break; | 194 break; |
| 194 } | 195 } |
| 195 return result; | 196 return result; |
| 196 } | 197 } |
| 197 | 198 |
| 198 bool visitInterceptor(HInterceptor node) { | 199 bool visitInterceptor(HInterceptor node) { |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 414 instruction = new HInvokeDynamicMethod( | 415 instruction = new HInvokeDynamicMethod( |
| 415 selector, mask, inputs, node.instructionType, true); | 416 selector, mask, inputs, node.instructionType, true); |
| 416 } | 417 } |
| 417 | 418 |
| 418 HBasicBlock block = node.block; | 419 HBasicBlock block = node.block; |
| 419 block.addAfter(node, instruction); | 420 block.addAfter(node, instruction); |
| 420 block.rewrite(node, instruction); | 421 block.rewrite(node, instruction); |
| 421 return true; | 422 return true; |
| 422 } | 423 } |
| 423 } | 424 } |
| OLD | NEW |