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

Side by Side Diff: test/mjsunit/array-feedback.js

Issue 397593008: Keep new arrays allocated with 'new Array(N)' in fast mode (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix slow test 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
« no previous file with comments | « test/mjsunit/array-constructor-feedback.js ('k') | test/mjsunit/array-splice.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 create1(0); 85 create1(0);
86 a = create1(0); 86 a = create1(0);
87 assertFalse(isHoley(a)); 87 assertFalse(isHoley(a));
88 assertKind(elements_kind.fast_smi_only, a); 88 assertKind(elements_kind.fast_smi_only, a);
89 a[0] = "hello"; 89 a[0] = "hello";
90 b = create1(10); 90 b = create1(10);
91 assertTrue(isHoley(b)); 91 assertTrue(isHoley(b));
92 assertKind(elements_kind.fast, b); 92 assertKind(elements_kind.fast, b);
93 93
94 a = create1(100000); 94 a = create1(100000);
95 assertKind(elements_kind.dictionary, a); 95 assertKind(elements_kind.fast_smi_only, a);
96 96
97 function create3(arg1, arg2, arg3) { 97 function create3(arg1, arg2, arg3) {
98 return Array(arg1, arg2, arg3); 98 return Array(arg1, arg2, arg3);
99 } 99 }
100 100
101 create3(1,2,3); 101 create3(1,2,3);
102 create3(1,2,3); 102 create3(1,2,3);
103 a = create3(1,2,3); 103 a = create3(1,2,3);
104 a[0] = 3.035; 104 a[0] = 3.035;
105 assertKind(elements_kind.fast_double, a); 105 assertKind(elements_kind.fast_double, a);
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 } 200 }
201 201
202 var realmBArray = Realm.eval(realmB, "Array"); 202 var realmBArray = Realm.eval(realmB, "Array");
203 instanceof_check(Array); 203 instanceof_check(Array);
204 instanceof_check(Array); 204 instanceof_check(Array);
205 instanceof_check(Array); 205 instanceof_check(Array);
206 instanceof_check(realmBArray); 206 instanceof_check(realmBArray);
207 instanceof_check(realmBArray); 207 instanceof_check(realmBArray);
208 instanceof_check(realmBArray); 208 instanceof_check(realmBArray);
209 })(); 209 })();
OLDNEW
« no previous file with comments | « test/mjsunit/array-constructor-feedback.js ('k') | test/mjsunit/array-splice.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698