On Wed, 4 Sep 2024 09:09:32 GMT, Per Minborg <[email protected]> wrote:
> This PR proposes to improve the performance of `MemorySegment::mismatch` by
> using Java code rather than transitioning to native code.
src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java
line 103:
> 101: } else {
> 102: long i;
> 103: if (SCOPED_MEMORY_ACCESS.getByte(src.sessionImpl(),
> src.unsafeGetBase(), src.unsafeGetOffset() + srcToOffset) !=
Suggestion:
if (SCOPED_MEMORY_ACCESS.getByte(src.sessionImpl(),
src.unsafeGetBase(), src.unsafeGetOffset() + srcFromOffset) !=
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20848#discussion_r1743672410