Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: tests/compiler/dart2js/js_backend_cps_ir_interceptors_test.dart

Issue 1007103003: cps-ir: Merge variables based on set-based liveness and graph coloring. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Rebase Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 // VMOptions=-DUSE_CPS_IR=true 4 // VMOptions=-DUSE_CPS_IR=true
5 5
6 // Tests of interceptors. 6 // Tests of interceptors.
7 7
8 library interceptors_tests; 8 library interceptors_tests;
9 9
10 import 'js_backend_cps_ir.dart'; 10 import 'js_backend_cps_ir.dart';
(...skipping 19 matching lines...) Expand all
30 print(l.length); 30 print(l.length);
31 for (int i = 0; i < l.length; i++) { 31 for (int i = 0; i < l.length; i++) {
32 var x = l[i]; 32 var x = l[i];
33 for (int j = 0; j < x.length; j++) { 33 for (int j = 0; j < x.length; j++) {
34 print(x[j]); 34 print(x[j]);
35 } 35 }
36 } 36 }
37 }""", 37 }""",
38 r""" 38 r"""
39 function() { 39 function() {
40 var l, i, v0, x, j, v1; 40 var l, i, v0, x, j;
41 l = ["hest", ["h", "e", "s", "t"]]; 41 l = ["hest", ["h", "e", "s", "t"]];
42 P.print(J.getInterceptor$as(l).get$length(l)); 42 P.print(J.getInterceptor$as(l).get$length(l));
43 i = 0; 43 i = 0;
44 L0: 44 L0:
45 while (true) { 45 while (true) {
46 v0 = J.getInterceptor$as(l).get$length(l); 46 v0 = J.getInterceptor$as(l).get$length(l);
47 if (P.identical(J.getInterceptor$n(i).$lt(i, v0), true)) { 47 if (P.identical(J.getInterceptor$n(i).$lt(i, v0), true)) {
48 x = J.getInterceptor$as(l).$index(l, i); 48 x = J.getInterceptor$as(l).$index(l, i);
49 j = 0; 49 j = 0;
50 while (true) { 50 while (true) {
51 v1 = J.getInterceptor$as(x).get$length(x); 51 v0 = J.getInterceptor$as(x).get$length(x);
52 if (P.identical(J.getInterceptor$n(j).$lt(j, v1), true)) { 52 if (P.identical(J.getInterceptor$n(j).$lt(j, v0), true)) {
53 P.print(J.getInterceptor$as(x).$index(x, j)); 53 P.print(J.getInterceptor$as(x).$index(x, j));
54 j = J.getInterceptor$ns(j).$add(j, 1); 54 j = J.getInterceptor$ns(j).$add(j, 1);
55 } else { 55 } else {
56 i = J.getInterceptor$ns(i).$add(i, 1); 56 i = J.getInterceptor$ns(i).$add(i, 1);
57 continue L0; 57 continue L0;
58 } 58 }
59 } 59 }
60 } else 60 } else
61 return null; 61 return null;
62 } 62 }
63 }"""), 63 }"""),
64 ]; 64 ];
65 65
66 66
67 void main() { 67 void main() {
68 runTests(tests); 68 runTests(tests);
69 } 69 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/tree_ir/tree_ir_builder.dart ('k') | tests/language/catch_liveness_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698