blob: 5c7b840a62156b698ef220000fc5d2898d9ece10 [file] [log] [blame]
//@ skip if $model == "Apple Watch Series 3" # added by mark-jsc-stress-test.py
function foo() {
var array = [];
for (var i = 0; i < 1000; ++i)
array.push(i + ((i % 2) ? 0.5 : 0));
var result = 0;
for (var i = 0; i < 1000; ++i) {
for (var j = 0; j < array.length; ++j)
result += array[j];
}
return result;
}
var result = foo();
if (result != 499750000)
throw "Bad result: " + result;