Alignment of stack traces

Bryce McKinlay bryce@waitaki.otago.ac.nz
Wed Feb 28 18:10:00 GMT 2001


"Boehm, Hans" wrote:

> natThrowable.cc contains the code:
>
>       // ???  Might this cause a problem if the byte array isn't aligned?
>       stackTrace = JvNewByteArray (n * sizeof p[0]);
>       memcpy (elements (stackTrace), p+1, (n * sizeof p[0]));
>
> What's the right solution here?  Should the stack trace just be an array of
> java longs?  This would overconstrain the 32-bit case, but that doesn't seem
> to be a big deal.

Or an Array of Objects? Maybe we need a new type that is like RawData except it
is marked by GC, but isn't expected to have the usual java object header.

regards

  [ bryce ]




More information about the Java mailing list