APCS-32 & 'float' argument passing
nick at dsvr.net
Thu Jun 10 01:39:59 PDT 2004
John Tytgat wrote:
> In message <40C71BDB.4060409 at dsvr.net>
> Nick Burrett <nick at dsvr.net> wrote:
>>John Tytgat wrote:
>>>Has this been discussed before ? Could this be fixed in GCC please (this
>>>means also a couple of fixes in UnixLib) ?
>>This has never been an issue before. I'm 100% certain that APCS-R does
>>not promote 32-bit float arguments to 64-bit double arguments.
>>Otherwise the code would never have been written that way.
> I'm afraid that is not correct (cfr. the APCS-32 / APCS-R quotes in my
> original mails). Also a small test with the Norcroft v5.06 (latest
> compiler version publically released by Acorn) and v5.54 (one of the
> latest versions released by Tematic/Castle) doesn't confirm your view
> either :
I think you need to look further back to Norcroft C version 3. The APCS
defined in the RISC OS 3 PRMs does not describe the promotion of
floating point arguments at all, which I believe implies that floats get
passed as floats.
I'm not arguing that your wrong, I'm just very surprised to see this
coming up as an issue before. It looks like Norcroft is currently based
on the (now obsolete) AAPCS.
I'll look into fixing the compiler.
Nick Burrett, Senior Systems and Network Engineer
Designer Servers Ltd. http://www.dsvr.co.uk
More information about the gcc