[Numpy-discussion] where are the benefits of ldexp and/or "array times 2"?
Robert Kern
robert.kern at gmail.com
Thu May 21 11:46:12 EDT 2009
On Thu, May 21, 2009 at 10:26, dmitrey <dmitrey.kroshko at scipy.org> wrote:
> Hi all,
> I expected to have some speedup via using ldexp or multiplying an
> array by a power of 2 (doesn't it have to perform a simple shift of
> mantissa?),
Addition of the exponent, not shift of the mantissa.
> but I don't see the one.
I said there *might* be a speedup, but it was probably going to be
insignificant. The overhead of using frexp and ldexp probably
outweighs any benefits.
--
Robert Kern
"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
-- Umberto Eco
More information about the NumPy-Discussion
mailing list