Re: RFR: 8339332: Clean up the java launcher code

2024-09-11 Thread Jaikiran Pai
On Thu, 12 Sep 2024 06:39:59 GMT, David Holmes wrote: > Aside: we do an awful lot of Java code execution in the launcher these days > before we even get to load the real main class. I have to wonder how all this > affects startup? In addition to regular regression testing, I also ran existing

Re: RFR: 8339332: Clean up the java launcher code

2024-09-11 Thread Jaikiran Pai
On Tue, 10 Sep 2024 06:15:57 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which cleans up the code in the > `java` launcher? The original motivation for the change was to prevent the > `java` launcher's C code from parsing a jar's manifest when launching an > application

Re: RFR: 8339332: Clean up the java launcher code

2024-09-11 Thread David Holmes
On Tue, 10 Sep 2024 06:15:57 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which cleans up the code in the > `java` launcher? The original motivation for the change was to prevent the > `java` launcher's C code from parsing a jar's manifest when launching an > application

Re: RFR: 8339918: Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

2024-09-11 Thread Alan Bateman
On Wed, 11 Sep 2024 09:47:24 GMT, Jaikiran Pai wrote: > Can I please get a review for this change which cleans up the `java` launcher > to remove checks/support for outdated options? > > As noted in https://bugs.openjdk.org/browse/JDK-8339918, these 6 options have > been outdated and unsupport

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

2024-09-11 Thread Daniel Jeliński
On Thu, 12 Sep 2024 02:10:00 GMT, Brian Burkhalter 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 in

Re: RFR: 8339332: Clean up the java launcher code

