[foreign-memaccess] RFR 8234814: Eager layout size computation trips on unbound sequence layouts
Maurizio Cimadamore
maurizio.cimadamore at oracle.com
Tue Nov 26 15:03:02 UTC 2019
After a discussion offline with Jorn I've decided to revert the changes
to constants:
cr.openjdk.java.net/~mcimadamore/panama/8234814_v3
As some of the tests demonstrate, among the original goals of these
JAVA_INT constants and friends was interop with ByteBuffers, hence the
endianness set to BE.
I'll leave it as is for now (after all, the behavior is documented). We
can revise later, if needs be.
Maurizio
On 26/11/2019 14:46, Maurizio Cimadamore wrote:
>
> On 26/11/2019 14:40, Maurizio Cimadamore wrote:
>> * constants such as JAVA_INT should use native order (this is, after
>> all, the layout of an int in the VM)
>
> To expand a bit - we eventually would like to see these constants
> moved in the primitive wrapper classes - e.g.
>
> MemoryLayout::JAVA_INT -> Integer::LAYOUT
>
> in which case I think these constants should return whatever layout
> the VM thinks a Java int (in this case) has.
>
> Maurizio
>
More information about the panama-dev
mailing list