5
function runBinop(binop, lhs, rhs) {
6
return binop(lhs, rhs);
11
// Get the add function to compile.
13
for (var i = 0; i < 1000; ++i)
15
assertEq(accum, 2000);
17
// Get the runBinop function to compile and inline the add function.
19
for (var i = 0; i < 10100; ++i)
20
accum = runBinop(add, i, i);
21
assertEq(accum, 20198);
25
var result = runBinop(add, t31, t31);
26
assertEq(result, Math.pow(2, 32));