2024-09-11 Thread Jaikiran Pai
On Tue, 10 Sep 2024 06:15:57 GMT, Jaikiran Pai wrote: > This was being done in the C code to support a long outdated "JRE selection" > feature (mJRE https://bugs.openjdk.org/browse/JDK-8058407) which required it > to parse the jar's manifest. I would like to note here that the mJRE feature is

RFR: 8339332: Clean up the java launcher code

2024-09-11 Thread Jaikiran Pai
Can I please get a review of this change which cleans up the code in the `java` launcher? The original motivation for the change was to prevent the `java` launcher's C code from parsing a jar's manifest when launching an application through `java -jar foo.jar`. The jar parsing code in C currentl

RFR: 8339980: [s390x] ProblemList jdk/java/util/zip/CloseInflaterDeflaterTest.java

2024-09-11 Thread Amit Kumar
This PR will ProblemList `jdk/java/util/zip/CloseInflaterDeflaterTest.java` on s390x. This change should be reverted while fixing [JDK-8339216](https://bugs.openjdk.org/browse/JDK-8339216). - Commit messages: - problemlisted Changes: https://git.openjdk.org/jdk/pull/20960/files

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 19:22:00 GMT, Brian Burkhalter wrote: >> src/java.base/windows/classes/sun/nio/fs/WindowsNativeDispatcher.java line >> 1097: >> >>> 1095: >>> 1096: static { >>> 1097: jdk.internal.loader.BootLoader.loadLibrary("net"); >> >> ...do we still need net here? > > We

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 16:51:43 GMT, Daniel Jeliński wrote: >> Yes, it still needs to be called in a few places, e.g., for classes whose >> native component needs the `fdval()` and `handleval()` functions. > > that's a good point. The comment might need to be updated to reflect that. Comments adde

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 19:31:02 GMT, Brian Burkhalter wrote: >> Just to be absolutely clear: All my other comments about removing unneeded >> libraries were about libnio, not libjava. I realize I made the comment in >> the PR next to libjava, but my intention was to ask if the list of libraries >

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

2024-09-11 Thread Brian Burkhalter
On Tue, 10 Sep 2024 13:26:58 GMT, Magnus Ihse Bursie wrote: >> make/modules/java.base/Lib.gmk line 81: >> >>> 79: libjava/nio/ch \ >>> 80: libnio/ch \ >>> 81: libnio/fs \ >> >> libnio/fs is gone on all platforms other than aix; is this still necessary? > > We can't add e

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

2024-09-11 Thread Brian Burkhalter
On Tue, 10 Sep 2024 09:54:56 GMT, Daniel Jeliński wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8337143: Remove loading libnet from Inet6AddressImpl; delete commented out >> #include in Windows IOUtil.c > >

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

2024-09-11 Thread Brian Burkhalter
> 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 incrementally with one additional commit since the last revision:

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v3]

2024-09-11 Thread Jaikiran Pai
On Wed, 11 Sep 2024 09:19:21 GMT, Jaikiran Pai wrote: >> Can I please get a review of this trivial change which replaces the usages >> of `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? >> >> As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are >> o

Integrated: 8339834: Replace usages of -mx and -ms in some tests

2024-09-11 Thread Jaikiran Pai
On Tue, 10 Sep 2024 09:46:14 GMT, Jaikiran Pai wrote: > Can I please get a review of this trivial change which replaces the usages of > `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? > > As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are > outdat

Re: RFR: 8339918: Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

2024-09-11 Thread David Holmes
On Wed, 11 Sep 2024 09:47:24 GMT, Jaikiran Pai wrote: > Can I please get a review for this change which cleans up the `java` launcher > to remove checks/support for outdated options? > > As noted in https://bugs.openjdk.org/browse/JDK-8339918, these 6 options have > been outdated and unsupport

RFR: 8339876: Move constant symbol caches to Utf8EntryImpl

2024-09-11 Thread Chen Liang
Some type descriptors are validated against generic utf8 entries, such as field or method types; we can cache a type descriptor wrapping the content of the utf8 entry if this entry is ever used as a type descriptor. This patch is more of a code cleanup; it is performance neutral. -

Re: RFR: 8338747: hasIncubatorModules needs to be generated when module resolution required at startup

2024-09-11 Thread Calvin Cheung
On Mon, 2 Sep 2024 12:27:21 GMT, Alan Bateman wrote: > This PR proposes changes to the ModuleBootstrap code that is used with CDS > (Ahead-of-Time Class Loading & Linking in the future). At things stand, the > module graph and boot layer can be archived at dump time (-Xshare:dump) when > the i

Integrated: 8299419: Thread.sleep(millis) may throw OOME

2024-09-11 Thread Viktor Klang
On Mon, 9 Sep 2024 20:40:22 GMT, Viktor Klang wrote: > This PR applies @AlanBateman's patch from the JBS issue. This pull request has now been integrated. Changeset: b0cff6b5 Author:Viktor Klang URL: https://git.openjdk.org/jdk/commit/b0cff6b528af7a2de453dd05d1c9ecbe7e00dc20 Stats:

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

2024-09-11 Thread Magnus Ihse Bursie
On Wed, 11 Sep 2024 19:18:18 GMT, Brian Burkhalter wrote: >> did you remove mswsock from libjava or from libnio? Libnio libraries are >> listed >> [here](https://github.com/openjdk/jdk/blob/f57b6f13e9f375bfd2e8a05afd2b900a4d42285e/make/modules/java.base/Lib.gmk#L89). >> There's no FileDispatche

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 19:28:39 GMT, Magnus Ihse Bursie wrote: >> Apparently I did remove it from libjava and not libnio. It will be fixed in >> the next commit. Thanks for being persistent. > > Just to be absolutely clear: All my other comments about removing unneeded > libraries were about libni

Integrated: 8339803: Acknowledge case insensitive unambiguous keywords in tzdata files

2024-09-11 Thread Naoto Sato
On Tue, 10 Sep 2024 19:45:01 GMT, Naoto Sato wrote: > This is a follow on fix to > [JDK-8339644](https://bugs.openjdk.org/browse/JDK-8339644). It turned out > that TZ data files allow abbreviation of keywords, such as "ZO" for "Zone." > Same fix, i.e, replacing `startsWith()` with `regionMatch

Re: RFR: 8339803: Acknowledge case insensitive unambiguous keywords in tzdata files [v2]

2024-09-11 Thread Naoto Sato
On Wed, 11 Sep 2024 18:33:59 GMT, Sean Coffey wrote: > maybe you can verify with a few simple edits to a tzdata file and building Yes, that is exactly what I did for this testing. - PR Comment: https://git.openjdk.org/jdk/pull/20940#issuecomment-2344538481

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

2024-09-11 Thread Brian Burkhalter
On Tue, 10 Sep 2024 11:27:05 GMT, Daniel Jeliński wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8337143: Remove loading libnet from Inet6AddressImpl; delete commented out >> #include in Windows IOUtil.c > >

Withdrawn: 8339875: MethodTypeDesc to reuse descriptor string from MethodType

2024-09-11 Thread Chen Liang
On Tue, 10 Sep 2024 23:24:25 GMT, Chen Liang wrote: > A micro-optimization by sharing compatible String objects from MethodType > (which itself is already deduplicated in a cache) to the generated > MethodTypeDesc. This very slightly improves hashing performance by avoiding > some string creat

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 16:48:24 GMT, Daniel Jeliński wrote: >> From a clean build in the CI with `mswsock.lib` removed: >> >> >> [2024-09-11T16:00:17,816Z] FileDispatcherImpl.obj : error LNK2019: >> unresolved external symbol >> TransmitFile referenced in function >> Java_sun_nio_ch_FileDispatch

Re: RFR: 8338747: hasIncubatorModules needs to be generated when module resolution required at startup

2024-09-11 Thread Ioi Lam
On Mon, 2 Sep 2024 12:27:21 GMT, Alan Bateman wrote: > This PR proposes changes to the ModuleBootstrap code that is used with CDS > (Ahead-of-Time Class Loading & Linking in the future). At things stand, the > module graph and boot layer can be archived at dump time (-Xshare:dump) when > the i

Re: RFR: 8338747: hasIncubatorModules needs to be generated when module resolution required at startup

2024-09-11 Thread Ioi Lam
On Mon, 2 Sep 2024 12:27:21 GMT, Alan Bateman wrote: > This PR proposes changes to the ModuleBootstrap code that is used with CDS > (Ahead-of-Time Class Loading & Linking in the future). At things stand, the > module graph and boot layer can be archived at dump time (-Xshare:dump) when > the i

Integrated: 8339687: Rearrange reachabilityFence()s in jdk.test.lib.util.ForceGC

2024-09-11 Thread Brent Christian
On Fri, 6 Sep 2024 19:57:41 GMT, Brent Christian wrote: > From the bug description: > ForceGC would be improved by moving the Reference.reachabilityFence() calls > for 'obj' and 'ref'. > > Reference.reachabilityFence(obj) is currently placed after 'obj' has been set > to null, so effectively d

Re: RFR: 8339803: Acknowledge case insensitive unambiguous keywords in tzdata files [v2]

2024-09-11 Thread Sean Coffey
On Tue, 10 Sep 2024 22:42:37 GMT, Naoto Sato wrote: >> This is a follow on fix to >> [JDK-8339644](https://bugs.openjdk.org/browse/JDK-8339644). It turned out >> that TZ data files allow abbreviation of keywords, such as "ZO" for "Zone." >> Same fix, i.e, replacing `startsWith()` with `regionM

Re: RFR: 8338694: x86_64 intrinsic for tanh using libm [v2]

2024-09-11 Thread Srinivas Vamsi Parasa
On Wed, 11 Sep 2024 17:21:36 GMT, Sandhya Viswanathan wrote: >> So far, this will be the only intrinsic implementation of tanh. Therefore, >> at the moment it is just checking the consistency of the intrinsic >> implementation with StrictMath/FDLIBM tanh. If the intrinsic has a ~1 ulp >> accu

Re: RFR: 8336881: [Linux] Support for hierarchical limits for Metrics [v8]

2024-09-11 Thread Severin Gehwolf
> Please review this fix for cgroups-based metrics reporting in the > `jdk.internal.platform` package. This fix is supposed to address wrong > reporting of certain limits if the limits aren't set at the leaf nodes. > > For example, on cg v2, the memory limit interface file is `memory.max`. > Co

Re: RFR: 8338694: x86_64 intrinsic for tanh using libm [v2]

2024-09-11 Thread Sandhya Viswanathan
On Wed, 11 Sep 2024 01:59:54 GMT, Joe Darcy wrote: >>> If the test is going to use randomness, then its jtreg tags should include >>> >>> `@key randomness` >>> >>> and it is preferable to use jdk.test.lib.RandomFactory to get and Random >>> object since that handles printing out a key so the r

Integrated: 8333446: Add tests for hierarchical container support

2024-09-11 Thread Severin Gehwolf
On Mon, 3 Jun 2024 17:28:09 GMT, Severin Gehwolf wrote: > Please review this PR which adds test support for systemd slices so that bugs > like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be > verified. The added test, `SystemdMemoryAwarenessTest` currently passes on > cgroup

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

2024-09-11 Thread Daniel Jeliński
On Tue, 10 Sep 2024 19:58:45 GMT, Brian Burkhalter wrote: >> src/java.base/share/classes/sun/nio/ch/IOUtil.java line 575: >> >>> 573: * Used to trigger loading of native libraries >>> 574: */ >>> 575: public static void load() { } >> >> do we still need this method? > > Yes, it st

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

2024-09-11 Thread Daniel Jeliński
On Wed, 11 Sep 2024 16:33:28 GMT, Brian Burkhalter wrote: >> Right. This PR moves FileDispatcherImpl.c to libjava, so >> FileDispatcherImpl.obj is no longer there. I'm guessing that our makefiles >> don't detect source files that were removed, and Brian didn't run `make >> clean`. > > From a c

Re: RFR: 8333446: Add tests for hierarchical container support [v11]

2024-09-11 Thread Severin Gehwolf
On Wed, 11 Sep 2024 14:13:50 GMT, Severin Gehwolf wrote: >> Please review this PR which adds test support for systemd slices so that >> bugs like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be >> verified. The added test, `SystemdMemoryAwarenessTest` currently passes on >> c

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v3]

2024-09-11 Thread Phil Race
On Wed, 11 Sep 2024 09:19:21 GMT, Jaikiran Pai wrote: >> Can I please get a review of this trivial change which replaces the usages >> of `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? >> >> As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are >> o

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

2024-09-11 Thread Brian Burkhalter
On Wed, 11 Sep 2024 06:00:23 GMT, Daniel Jeliński wrote: >> And you did not get `mswsock.lib: FileDispatcherImpl.obj : error LNK2019: >> unresolved external symbol TransmitFile`? > > Right. This PR moves FileDispatcherImpl.c to libjava, so > FileDispatcherImpl.obj is no longer there. I'm guessi

Re: RFR: 8339538: Wrong timeout computations in DnsClient [v5]

2024-09-11 Thread Daniel Fuchs
On Tue, 10 Sep 2024 19:01:54 GMT, Mark Sheppard wrote: >> I agree that we don't want to document too much here. Updated the factor to >> 1.75 (2 seems a bit high and might hide real issues), and to make the >> timeout value calculation and check less arcane - I have updated test output >> to p

Re: RFR: 8339538: Wrong timeout computations in DnsClient [v7]

2024-09-11 Thread Daniel Fuchs
On Wed, 11 Sep 2024 15:22:43 GMT, Aleksei Efimov wrote: >> This PR proposes the following changes to address wrong timeout computations >> in the `com.sun.jndi.dns.DnsClient`: >> - The `DnsClient` has been updated to use a monotonic high-resolution (nano) >> clock. The existing `Timeout` test h

Re: RFR: 8339803: Acknowledge case insensitive unambiguous keywords in tzdata files [v2]

2024-09-11 Thread Naoto Sato
On Wed, 11 Sep 2024 15:13:25 GMT, Sean Coffey wrote: >> Naoto Sato has updated the pull request incrementally with one additional >> commit since the last revision: >> >> tz files aligned with the default TzdbZoneRulesProvider list > > LGTM > > `sun/util/calendar/zi/TestZoneInfo310.java` exe

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v3]

2024-09-11 Thread Anthony Scarpino
On Wed, 11 Sep 2024 09:19:21 GMT, Jaikiran Pai wrote: >> Can I please get a review of this trivial change which replaces the usages >> of `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? >> >> As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are >> o

Re: RFR: 8339538: Wrong timeout computations in DnsClient [v5]

2024-09-11 Thread Aleksei Efimov
On Tue, 10 Sep 2024 19:01:54 GMT, Mark Sheppard wrote: >> I agree that we don't want to document too much here. Updated the factor to >> 1.75 (2 seems a bit high and might hide real issues), and to make the >> timeout value calculation and check less arcane - I have updated test output >> to p

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v9]

2024-09-11 Thread fabioromano1
> This implementation of MutableBigInteger.leftShift(int) optimizes the current > version, avoiding unnecessary copy of the MutableBigInteger's value content > and performing the primitive shifting only in the original portion of the > value array rather than in the value yet extended with trail

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v7]

2024-09-11 Thread Raffaello Giulietti
On Wed, 11 Sep 2024 12:44:54 GMT, fabioromano1 wrote: >> test/jdk/java/math/BigInteger/MutableBigIntegerShiftTests.java line 153: >> >>> 151: >>> 152: return result; >>> 153: } >> >> I think this is getting too complex for a test, there's a risk that it is >> incorrect... >> >> I

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v8]

