Hi Caolan, On 2010-12-09 at 09:43 +0000, Caolán McNamara wrote:
> > and from what I see on page 19, it seems to me that *BSD defaults to the > > 'fastcall' variant, right? > > We're looking at "Table 7. Methods for returning structure, class and > union objects" right ? > > > The table suggests that the small structs that combine int and float > > are returned on stack > > Are you looking at "Table 6. Methods for passing structure..." ? I'm > only looking at structure *returns*. Yeah, sorry; I knew I should have been looking at the table 7, but was not careful, and looked at 6 :-( > calling_conventions.pdf baffles me a little in Table 7 anyway. System V > Application Binary Interface (abi386-4.pdf) clearly says "If a function > returns a structure or union, then the caller provides space for the > return value and places its address on the stack as argument word zero", > i.e. default Linux ABI x86 does not return structs in registers, despite > the "I" in "simple structure, class or union" for "Gnu except Mac OS" > where I is "Returned in integer registers". We clearly don't don't > return small structs in regs on x86 Linux so I don't know what "Gnu > except Mac OS" refers to there. > > Anyway, better info where Apple documents the diff they use on MacOSX > from the classic SYSV ABI. > > http://developer.apple.com/library/mac/#documentation/DeveloperTools/Conceptual/LowLevelABI/130-IA-32_Function_Calling_Conventions/IA32.html#//apple_ref/doc/uid/TP40002492-SW4 This was actually why I was looking at other sources too - thanks to the circular dependency 'See “Returning Results” for more information.' and 'See “Passing Arguments” for more information.', I was afraid there's missing something there :-) > Anyway, what I'll simply do is first add some tests to testtools for > returning something comprised of two floats, and or something comprised > of an integer + float and for something that is 3 bytes in size, etc to > force clarification in practice. Thank you - and sorry for the nitpicking. Regards, Kendy _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice