On 04-10-2012 15:06, Jacob Carlborg wrote:
On 2012-10-04 14:36, Alex Rønne Petersen wrote:

Presumably speed; returning small structs in registers will be faster
than doing so on the stack.

Are sturcts currently always returned on the stack?

As always, it depends on the arch, but on 32-bit x86: Yes. On 64-bit x86: Yes, if the struct size is larger than 8 bytes (otherwise it's returned in RAX).


But I don't agree that the vast complexity of altering well-established
ABIs for multiple architectures is worth that speed gain.

I agree.


--
Alex Rønne Petersen
a...@lycus.org
http://lycus.org

Reply via email to