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

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

Issue 914133002: VM: Fix slow-path deoptimization environment. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 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
« no previous file with comments | « runtime/vm/intrinsifier.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2015, 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 // VMOptions=--stacktrace-every=3 --optimization-counter-threshold=10 --enable-i nlining-annotations
5
6 // Test generating stacktraces with inlining and deferred code.
7 // Regression test for issue dartbug.com/22331
8
9 class A {
10 final N;
11 final inc;
12 var next;
13 A(this.N, this.inc) {
14 next = this;
15 }
16 }
17
18 foo(o, value) {
19 for (var i = 0; i < o.N; i += o.inc) {
20 if (value < i) {
21 throw "";
22 }
23 o = o.next;
24 }
25 return value;
26 }
27
28 const NeverInline = 'NeverInline';
29
30 @NeverInline baz(x, y, z) => z;
31
32 bar(o) {
33 var value = 0x100000000 + o.inc;
34 baz(0, 0, foo(o, value));
35 }
36
37 main() {
38 var o = new A(10, 1);
39 for (var i = 0; i < 100; i++) bar(o);
40 bar(new A(100000, 1));
41 }
42
OLDNEW
« no previous file with comments | « runtime/vm/intrinsifier.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698