| 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 // VMOptions=--optimization-counter-threshold=10 | 4 // VMOptions=--optimization-counter-threshold=10 --no-background-compilation |
| 5 | 5 |
| 6 import "package:expect/expect.dart"; | 6 import "package:expect/expect.dart"; |
| 7 | 7 |
| 8 constants() { | 8 constants() { |
| 9 Expect.equals(0, 499 >> 33); | 9 Expect.equals(0, 499 >> 33); |
| 10 Expect.equals(0, (499 << 33) & 0xFFFFFFFF); | 10 Expect.equals(0, (499 << 33) & 0xFFFFFFFF); |
| 11 Expect.equals(0, (499 << 32) >> 65); | 11 Expect.equals(0, (499 << 32) >> 65); |
| 12 Expect.equals(0, ((499 << 32) << 65) & 0xFFFFFFFFFFFFFFFF); | 12 Expect.equals(0, ((499 << 32) << 65) & 0xFFFFFFFFFFFFFFFF); |
| 13 } | 13 } |
| 14 | 14 |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 | 49 |
| 50 // JavaScript shifts by the amount modulo 32. That is x << y is equivalent to | 50 // JavaScript shifts by the amount modulo 32. That is x << y is equivalent to |
| 51 // x << (y & 0x1F). Dart does not. | 51 // x << (y & 0x1F). Dart does not. |
| 52 main() { | 52 main() { |
| 53 for (var i = 0; i < 10; ++i) { | 53 for (var i = 0; i < 10; ++i) { |
| 54 constants(); | 54 constants(); |
| 55 interceptors(); | 55 interceptors(); |
| 56 speculative(); | 56 speculative(); |
| 57 } | 57 } |
| 58 } | 58 } |
| OLD | NEW |