blob: 681e3dc7d7a7a6b853f9eaa82d0ee83ce9767116 [file] [log] [blame]
//@ skip if $model == "Apple Watch Series 3" # added by mark-jsc-stress-test.py
var x = 1;
var o = {
get value() {
x ^= x * 3;
x = x | 1;
return x;
}
}
function foo(o) {
var result = 0;
for (var i = 0; i < 128; i++) {
result ^= o.value;
result |= 1
}
return result;
}
noInline(foo);
var result = 0;
for (var i = 0; i < 40000; ++i) {
result ^= foo(o);
result = result | 1;
}
if (result != -2004318071)
throw "Incorrect result: " + result + ". Should be -2004318071";