Status: Accepted
Owner: [email protected]
Labels: Type-Bug Priority-Medium
New issue 2339 by [email protected]: Wrong handling of constant operand 0
in integer multiplication.
http://code.google.com/p/v8/issues/detail?id=2339
Ar reported by rsturgell, this code snippet repeatedly deopts while
multiplying always_zero and always_five:
-------------------------
function simple() {
return simple_two_args(0, undefined);
}
function simple_two_args(always_zero, always_undefined) {
var always_five = always_undefined || 5;
return always_zero * always_five * .5;
}
for (var i = 0; i < 10000; i++) {
simple();
}
-------------------------
vegorov reduced the test case to "function for(a) { return a * 0; }" and
noted that the bug was introduced 1 year 7 month ago during porting of
crankshaft to x64 as a fix to issue 1117 but the fix is actually wrong (it
does produce correct result though).
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev