RFR: 8337143: (fc, fs) Move filesystem-related native objects from libnio to libjava [v4]

Daniel Fuchs dfuchs at openjdk.org
Thu Aug 8 09:19:41 UTC 2024


On Wed, 7 Aug 2024 15:59:14 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

>> This proposed change would move the native objects required for NIO file interaction from the libnio native library to the libjava native library on Linux, macOS, and Windows.
>
> Brian Burkhalter has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
> 
>  - Merge
>  - 8337143: Removed dependency of libjava on headers in libnio/ch
>  - 8337143: Move natives to <platform>/native/libjava/nio/{ch,fs} as a function of their original location in libnio
>  - 8337143: (fc, fs) Move filesystem-related native objects from libnio to libjava

Disclaimer: I have not tried to understand the proposed change in details. However I have spotted a small oddity.

src/java.base/share/classes/java/net/Inet6AddressImpl.java line 154:

> 152:     static {
> 153:         jdk.internal.loader.BootLoader.loadLibrary("net");
> 154:     }

I am curious about this change - wouldn't it be needed in Inet4AddressImpl as well?

src/java.base/windows/native/libjava/IOUtil.c line 37:

> 35: #include "nio.h"
> 36: #include "nio_util.h"
> 37: /* #include "net_util.h" */

Is this change intended or is this a left over from some experimentation?

-------------

PR Review: https://git.openjdk.org/jdk/pull/20317#pullrequestreview-2227299000
PR Review Comment: https://git.openjdk.org/jdk/pull/20317#discussion_r1709024031
PR Review Comment: https://git.openjdk.org/jdk/pull/20317#discussion_r1709029492


More information about the core-libs-dev mailing list