http://codereview.chromium.org/6602007/diff/1/src/x64/code-stubs-x64.cc
File src/x64/code-stubs-x64.cc (right):

http://codereview.chromium.org/6602007/diff/1/src/x64/code-stubs-x64.cc#newcode2154
src/x64/code-stubs-x64.cc:2154: __ movl(rcx, Immediate(0x7FB00000));
We now divide first, then compare to 0.


On 2011/02/28 13:21:41, Lasse Reichstein wrote:
Could you detect infinity by adding the value to itself and see that
it doesn't
change? (Need to filter out zero at the beginning then, ofcourse).


Or subtract it from itself and not get zero (but NaN)?

http://codereview.chromium.org/6602007/diff/1/src/x64/code-stubs-x64.cc#newcode2160
src/x64/code-stubs-x64.cc:2160: __ movsd(xmm1, xmm3);
On 2011/02/28 13:21:41, Lasse Reichstein wrote:
It's worth noticing that if xmm1 is very small, the division might
give Infinity
- but that's the correct result for the operation.

Done.

http://codereview.chromium.org/6602007/diff/1/src/x64/code-stubs-x64.cc#newcode2189
src/x64/code-stubs-x64.cc:2189: __ j(greater_equal, &call_runtime);
The value b^infinity depends on whether b is >, =, or < 1, and >, =, or
< 0.  It is complicated.

On 2011/02/28 13:21:41, Lasse Reichstein wrote:
If the value isn't -Infinity, won't the result be NaN/Infinity too. We
shouldn't
need to go to runtime.
It's only if it's -Infinity that we need to do something (and I have
no idea
what :).

http://codereview.chromium.org/6602007/diff/1/src/x64/code-stubs-x64.cc#newcode2197
src/x64/code-stubs-x64.cc:2197: __ movl(rcx, Immediate(0xBF000000));
Changed.

On 2011/02/28 13:21:41, Lasse Reichstein wrote:
Is this smaller than loading the exact representation of 1/2 as
64-bit?

http://codereview.chromium.org/6602007/

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to