Index: test/mjsunit/polymorph-arrays.js |
diff --git a/test/mjsunit/polymorph-arrays.js b/test/mjsunit/polymorph-arrays.js |
index 2bb0433214e934d5812f14d221dfd5dff8ead4ad..ff0c433bd76a398b1679ebe51437365735495074 100644 |
--- a/test/mjsunit/polymorph-arrays.js |
+++ b/test/mjsunit/polymorph-arrays.js |
@@ -37,7 +37,7 @@ function init_sparse_array(a) { |
a[i] = i; |
} |
a[5000000] = 256; |
- return %NormalizeElements(a); |
+ assertTrue(%HasDictionaryElements(a)); |
} |
function testPolymorphicLoads() { |
@@ -49,7 +49,7 @@ function testPolymorphicLoads() { |
var object_array = new Object; |
var sparse_object_array = new Object; |
var js_array = new Array(10); |
- var sparse_js_array = %NormalizeElements([]); |
+ var sparse_js_array = new Array(5000001); |
init_array(object_array); |
init_array(js_array); |
@@ -67,7 +67,7 @@ function testPolymorphicLoads() { |
var object_array = new Object; |
var sparse_object_array = new Object; |
var js_array = new Array(10); |
- var sparse_js_array = %NormalizeElements([]); |
+ var sparse_js_array = new Array(5000001); |
init_array(object_array); |
init_array(js_array); |
@@ -114,8 +114,7 @@ function testPolymorphicStores() { |
var object_array = new Object; |
var sparse_object_array = new Object; |
var js_array = new Array(10); |
- var sparse_js_array = []; |
- sparse_js_array.length = 5000001; |
+ var sparse_js_array = new Array(5000001); |
init_array(object_array); |
init_array(js_array); |
@@ -133,8 +132,7 @@ function testPolymorphicStores() { |
var object_array = new Object; |
var sparse_object_array = new Object; |
var js_array = new Array(10); |
- var sparse_js_array = %NormalizeElements([]); |
- sparse_js_array.length = 5000001; |
+ var sparse_js_array = new Array(5000001); |
init_array(object_array); |
init_array(js_array); |