Sign in
webkit
/
WebKit
/
40afcbb21002c01b02495d31a13a88332533fb26
/
.
/
JSTests
/
microbenchmarks
/
check-mul-constant.js
blob: e4452ea4053d36b8138e48db0e054eb53dd90176 [
file
] [
log
] [
blame
]
function
doTest
(
max
)
{
let sum
=
0
for
(
let i
=
0
;
i
<
max
;
++
i
)
{
sum
=
sum
+
i
*
304
;
}
return
sum
}
noInline
(
doTest
);
for
(
let i
=
0
;
i
<
100000
;
++
i
)
doTest
(
10000
)
if
(
doTest
(
10000
)
!=
15198480000
)
throw
"Error: bad result: "
+
doTest
(
10000
);