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

Side by Side Diff: tests/language/math_vm_test.dart

Issue 12038013: Reland r17365. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: replace enter with EnterFrame Created 7 years, 11 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) 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 // Tests that the VM does not crash on weird corner cases of class Math. 4 // Tests that the VM does not crash on weird corner cases of class Math.
5 // VMOptions=--optimization_counter_threshold=100 5 // VMOptions=--optimization_counter_threshold=100
6 6
7 library math_vm_test; 7 library math_vm_test;
8 8
9 import 'dart:math'; 9 import 'dart:math';
10 10
(...skipping 19 matching lines...) Expand all
30 } catch (e) { 30 } catch (e) {
31 return false; 31 return false;
32 } 32 }
33 } 33 }
34 34
35 static void testMain() { 35 static void testMain() {
36 Expect.equals(false, testParseInt(5)); 36 Expect.equals(false, testParseInt(5));
37 Expect.equals(false, testSqrt(const FakeNumber())); 37 Expect.equals(false, testSqrt(const FakeNumber()));
38 } 38 }
39 } 39 }
40
41 testDoublePow() {
42 Expect.equals((1 << 32).toDouble(), pow(2.0, 32));
43 }
44
45
40 main() { 46 main() {
41 for (int i = 0; i < 200; i++) { 47 for (int i = 0; i < 200; i++) {
Florian Schneider 2013/01/22 11:22:34 Not sure if 200 is enough to get it optimized reli
Vyacheslav Egorov (Google) 2013/01/22 11:36:31 This tests comes with VMOptions=--optimization_co
42 MathTest.testMain(); 48 MathTest.testMain();
49 testDoublePow();
43 } 50 }
44 } 51 }
OLDNEW
« runtime/vm/intermediate_language_x64.cc ('K') | « runtime/vm/locations.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698