Re: C aggregate passing (Rust kernel policy)

David Laight
2025-02-22T08:41:15Z

On Sat, 22 Feb 2025 07:37:30 +0100
Willy Tarreau <w@1wt.eu> wrote:

...
> Update: I found in my code a comment suggesting that it works when using
> -freg-struct (which is in fact -freg-struct-return) which works both on
> i386 and ARM.

The problem is that you need it to be an __attribute__(()) so it can
be per-function without breaking ABI.

> I just didn't remember about this and couldn't find it when
> looking at gcc docs.

I can never find anything in there either.
And then I wish they say when it was introduced.

David