2024-09-11 Thread Raffaello Giulietti
On Wed, 11 Sep 2024 14:23:40 GMT, fabioromano1 wrote: >> This implementation of MutableBigInteger.leftShift(int) optimizes the >> current version, avoiding unnecessary copy of the MutableBigInteger's value >> content and performing the primitive shifting only in the original portion >> of the

Re: RFR: 8339538: Wrong timeout computations in DnsClient [v7]

2024-09-11 Thread Aleksei Efimov
> This PR proposes the following changes to address wrong timeout computations > in the `com.sun.jndi.dns.DnsClient`: > - The `DnsClient` has been updated to use a monotonic high-resolution (nano) > clock. The existing `Timeout` test has also been updated to use the nano > clock to measure obser

Re: RFR: 8339803: Acknowledge case insensitive unambiguous keywords in tzdata files [v2]

2024-09-11 Thread Sean Coffey
On Tue, 10 Sep 2024 22:42:37 GMT, Naoto Sato wrote: >> This is a follow on fix to >> [JDK-8339644](https://bugs.openjdk.org/browse/JDK-8339644). It turned out >> that TZ data files allow abbreviation of keywords, such as "ZO" for "Zone." >> Same fix, i.e, replacing `startsWith()` with `regionM

Re: RFR: 8333446: Add tests for hierarchical container support [v11]

2024-09-11 Thread Zdenek Zambersky
On Wed, 11 Sep 2024 14:13:50 GMT, Severin Gehwolf wrote: >> Please review this PR which adds test support for systemd slices so that >> bugs like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be >> verified. The added test, `SystemdMemoryAwarenessTest` currently passes on >> c

Re: RFR: 8333446: Add tests for hierarchical container support [v11]

2024-09-11 Thread Matthias Baesken
On Wed, 11 Sep 2024 14:13:50 GMT, Severin Gehwolf wrote: >> Please review this PR which adds test support for systemd slices so that >> bugs like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be >> verified. The added test, `SystemdMemoryAwarenessTest` currently passes on >> c

Re: RFR: 8333446: Add tests for hierarchical container support [v11]

2024-09-11 Thread Severin Gehwolf
On Wed, 11 Sep 2024 14:13:50 GMT, Severin Gehwolf wrote: >> Please review this PR which adds test support for systemd slices so that >> bugs like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be >> verified. The added test, `SystemdMemoryAwarenessTest` currently passes on >> c

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v8]

