[Bug testsuite/32843] [4.3 Regression] : libffi.call/return_sc.c

aph at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Mon Aug 6 12:53:00 GMT 2007



------- Comment #13 from aph at gcc dot gnu dot org  2007-08-06 12:53 -------
> The 32bit psABI specifies Integral Arguments as 'Functions pass all
> integer-valued
> arguments as words, expanding or padding signed or unsigned bytes and
> halfwords as needed'. For return values the best I can find is 'A function that
> returns an integral or pointer value places its result in register %eax.'
> Both are not exactly clear whether sign- or zero-extension is required.

On the contrary, this implies very strongly to me that all integer-valued
arguments are passed as words, fully sign- or zero-extended for their type.
To read this in any other way strikes me as perverse.  If we are not correctly
sign- or zero-extendening return values we have broken the ABI.  To suggest
that this sign- or zero-extension does not apply to return values is also
perverse.


-- 

aph at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |aph at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32843



More information about the Gcc-bugs mailing list