This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author JohnsonCW
Recipients JohnsonCW, illumino, theller
Date 2009-05-21.20:25:04
SpamBayes Score 1.72757e-09
Marked as misclassified No
Message-id <>
Turns out the problem is really in the Sparc version of libffi -- the 
ffi_closure_sparc_inner_v9 function in 
Modules/_ctypes/libffi/src/sparc/ffi.c wasn't properly accounting for 
the 16-byte alignment of a long double in an argument stack -- it 
presumed 8-byte alignment throwing off any long double value after a 
shorter value.  (16-byte alignment is specified in the SPARC Compliance 

I've attached a patch which I'm sure could be improved (there's 
probably a more proper way to do things in libffi) but it passes the 
check tests for ctypes and a few other tests I threw in.

By the way, I noticed that one of the test cases in the script I added 
in my last comment has an error in its success/failure test ... 
the "(typ, c_byte)" test should check for the result of -3 instead of 
Date User Action Args
2009-05-21 20:25:11JohnsonCWsetrecipients: + JohnsonCW, theller, illumino
2009-05-21 20:25:10JohnsonCWsetmessageid: <>
2009-05-21 20:25:08JohnsonCWlinkissue6029 messages
2009-05-21 20:25:06JohnsonCWcreate