2024-09-11 Thread fabioromano1
> This implementation of MutableBigInteger.leftShift(int) optimizes the current > version, avoiding unnecessary copy of the MutableBigInteger's value content > and performing the primitive shifting only in the original portion of the > value array rather than in the value yet extended with trail

Re: RFR: 8333446: Add tests for hierarchical container support [v11]

2024-09-11 Thread Severin Gehwolf
> Please review this PR which adds test support for systemd slices so that bugs > like [JDK-8217338](https://bugs.openjdk.org/browse/JDK-8217338) can be > verified. The added test, `SystemdMemoryAwarenessTest` currently passes on > cgroups v1 and cgroups v2 (since > [JDK-8322420](https://bugs.o

Re: RFR: 8339531: Improve performance of MemorySegment::mismatch [v9]

2024-09-11 Thread Per Minborg
On Thu, 5 Sep 2024 17:58:11 GMT, Maurizio Cimadamore wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix errors in a benchmark > > src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java > line

Re: RFR: 8339531: Improve performance of MemorySegment::mismatch [v9]

2024-09-11 Thread Per Minborg
On Fri, 6 Sep 2024 15:11:19 GMT, Brett Okken wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix errors in a benchmark > > src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java > line 244: >

Re: RFR: 8339531: Improve performance of MemorySegment::mismatch [v9]

2024-09-11 Thread Per Minborg
On Thu, 5 Sep 2024 17:51:35 GMT, Maurizio Cimadamore wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix errors in a benchmark > > src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java > line

Re: RFR: 8339934: Simplify Math.scalb(double) method

2024-09-11 Thread Raffaello Giulietti
On Wed, 11 Sep 2024 12:45:50 GMT, Raffaello Giulietti wrote: > `Math.scalb(double)` can be simplified, removing a loop and using > larger/smaller factors. The proposed implementation is even about 1.5x faster, but that's not the point of this PR. The point is to have simpler logic. Similar lo

RFR: 8339934: Simplify Math.scalb(double) method

2024-09-11 Thread Raffaello Giulietti
`Math.scalb(double)` can be simplified, removing a loop and using larger/smaller factors. - Commit messages: - 8339934: Simplify Math.scalb(double) method Changes: https://git.openjdk.org/jdk/pull/20948/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=20948&range=00 Issue

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v7]

