[issue3168] cmath test fails on Solaris 10

2008-07-05 Thread Jean Brouwers
Changes by Jean Brouwers <[EMAIL PROTECTED]>: Added file: http://bugs.python.org/file10818/config64.log.gz ___ Python tracker <[EMAIL PROTECTED]> ___ __

[issue3168] cmath test fails on Solaris 10

2008-07-05 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Can't find that particular message. Attached is the entire log of one of the SUN C builds of Python 2.6b1. Added file: http://bugs.python.org/file10817/config.log.gz ___ Python tracker <[EMAIL PROTECTED]>

[issue3168] cmath test fails on Solaris 10

2008-07-05 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: > There is another, perhaps related issue on Solaris. The compiler warns > that function finite is implicitly defined. > > Commenting out this line in pyconfig.h as > > /* #define HAVE_FINITE 1 */ > > make that warning go away. If there is

[issue3168] cmath test fails on Solaris 10

2008-07-05 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: Thanks, Jean. I've checked in your workaround in r64735. Leaving this open for now as a reminder about finite/is_finite. -- resolution: -> fixed ___ Python tracker <[EMAIL PROTECTED]>

[issue3168] cmath test fails on Solaris 10

2008-07-04 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Below is the reply from SUN. It was indeed a bug which has been fixed already. I have not yet applied the patches to my SUN compilers and tried again. /Jean Begin forwarded message: From: Sun Microsystems <[EMAIL PROTECTED]> Date: July 1,

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: There is another, perhaps related issue on Solaris. The compiler warns that function finite is implicitly defined. Commenting out this line in pyconfig.h as /* #define HAVE_FINITE 1 */ make that warning go away. If there is no function

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Without changing the cmath_log code, another workaround is to compile Python with optimization level -xO2 or less for 64-bit using Sun C. ___ Python tracker <[EMAIL PROTECTED]>

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: File but showing -xO0 thru -xO5 results. Added file: http://bugs.python.org/file10775/SunC-64bit-xO5-bug.c ___ Python tracker <[EMAIL PROTECTED]> _

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Changes by Jean Brouwers <[EMAIL PROTECTED]>: Removed file: http://bugs.python.org/file10774/SunC-64bit-xO5-bug.c ___ Python tracker <[EMAIL PROTECTED]> ___ ___

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Changes by Jean Brouwers <[EMAIL PROTECTED]>: Removed file: http://bugs.python.org/file10762/c_quot.c ___ Python tracker <[EMAIL PROTECTED]> ___ ___

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Attached is a test case which does demonstrate the problem. See the top of that file. I will post this at the SUN C Forum. Added file: http://bugs.python.org/file10774/SunC-64bit-xO5-bug.c ___ Python tra

[issue3168] cmath test fails on Solaris 10

2008-06-29 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: I have not yet been able to duplicate the problem in a smaller test case, but I did stumble into a fix. Changing the following statement in the cmath_log function from if (PyTuple_GET_SIZE(args) == 2) x = c_quot(x, c

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: > Trying to isolate and duplicate the problem with c_quot isn't quite > working. See the attached c_quot.c file and the results at the end. I'd expect that you'd need both the cmath_log and the c_quot functions, probably in separate files

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: Could you try the attached patch, and see what output you get from cmath.log(100., 2.)? (On 64-bit, of course.) -- keywords: +patch Added file: http://bugs.python.org/file10763/issue3168.patch ___

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Trying to isolate and duplicate the problem with c_quot isn't quite working. See the attached c_quot.c file and the results at the end. Added file: http://bugs.python.org/file10762/c_quot.c ___ Python tra

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: This is pretty bizarre, take a look at the following, 64-bit Pyhon 2.6b1 -xO5. Python 2.6b1 (r26b1:64398, Jun 28 2008, 12:50:06) [C] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> import math >>> math.log

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: This looks a lot like a compiler bug, then. Do you agree? I guess the next step would be to try to extract a smallest failing example from the Python code, and report the bug to Sun. It might first be interesting to insert some printfs in

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Forgot to mention, both 64-bit builds above includes -xlibmieee in the BASECFLAGS and LDFLAGS ./configure symbols (not LDSHARED!). The complete .configure command line was (with OPT adjusted accordingly): env CCSHARED="-KPIC" LDSHARED="cc -x

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: Here are the 64-bit results. First with -xO5: Python 2.6b1 (r26b1:64398, Jun 28 2008, 10:57:27) [C] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>> import cmath >>> cmath.log(100.0) (4.6051701859880918+0j)

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: What about cmath.log(100.0) and cmath.log(2.0) on 64-bit? ___ Python tracker <[EMAIL PROTECTED]> ___ __

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: For 32-bit, see the latest posts at . ___ Python tracker <[EMAIL PROTECTED]> ___ _

[issue3168] cmath test fails on Solaris 10

2008-06-28 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: More curious and more curious... I assume that cmath.log(100.0) and cmath.log(2.0) return the right things? (Both answers should have zero imaginary part.) Might this be some optimization bug? Can you turn off all optimizations and see wha

[issue3168] cmath test fails on Solaris 10

2008-06-27 Thread Jean Brouwers
Jean Brouwers <[EMAIL PROTECTED]> added the comment: 3 different Python 2.6b1 builds: 1) 64-bit Python 2.6b1 on Solaris 10 built with SUN C (no -xlibmieee): Python 2.6b1 (r26b1:64398, Jun 19 2008, 20:27:39) [C] on sunos5 Type "help", "copyright", "credits" or "license" for more information. >>

[issue3168] cmath test fails on Solaris 10

2008-06-27 Thread Mark Dickinson
Mark Dickinson <[EMAIL PROTECTED]> added the comment: This one's quite baffling. Jean, can you confirm whether cmath.log(0.01, 0.5) and cmath.log(100., 2.0) give the correct answer or not? They should both give (6.6438561897747244-0j) (the sign on the imaginary part might turn out as + inste

[issue3168] cmath test fails on Solaris 10

2008-06-27 Thread Terry J. Reedy
Terry J. Reedy <[EMAIL PROTECTED]> added the comment: Nasty. Here is the test extracted from test/test_cmath.py import math, cmath test_values = [0.01, 0.1, 0.2, 0.5, 0.9, 0.99] positive = test_values + [1.] + [1./x for x in test_values] for base in [0.5, 2., 10.]: for v in positive:

[issue3168] cmath test fails on Solaris 10

2008-06-22 Thread Mark Dickinson
Changes by Mark Dickinson <[EMAIL PROTECTED]>: -- assignee: -> marketdickinson nosy: +marketdickinson ___ Python tracker <[EMAIL PROTECTED]> ___ __

[issue3168] cmath test fails on Solaris 10

2008-06-21 Thread Jean Brouwers
New submission from Jean Brouwers <[EMAIL PROTECTED]>: There is on cmath test failure with 64-bit Python 2.6b1 and 3.0b1 on Solaris 10. The failure does not occur in the 32-bit builds. All builds are compiled with Sun's C compiler using the same options (except -xtarget=native vs -xtarget=nat