| 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 // Dart test program for constructors and initializers. | 4 // Dart test program for constructors and initializers. |
| 5 // VMOptions=--optimization-counter-threshold=10 --no-use-osr | 5 // VMOptions=--optimization-counter-threshold=10 --no-use-osr --no-background-co
mpilation |
| 6 | 6 |
| 7 import "package:expect/expect.dart"; | 7 import "package:expect/expect.dart"; |
| 8 | 8 |
| 9 // Check that range analysis does not enter infinite loop trying to propagate | 9 // Check that range analysis does not enter infinite loop trying to propagate |
| 10 // ranges through dependant phis. | 10 // ranges through dependant phis. |
| 11 bar() { | 11 bar() { |
| 12 var sum = 0; | 12 var sum = 0; |
| 13 for (var i = 0; i < 10; i++) { | 13 for (var i = 0; i < 10; i++) { |
| 14 for (var j = i - 1; j >= 0; j--) { | 14 for (var j = i - 1; j >= 0; j--) { |
| 15 for (var k = j; k < i; k++) { | 15 for (var k = j; k < i; k++) { |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 for (var i = 0; i < 20; i++) h(10); | 113 for (var i = 0; i < 20; i++) h(10); |
| 114 Expect.equals(10, h(10)); | 114 Expect.equals(10, h(10)); |
| 115 } | 115 } |
| 116 | 116 |
| 117 | 117 |
| 118 main() { | 118 main() { |
| 119 test1(); | 119 test1(); |
| 120 test2(); | 120 test2(); |
| 121 test3(); | 121 test3(); |
| 122 } | 122 } |
| OLD | NEW |