expando-realloc-slots.js (396B)
1 function O() { 2 this.x0 = 1; 3 this.x1 = 1; 4 this.x2 = 1; 5 this.x3 = 1; 6 this.x4 = 1; 7 this.x5 = 1; 8 } 9 function f() { 10 var arr = []; 11 for (var i=0; i<1500; i++) 12 arr.push(new O); 13 for (var i=0; i<1500; i++) { 14 var o = arr[i]; 15 o.x10 = 1; 16 o.x11 = 1; 17 o.x12 = 1; 18 o.x13 = 1; 19 o.x14 = 1; 20 o.x15 = 1; 21 o.x16 = 1; 22 o.x17 = 1; 23 o.x18 = 1; 24 o.x19 = 1; 25 o.x20 = 1; 26 } 27 } 28 f();