[SciPy-dev] Pre-release fixes
oliphant at ee.byu.edu
Fri Oct 1 11:49:02 CDT 2004
Robert Kern wrote:
> Travis Oliphant wrote:
>> Robert Kern wrote:
>>> I've just checked in a fix for fastumath's logical functions. They
>>> used to give wrong answers on OSX and caused some tests to fail. I
>>> believe this to be an endianness issue, but I don't have another
>>> big-endian machine to test on. All tests still pass on Athlon/Linux.
>>> The changes made largely track what Numeric did, so I'm not sure if
>>> these were conscious deviations to speed up fastumath or just a
>>> failure to keep up with the bugfixes in Numeric.
>>> I have only implemented fastumath_unsigned.inc as yet. I will make
>>> similar changes in fastumath_nounsigned.inc as I accumulate tuits.
>>> Travis, could you check my changes to make sure I didn't revert
>>> differences you deliberately made? If they were deliberate, then we
>>> need to figure a way to revert to the correct, if slower, Numeric
>>> implementations on the Mac.
>> I'm not sure what the problem is here. But I think you undid
>> deliberate changes that have implications for alter_numeric() and
>> need to be discussed. I had intentially made the results of all
>> logical operations be unsigned bytes. What was broken about this on
>> the Mac?
> Here are the tests that fail. The first two are what led me to the
> "fix" in the first place. The CDF failures are newer (I haven't seen
> them until today because I always used my version of
> fastumath_unsigned.inc for some months now), but all tests pass with
> my version.
> A quick summary:
I appreciate you finding this bug. I had no idea it was there and it
has probably been there for some time.
What I don't get is that your fix just changes the type of the pointer
to be assigned to, but (presumably) doesn't change the type of the array
being populated. So, why doesn't this create problems?
How can you have an output array that is UInt8 but assign to it as if it
were Int32? This seems like an endian-ness issue and your fix is
fooling the MAC platform. But, how would this work on other
More information about the Scipy-dev