tech-toolchain archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: x86 abi for complex.



Den 2023-02-06 kl. 20:22, skrev Andrew Cagney:
    https://www.uclibc.org/docs/psABI-i386.pdf (page 14)
Yep, sounds quite likely.
What is the reason for;
1) return floats in eax/edx instead as a struct?
My guess: passing these values in registers helps
reduce memory traffic.
I don't think so, since the values must be stored into memory anyway to
get them into the floating point registers.
Floating point stack?

Taking a step back.  At the time, some UNIX (like) systems required a
'387 to just boot, but some did not.  Off the top of my head SCO
(SVR3?) did, but MINIX did not.  Presumably NetBSD hedged its bets by
not tying the ABI to the FPU making the hardware optional.
Not likely.
Complex did not exist in the standard at that time, and any other (x87) float is required to be returned on the floating point stack.

-- R


Home | Main Index | Thread Index | Old Index