This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: On alignment
Tom Tromey writes:
> >>>>> "Kevin" == Kevin B Hendricks <kevin dot hendricks at sympatico dot ca> writes:
>
> Kevin> Will having long long int aligned to 8 and double aligned to 4
> Kevin> create any problems for gcj if a similar alignment macro is
> Kevin> used for gcj given that doubles and long long int are
> Kevin> different?
>
> I'm not certain. My understanding is that g++ does all the field
> alignment in the front end,
Not entirely, I don't think. It's a mixture of both, which is AFAIK
the source of these problems.
> while gcj completely relies on stor-layout to do it. So the
> question is whether g++ (with whatever hack we're adding to the
> generated headers) and stor-layout agree in the above scenario.
With the C++ layout bugs fixed, I expect this will be fine.
In the future, we need to be using the same layout code as C++. In
fact I thought we *were*, so I didn't expect any of this. I assumed
that when C++ moved to the new ABI gcj would automatically follow,
because we were using the same code. I didn't realize that the C++
guys would make the changes inside their front end.
Andrew.