2024-09-11 Thread fabioromano1
On Wed, 11 Sep 2024 11:48:36 GMT, Raffaello Giulietti wrote: >> fabioromano1 has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge branch 'patchLeftShift' of https://github.com/fabioromano1/jdk into >> patchLeftShift >> - Removed re

Re: RFR: 8299419: Thread.sleep(millis) may throw OOME [v3]

2024-09-11 Thread Alan Bateman
On Wed, 11 Sep 2024 11:42:19 GMT, Viktor Klang wrote: >> This PR applies @AlanBateman's patch from the JBS issue. > > Viktor Klang has refreshed the contents of this pull request, and previous > commits have been removed. The incremental views will show differences > compared to the previous co

Re: RFR: 8336274: MutableBigInteger.leftShift(int) optimization [v7]

2024-09-11 Thread Raffaello Giulietti
On Sat, 7 Sep 2024 20:39:39 GMT, fabioromano1 wrote: >> This implementation of MutableBigInteger.leftShift(int) optimizes the >> current version, avoiding unnecessary copy of the MutableBigInteger's value >> content and performing the primitive shifting only in the original portion >> of the v

Re: RFR: 8299419: Thread.sleep(millis) may throw OOME [v2]

2024-09-11 Thread Viktor Klang
On Wed, 11 Sep 2024 07:00:25 GMT, Alan Bateman wrote: >> If these are just methods that might be seen in a stackdump then we still >> need `ThreadSleepEvent.isEnabled` and `ThreadSleepEvent.`. > >> If these are just methods that might be seen in a stackdump then we still >> need `ThreadSleepEve

Re: RFR: 8299419: Thread.sleep(millis) may throw OOME [v3]

2024-09-11 Thread Viktor Klang
> This PR applies @AlanBateman's patch from the JBS issue. Viktor Klang has refreshed the contents of this pull request, and previous commits have been removed. The incremental views will show differences compared to the previous content of the PR. The pull request contains one new commit since

Re: RFR: 8339918: Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

2024-09-11 Thread Jaikiran Pai
On Wed, 11 Sep 2024 09:47:24 GMT, Jaikiran Pai wrote: > Can I please get a review for this change which cleans up the `java` launcher > to remove checks/support for outdated options? > > As noted in https://bugs.openjdk.org/browse/JDK-8339918, these 6 options have > been outdated and unsupport

Integrated: 8339686: java/foreign/TestMappedHandshake.java fails with assert(depth < max_critical_stack_depth) failed: can't have more than 10 critical frames

2024-09-11 Thread Maurizio Cimadamore
On Mon, 9 Sep 2024 12:57:17 GMT, Maurizio Cimadamore wrote: > The new test added by https://github.com/openjdk/jdk/pull/20854 fails > spuriously. > While JNI lookup is now moved into the static initializer of the > `MappedMemoryUtils` class, this class might only get initialized while in the

Re: RFR: 8339918: Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

2024-09-11 Thread Alan Bateman
On Wed, 11 Sep 2024 09:47:24 GMT, Jaikiran Pai wrote: > Would this change require a CSR? and probably a release note too. - PR Comment: https://git.openjdk.org/jdk/pull/20945#issuecomment-2343274428

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Claes Redestad
On Wed, 11 Sep 2024 08:34:09 GMT, Eirik Bjørsnøs wrote: >> src/java.base/share/classes/java/util/zip/ZipFile.java line 681: >> >>> 679: >>> 680: e.flag = CENFLG(cen, pos); >>> 681: e.method = CENHOW(cen, pos); >> >> Not reading `nlen` when it's not needed is a good change, and

RFR: 8339918: Remove checks for outdated -t -tm -Xfuture -checksource -cs -noasyncgc options from the launcher

2024-09-11 Thread Jaikiran Pai
Can I please get a review for this change which cleans up the `java` launcher to remove checks/support for outdated options? As noted in https://bugs.openjdk.org/browse/JDK-8339918, these 6 options have been outdated and unsupported for several releases now. 2 of them even throw an error curren

Re: RFR: 8339538: Wrong timeout computations in DnsClient [v6]

2024-09-11 Thread Daniel Fuchs
On Tue, 10 Sep 2024 18:41:41 GMT, Aleksei Efimov wrote: >> This PR proposes the following changes to address wrong timeout computations >> in the `com.sun.jndi.dns.DnsClient`: >> - The `DnsClient` has been updated to use a monotonic high-resolution (nano) >> clock. The existing `Timeout` test h

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v3]

2024-09-11 Thread Alexey Ivanov
On Wed, 11 Sep 2024 09:19:21 GMT, Jaikiran Pai wrote: >> Can I please get a review of this trivial change which replaces the usages >> of `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? >> >> As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are >> o

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v2]

