This is the mail archive of the gcc-patches@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: [ada] rts support for alpha-linux


* Richard Henderson:

> Ada maintainers: I think my versions of sigset_t and other pthreads
> structures is more correct than in the existing s-osinte-linux.ads.
> Of primary concern is the alignment of the structures; using char
> for allocating dummy space when the real structure is aligned a-la
> unsigned long is surely a bug.  Of secondary concern, I have no idea
> what "pragma Convention (C, foo)" does when Ada declares an array 
> and the real C type is a structure.  It does seem inconsistent though.

As a compiler implementer, you have additional freedom.  8-) The array
construct isn't too bad, IMHO.  You can specify the alignment
explicitly using:

  for sigset_t'Alignment use 8;

This is used in other parts of the run-time, too, and it is a rather
useful construct when generating bindings to opaque C types in a
semi-automatic way (you only need the sizeof and __alignof__ values).


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