Comment #1 on issue 3579 by [email protected]: Math.log2 and Math.log10
should be exact for exact powers
https://code.google.com/p/v8/issues/detail?id=3579
The current implementation basically does log2(x) = log(x)/log(2). This
can be improved by using the fact that x = 2^e*f where 1 <= |f| < 2. Then
log2(x) = e + log2(f) = e + log(f)/log(2)
I think this change will allow log2(2^n) = n for all possible n such that
2^n fits in a float. However, this might cause an additional rounding that
causes this log2 to be different from the original, which only had one
extra rounding to multiply by 1/log(2).
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.