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

Side by Side Diff: test/mjsunit/REMOVE_callic_behavior.js

Issue 445943002: CallIC must update type feedback info correctly. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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
« src/ic.cc ('K') | « src/ic.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 function foo() {
2 var a = new Array();
3 a[0] = 1;
4 return a;
5 }
6
7
8 function foo_other() {
9 var a = new Array();
10 a[0] = 2;
11 return a;
12 }
13
14
15 function bar(f1, f2) {
16 var accum = 0;
17 for (var i = 0; i < 100; i++) {
18 var a = f1();
19 var b = f2();
20 accum = a[0] + b[0];
21 }
22 }
23
24
25 // We should see function bar referenced in --trace-opt like so:
26 // [marking 0x5f540959 <JS Function bar (SharedFunctionInfo 0x5f5407d9)>
27 // for recompilation, reason: small function,
28 // ICs with typeinfo: 6/7 (85%), generic ICs: 1/7 (14%)]
29
30 for (var i = 0; i < 100000; i++) {
31 if (i % 2 == 0) {
32 bar(foo, foo);
33 } else {
34 bar(foo, foo_other);
35 }
36 }
37
OLDNEW
« src/ic.cc ('K') | « src/ic.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698