2024-09-11 Thread Jaikiran Pai
On Wed, 11 Sep 2024 09:03:58 GMT, Alexey Ivanov wrote: >> Jaikiran Pai has updated the pull request incrementally with one additional >> commit since the last revision: >> >> update JImageToolTest too > > test/jdk/java/beans/Introspector/Test5102804.java line 28: > >> 26: * @bug 5102804 >>

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v3]

2024-09-11 Thread Jaikiran Pai
> Can I please get a review of this trivial change which replaces the usages of > `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? > > As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are > outdated and support for them will soon be deprecated and remo

Re: RFR: 8339834: Replace usages of -mx and -ms in some tests [v2]

2024-09-11 Thread Alexey Ivanov
On Tue, 10 Sep 2024 11:10:38 GMT, Jaikiran Pai wrote: >> Can I please get a review of this trivial change which replaces the usages >> of `-mx` and `-ms` to `-Xmx` and `-Xms` in tests and in one code comment? >> >> As noted in https://bugs.openjdk.org/browse/JDK-8339834, these options are >> o

Re: RFR: 8337408: Use GetTempPath2 API instead of GetTempPath [v2]

2024-09-11 Thread Kevin Walls
On Thu, 15 Aug 2024 20:28:28 GMT, Dhamoder Nalla wrote: >> Use the GetTempPath2 APIs instead of the GetTempPath APIs in native code >> across the OpenJDK repository to retrieve the temporary directory path, as >> GetTempPath2 provides enhanced security. While GetTempPath may still >> function

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
On Tue, 10 Sep 2024 19:39:34 GMT, Claes Redestad wrote: >> Eirik Bjørsnøs has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Add whitespace per review feedback > > src/java.base/share/classes/java/util/zip/ZipFile.java line 681: > >> 679:

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
On Tue, 10 Sep 2024 19:39:24 GMT, Lance Andersen wrote: >> Eirik Bjørsnøs has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Add whitespace per review feedback > > src/java.base/share/classes/java/util/zip/ZipCoder.java line 161: > >> 159:

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
On Tue, 10 Sep 2024 19:57:56 GMT, Claes Redestad wrote: >> Eirik Bjørsnøs has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Add whitespace per review feedback > > src/java.base/share/classes/java/util/zip/ZipFile.java line 549: > >> 547:

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
On Tue, 10 Sep 2024 19:34:11 GMT, Claes Redestad wrote: >> Eirik Bjørsnøs has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Add whitespace per review feedback > > src/java.base/share/classes/java/util/zip/ZipCoder.java line 161: > >> 159:

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
On Tue, 10 Sep 2024 19:30:52 GMT, Lance Andersen wrote: > If this does not make a huge performance difference, I would keep this > together with the init of elen and clen on line 692. I verified this does not cause a regression, so moved the `nlen` read up on the common path. See also my comm

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v4]

2024-09-11 Thread Eirik Bjørsnøs
> Please review this PR which speeds up `ZipFile.getZipEntry` by removing > slash-checking logic which is already taking place during lookup in > `ZipFile.Source.getEntryPos`. > > `ZipFile.Source.getEntryPos` includes logic to match a lookup for "name" > against a directory entry "name/" (with

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v3]

2024-09-11 Thread Eirik Bjørsnøs
> Please review this PR which speeds up `ZipFile.getZipEntry` by removing > slash-checking logic which is already taking place during lookup in > `ZipFile.Source.getEntryPos`. > > `ZipFile.Source.getEntryPos` includes logic to match a lookup for "name" > against a directory entry "name/" (with

Re: RFR: 8339874: Avoid duplicate checking of trailing slash in ZipFile.getZipEntry [v2]

2024-09-11 Thread Eirik Bjørsnøs
> Please review this PR which speeds up `ZipFile.getZipEntry` by removing > slash-checking logic which is already taking place during lookup in > `ZipFile.Source.getEntryPos`. > > `ZipFile.Source.getEntryPos` includes logic to match a lookup for "name" > against a directory entry "name/" (with

Re: RFR: 8338768: Introduce runtime lookup to check for static builds [v2]

2024-09-11 Thread Josef Eisl
On Tue, 10 Sep 2024 21:47:15 GMT, Magnus Ihse Bursie wrote: > sort out the mess that is libawt_headless/libawt_xawt sounds good. can you point me to a JBS? - PR Review Comment: https://git.openjdk.org/jdk/pull/20666#discussion_r1753307449

Re: RFR: 8299419: Thread.sleep(millis) may throw OOME [v2]

2024-09-11 Thread Alan Bateman
On Wed, 11 Sep 2024 06:18:25 GMT, David Holmes wrote: > If these are just methods that might be seen in a stackdump then we still > need `ThreadSleepEvent.isEnabled` and `ThreadSleepEvent.`. I think minimal here is to just drop isTurnedOn from lists in these tests. From what I can tell, the te