Issue 678265: test_coercion fails on AIX (original) (raw)

Created on 2003-01-31 18:10 by nnorwitz, last changed 2022-04-10 16:06 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
coercion-patch.txt nascheme,2004-03-10 17:33
Messages (10)
msg14348 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2003-01-31 18:10
Tim, I assigned this to you to see if you had any insight/ideas about this problem. test_coercion fails on AIX. All the failures are due to the test expecting n+0j, but the output is n-0j. Here's an example: - <MethodNumber 1> / (2+0j) = (0.5+0j) ? ^ + <MethodNumber 1> / (2+0j) = (0.5-0j) ? ^ I have another compiler, so I'll probably try that. Especially since it's gcc. :-)
msg14349 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2003-01-31 19:26
Logged In: YES user_id=33168 The test passes with gcc 3.2. The C compiler is in vac.C version 4.4.0.3 (lslpp -l vac.C).
msg14350 - (view) Author: Tim Peters (tim.peters) * (Python committer) Date: 2003-01-31 21:08
Logged In: YES user_id=31435 You really need a platform wizard for something like this. If there are any compiler options with descriptions like "generate IEEE-754 compatible code" (or "stricter 754 xyz"), or "disable generation of fused multiply-add", they would be relevant. OTOH, Python promises nothing about how the sign bit of a floating zero behaves, so it would be OK by me if the test were changed not to produce complex results with zero imaginary members.
msg14351 - (view) Author: Mark D. Roth (mdr0) Date: 2004-03-09 21:35
Logged In: YES user_id=994239 I've run into this same problem under AIX 4.3.3 with IBM compiler version 6.0.0.5 and under AIX 5.1 with IBM compiler version 6.0.0.4. Is there a work-around, other than building with gcc?
msg14352 - (view) Author: Neil Schemenauer (nascheme) * (Python committer) Date: 2004-03-09 23:22
Logged In: YES user_id=35752 I really didn't intend for test_coercion to become a platform fp quirks test. The attached patch changes the test to format floating point numbers to one decimal place.
msg14353 - (view) Author: Neal Norwitz (nnorwitz) * (Python committer) Date: 2004-03-10 00:16
Logged In: YES user_id=33168 IIRC, there was a command line switch to xlc which would change the math behaviour. I don't recall trying it but from the description it seemed like it would work. Neil, I'll try to look at your patch. If you think it's not controversial, just check it in. I'll definitely review it in that case. :-)
msg14354 - (view) Author: Mark D. Roth (mdr0) Date: 2004-03-10 16:52
Logged In: YES user_id=994239 Looks like the test is still failing, even with this patch. Any idea what that xlc option might have been? I looked through the list of options, but it wasn't immediately obvious to me which one might have helped. Any other ideas? Thanks!
msg14355 - (view) Author: Neil Schemenauer (nascheme) * (Python committer) Date: 2004-03-10 17:27
Logged In: YES user_id=35752 My patch didn't update the expected output for the test. I've uploaded a new patch that does (if you want to test it again).
msg14356 - (view) Author: Mark D. Roth (mdr0) Date: 2004-03-10 17:34
Logged In: YES user_id=994239 Looks like that fixed it. Thanks!
msg14357 - (view) Author: Neil Schemenauer (nascheme) * (Python committer) Date: 2004-03-10 17:39
Logged In: YES user_id=35752 Patch commited (test_coercion.py 1.7, test_coercion 1.6).
History
Date User Action Args
2022-04-10 16:06:23 admin set github: 37884
2003-01-31 18:10:37 nnorwitz create