This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Alpha vs. new ABI
Alexandre Oliva wrote:
> > jobject dummy[0];
>
> jobject isn't correct either for a platform that has 32-bits pointers
> but 64-bit doubles that must be 64-bit aligned.
I had thought that `data' would get double alignment regardless of
`dummy' for a jdouble array, since it would be the largest member... is
that wrong?
> union { jobject align_object; jdouble align_double; jlong align_long;
> T data; } data[0];
We don't enforce double alignment on data, not yet anyway. For that the
compiler would have to change as well. But the union makes sense to me,
provided it doesn't worsen the generated code. It may be more
portable/standard than the empty array, for whatever that's worth.
Thanks. I'll give it a try tonight, if nobody else does.
Jeff