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 part of js_backend; | 5 part of js_backend; |
6 | 6 |
7 typedef void Recompile(Element element); | 7 typedef void Recompile(Element element); |
8 | 8 |
9 class ReturnInfo { | 9 class ReturnInfo { |
10 HType returnType; | 10 HType returnType; |
(...skipping 798 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
809 compiler.codegenWorld.addBailoutCode(work, codeBuffer); | 809 compiler.codegenWorld.addBailoutCode(work, codeBuffer); |
810 optimizer.prepareForSpeculativeOptimizations(work, graph); | 810 optimizer.prepareForSpeculativeOptimizations(work, graph); |
811 optimizer.optimize(work, graph, true); | 811 optimizer.optimize(work, graph, true); |
812 } | 812 } |
813 CodeBuffer codeBuffer = generator.generateCode(work, graph); | 813 CodeBuffer codeBuffer = generator.generateCode(work, graph); |
814 compiler.codegenWorld.addGeneratedCode(work, codeBuffer); | 814 compiler.codegenWorld.addGeneratedCode(work, codeBuffer); |
815 invalidateAfterCodegen.forEach(compiler.enqueuer.codegen.eagerRecompile); | 815 invalidateAfterCodegen.forEach(compiler.enqueuer.codegen.eagerRecompile); |
816 invalidateAfterCodegen.clear(); | 816 invalidateAfterCodegen.clear(); |
817 } | 817 } |
818 | 818 |
819 void processNativeClasses(Enqueuer world, | 819 |
820 Collection<LibraryElement> libraries) { | 820 native.NativeEnqueuer nativeResolutionEnqueuer(Enqueuer world) { |
821 native.processNativeClasses(world, emitter, libraries); | 821 return new native.NativeResolutionEnqueuer(world, compiler); |
| 822 } |
| 823 |
| 824 native.NativeEnqueuer nativeCodegenEnqueuer(Enqueuer world) { |
| 825 return new native.NativeCodegenEnqueuer(world, compiler, emitter); |
822 } | 826 } |
823 | 827 |
824 void assembleProgram() { | 828 void assembleProgram() { |
825 emitter.assembleProgram(); | 829 emitter.assembleProgram(); |
826 } | 830 } |
827 | 831 |
828 /** | 832 /** |
829 * Documentation wanted -- johnniwinther | 833 * Documentation wanted -- johnniwinther |
830 * | 834 * |
831 * Invariant: [element] must be a declaration element. | 835 * Invariant: [element] must be a declaration element. |
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1020 print("Inferred return types:"); | 1024 print("Inferred return types:"); |
1021 print("----------------------"); | 1025 print("----------------------"); |
1022 dumpReturnTypes(); | 1026 dumpReturnTypes(); |
1023 print(""); | 1027 print(""); |
1024 print("Inferred field types:"); | 1028 print("Inferred field types:"); |
1025 print("------------------------"); | 1029 print("------------------------"); |
1026 fieldTypes.dump(); | 1030 fieldTypes.dump(); |
1027 print(""); | 1031 print(""); |
1028 } | 1032 } |
1029 } | 1033 } |
OLD | NEW |