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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 final Compiler compiler; | 42 final Compiler compiler; |
43 final Element element; | 43 final Element element; |
44 HGraph graph; | 44 HGraph graph; |
45 | 45 |
46 SsaSimplifyInterceptors(this.compiler, this.constantSystem, this.element); | 46 SsaSimplifyInterceptors(this.compiler, this.constantSystem, this.element); |
47 | 47 |
48 JavaScriptBackend get backend => compiler.backend; | 48 JavaScriptBackend get backend => compiler.backend; |
49 | 49 |
50 BackendHelpers get helpers => backend.helpers; | 50 BackendHelpers get helpers => backend.helpers; |
51 | 51 |
52 ClassWorld get classWorld => compiler.world; | 52 ClassWorld get classWorld => compiler.closedWorld; |
53 | 53 |
54 void visitGraph(HGraph graph) { | 54 void visitGraph(HGraph graph) { |
55 this.graph = graph; | 55 this.graph = graph; |
56 visitDominatorTree(graph); | 56 visitDominatorTree(graph); |
57 } | 57 } |
58 | 58 |
59 void visitBasicBlock(HBasicBlock node) { | 59 void visitBasicBlock(HBasicBlock node) { |
60 currentBlock = node; | 60 currentBlock = node; |
61 | 61 |
62 HInstruction instruction = node.first; | 62 HInstruction instruction = node.first; |
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 instruction = new HInvokeDynamicMethod( | 415 instruction = new HInvokeDynamicMethod( |
416 selector, mask, inputs, node.instructionType, true); | 416 selector, mask, inputs, node.instructionType, true); |
417 } | 417 } |
418 | 418 |
419 HBasicBlock block = node.block; | 419 HBasicBlock block = node.block; |
420 block.addAfter(node, instruction); | 420 block.addAfter(node, instruction); |
421 block.rewrite(node, instruction); | 421 block.rewrite(node, instruction); |
422 return true; | 422 return true; |
423 } | 423 } |
424 } | 424 } |
OLD | NEW |