This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Use of VLA in struct in gcc-torture/execute/20020412-1.c


> On Sun, Sep 08, 2002 at 03:14:02PM -0400, John David Anglin wrote:
> > Another question, what should FUNCTION_ARG do about arguments that have
> > a zero size (e.g., an empty struct, another GCC extension)?
> 
> A _fixed_ size zero?  I think we're supposed to treat 
> that as a struct of size one.  Look at x86 output to be sure.

Ok, I tried compile/zero-strct-1.c with the HP aCC compiler and
it passes the empty struct as a single byte in a general register.
x86 passes them on the stack.

I still don't understand the function of empty structs.

Dave
-- 
J. David Anglin                                  dave.anglin@nrc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6605)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]