On Fri, 7 Jul 2023 10:32:54 GMT, Jorn Vernee <jver...@openjdk.org> wrote:
>> sid8606 has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Address Amit's review comments > > test/jdk/java/foreign/TestClassLoaderFindNative.java line 63: > >> 61: public void testVariableSymbolLookup() { >> 62: MemorySegment segment = >> SymbolLookup.loaderLookup().find("c").get().reinterpret(ByteOrder.nativeOrder() >> == ByteOrder.LITTLE_ENDIAN ? 1 : 4); >> 63: assertEquals(segment.get(JAVA_BYTE, ByteOrder.nativeOrder() == >> ByteOrder.LITTLE_ENDIAN ? 0 : 3), 42); > > Could you explain why this is needed? It looks like the lookup is returning > the wrong address? Since s390x runs in Big Endian mode. We get LSB on higher address of integer size. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/14801#discussion_r1255921714