DescriptionChange heuristics for deciding phi-representation types to use int32 more frequently.
Until now we conservatively chose a double representation if
at least one use occurs in a double operation. This causes performance
degradation in many cases where there are mixes uses (integer and double)
e.g.:
for (int i = 0; i < 10; i++) {
var t = i / 3.5;
a[i] = t;
}
where the use in i/3 requires a double, where as the keyed store requires i
as an integer.
For these cases we want to have i as an integer and convert it only before the
double division.
In order to avoid unconditional deoptimization in some rare cases, we check
phis if there is any conversion that will always fail when converting a
heap-number constant to int32.
Committed: http://code.google.com/p/v8/source/detail?r=7757
Patch Set 1 #Patch Set 2 : fixed lint/spelling errors #Patch Set 3 : '' #
Total comments: 3
Messages
Total messages: 2 (0 generated)
|