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

Side by Side Diff: tests/language/vm/optimized_identical_test.dart

Issue 26451006: VM: Fix bug in canonicalization of identical in the optimizing compiler. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 2 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
(Empty)
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
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.
4 // Test various optimizations and deoptimizations of optimizing compiler..
5 // VMOptions=--optimization-counter-threshold=10 --no-constant-propagation
6
7 import "package:expect/expect.dart";
8
9 // Test canonicalization of identical with double input.
10 // Constant propagation is disabled so that canonicalization is run
11 // one time less than usual.
12
13 test(a) {
14 var dbl = a + 1.0;
15 if (!identical(dbl, true)) {
16 return "ok";
17 }
18 throw "fail";
19 }
20
21 main() {
22 for (var i = 0; i < 20; i++) test(0);
23 Expect.equals("ok", test(0));
24 }
25
OLDNEW
« runtime/vm/intermediate_language.cc ('K') | « runtime/vm/intermediate_language.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698