[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: a < b for complex numbers on MinGW

From: John W. Eaton
Subject: Re: a < b for complex numbers on MinGW
Date: Wed, 13 Nov 2013 16:11:51 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131005 Icedove/17.0.9

On 11/13/2013 04:03 PM, Rik wrote:
Good news on this bug.  Apparently we had already encountered it 4 years
The root cause is that intermediate math results can sometimes be stored in
machine registers that exceed the mandated IEEE 64 bits.  Most of the time
this is fine, even good so numbers don't under/over flow, but occasionally
it causes problems as in this case.  We already have a configure option,
--enable-float-truncate, which declares the variables used for complex
comparisons as volatile so they get truncated to IEEE width.  I re-built
with this flag thrown and now MinGW is passing both the quadgk test and the
sort test which were failing.

Remaining question is where should we enable this flag?  We could detect
the vulnerable systems (MinGW and Cygwin) in Octave's configure script and
automatically set the option.  We could also put it in the mxe-octave build
script octave.mk.  The disadvantage of the latter is that some people may
get the tarball and be doing native builds without mxe and thus miss
setting this flag.

Is it possible to write a configure test that will reliably detect the problem? If so, then let's base the choice on a test. However, since it will require running a program, we will also need a default for cross compiling, so we'll have to set the default for at least MinGW and Cygwin systems as enabling the feature. If it's not possible to write a reliable test, then I guess we should just enable it for MinGW and Cygwin by default.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]