Re: RFR: 8339260: Move rarely used constants out of ClassFile [v9]

2024-11-29 Thread Chen Liang
On Fri, 29 Nov 2024 22:20:50 GMT, Luca Kellermann wrote: >> Don't think so. This imo is fixable in the future if we do have many new >> cp/annotation tags (see example of Thread::threadId), though I don't think >> that is likely > > Wait, I referenced the wrong thing. I was speaking about this

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v3]

2024-11-29 Thread Sergey Chernyshev
On Wed, 27 Nov 2024 11:07:18 GMT, Severin Gehwolf wrote: > Right. I'm still not convinced this extra reduction buys us much. The adjust > controller logic will handle it if kept as is in the Metrics version. The adjust controller logic won't handle it, because it reduces the path from child to

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v6]

2024-11-29 Thread Severin Gehwolf
On Wed, 27 Nov 2024 09:11:22 GMT, Sergey Chernyshev wrote: >> Cgroup V1 subsustem fails to initialize mounted controllers properly in >> certain cases, that may lead to controllers left undetected/inactive. We >> observed the behavior in CloudFoundry deployments, it affects also host >> syste

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v3]

2024-11-29 Thread Severin Gehwolf
On Fri, 29 Nov 2024 14:47:13 GMT, Sergey Chernyshev wrote: > > Right. I'm still not convinced this extra reduction buys us much. The > > adjust controller logic will handle it if kept as is in the Metrics version. > > The adjust controller logic won't handle it, because it reduces the path fro

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v3]

2024-11-29 Thread Severin Gehwolf
On Wed, 27 Nov 2024 10:56:57 GMT, Sergey Chernyshev wrote: >>> Version specific code can be had in `set_subsystem_path()` of the >>> corresponding impl (like an earlier version of your patch). `lowest_limit` >>> and `limit_cg_path` fixes are version agnostic and can and should be fixed >>> in

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v6]

2024-11-29 Thread Sergey Chernyshev
On Wed, 27 Nov 2024 10:18:24 GMT, Severin Gehwolf wrote: >> Sergey Chernyshev has updated the pull request incrementally with one >> additional commit since the last revision: >> >> adjust path suffix in cgroup (v1) version specific code, when root != >> cgroup > > src/hotspot/os/linux/cgrou

Re: RFR: 8343191: Cgroup v1 subsystem fails to set subsystem path [v8]

2024-11-29 Thread Sergey Chernyshev
> Cgroup V1 subsustem fails to initialize mounted controllers properly in > certain cases, that may lead to controllers left undetected/inactive. We > observed the behavior in CloudFoundry deployments, it affects also host > systems. > > The relevant /proc/self/mountinfo line is > > > 2207 21

Re: RFR: 8339260: Move rarely used constants out of ClassFile [v9]

2024-11-29 Thread Luca Kellermann
On Fri, 29 Nov 2024 18:59:41 GMT, Chen Liang wrote: >>> Yet I think we can consider promoting Constant Pool tag from byte or char, >>> short, or int to represent a u1 in case it goes over 127. >> >> Is there any chance a change like this could make it into JDK 24? I'd >> imagine it would be to

Re: RFR: 8344911: Introduce test utility for asserting file open status [v2]

2024-11-29 Thread Eirik Bjørsnøs
On Mon, 25 Nov 2024 17:19:41 GMT, Eirik Bjørsnøs wrote: >> Please review this PR which adds a utility API in the test libraries to >> assert whether a file is currently open. >> >> Several OpenJDK tests currently rely on approximations to check this, >> including deletion (fails only on Wind

Re: RFR: 8315487: Security Providers Filter [v9]

2024-11-29 Thread Francisco Ferrari Bihurriet
On Mon, 4 Nov 2024 19:46:07 GMT, Xue-Lei Andrew Fan wrote: >> Martin Balao has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains eight commits: >> >> - Remove -Xdebug from commented-out debug command >> >>This is unnecessary, s

Re: RFR: 8339260: Move rarely used constants out of ClassFile [v9]

2024-11-29 Thread Chen Liang
On Fri, 29 Nov 2024 17:53:43 GMT, Luca Kellermann wrote: >>> Your example is an exact antipattern from our data-oriented model: we would >>> want users to check the object type with `instanceof` (should be `is` in >>> kotlin) instead of checking these constants. >> >> I'm aware, this was just

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v3]

2024-11-29 Thread Nizar Benalla
On Fri, 29 Nov 2024 12:20:02 GMT, Nizar Benalla wrote: >> Can I please get a review for this PR that add tests to verify the value of >> `@since` tags to the Tools area modules. The test is described in this >> [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). >> Th

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v4]

2024-11-29 Thread Nizar Benalla
> Can I please get a review for this PR that add tests to verify the value of > `@since` tags to the Tools area modules. The test is described in this > [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). > This issue is similar to JDK-8341399, JDK-8331051 and JDK-83434

Re: RFR: 8340133: Add concise usage message to the java executable [v10]

2024-11-29 Thread Jan Lahoda
On Fri, 29 Nov 2024 17:05:45 GMT, Magnus Ihse Bursie wrote: > Shouldn't we try to promote GNU-style long options? (That is, suggest > `--version` instead of `-version`.) I was thinking of that, but shied away from it, because: the current `java` output prints to stderr; this new concise `java`

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Jorn Vernee
On Fri, 29 Nov 2024 09:46:55 GMT, Per Minborg wrote: >> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, >> fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != >> 0`). >> >> This PR also improves performance on modern hardware, as there is no nee

Re: RFR: 8334714: Implement JEP 484: Class-File API [v9]

2024-11-29 Thread Nizar Benalla
On Fri, 15 Nov 2024 11:53:00 GMT, Adam Sotona wrote: >> Class-File API is leaving preview. >> This is a removal of all `@PreviewFeature` annotations from Class-File API. >> It also bumps all `@since` tags and removes >> `jdk.internal.javac.PreviewFeature.Feature.CLASSFILE_API`. >> >> Please rev

Re: RFR: 8339260: Move rarely used constants out of ClassFile [v9]

2024-11-29 Thread Luca Kellermann
On Mon, 7 Oct 2024 17:37:40 GMT, Luca Kellermann wrote: > Yet I think we can consider promoting Constant Pool tag from byte or char, > short, or int to represent a u1 in case it goes over 127. Is there any chance a change like this could make it into JDK 24? I'd imagine it would be too late af

Re: RFR: 8334714: Implement JEP 484: Class-File API [v9]

2024-11-29 Thread Luca Kellermann
On Fri, 15 Nov 2024 11:53:00 GMT, Adam Sotona wrote: >> Class-File API is leaving preview. >> This is a removal of all `@PreviewFeature` annotations from Class-File API. >> It also bumps all `@since` tags and removes >> `jdk.internal.javac.PreviewFeature.Feature.CLASSFILE_API`. >> >> Please rev

Re: RFR: 8340133: Add concise usage message to the java executable [v10]

2024-11-29 Thread Alan Bateman
On Fri, 29 Nov 2024 07:25:23 GMT, Jan Lahoda wrote: >> Currently, running `java` without any parameters will lead to an output that >> is a full `--help`, which is over 100 lines (on my computer at least), and >> it feels overwhelming. And many people might actually want to run >> JShell/REPL,

Re: RFR: 8340133: Add concise usage message to the java executable [v10]

2024-11-29 Thread Magnus Ihse Bursie
On Fri, 29 Nov 2024 07:25:23 GMT, Jan Lahoda wrote: >> Currently, running `java` without any parameters will lead to an output that >> is a full `--help`, which is over 100 lines (on my computer at least), and >> it feels overwhelming. And many people might actually want to run >> JShell/REPL,

Integrated: 8345145: Display javap LineNumberTable and LocalVariableTable iff disassembled code output with `-c` or `-v`

2024-11-29 Thread Jonathan Lampérth
On Thu, 28 Nov 2024 11:33:43 GMT, Jonathan Lampérth wrote: > This PR includes a suggested change in behaviour of `javap -l` without `-v` > or `-c`. > Previously it was possible to print `LineNumberTable` and > `LocalVariableTable` without disassembled code output. This didn't make much > sense

Re: RFR: 8345145: Display javap LineNumberTable and LocalVariableTable iff disassembled code output with `-c` or `-v`

2024-11-29 Thread Chen Liang
On Thu, 28 Nov 2024 11:33:43 GMT, Jonathan Lampérth wrote: > This PR includes a suggested change in behaviour of `javap -l` without `-v` > or `-c`. > Previously it was possible to print `LineNumberTable` and > `LocalVariableTable` without disassembled code output. This didn't make much > sense

Re: RFR: 8343342: java/io/File/GetXSpace.java fails on Windows with CD-ROM drive

2024-11-29 Thread Taizo Kurashige
On Thu, 31 Oct 2024 07:15:16 GMT, Taizo Kurashige wrote: > To resolve java/io/File/GetXSpace.java failure, I fix libGetXSpace.c to use > Cygwin’s `df` to get the size for comparison if the test target drive is a > CD-ROM drive. > > As described in JDK-8343342, GetDiskSpaceInformationW can't g

Re: RFR: 8315487: Security Providers Filter [v13]

2024-11-29 Thread Martin Balao
> In addition to the goals, scope, motivation, specification and requirement > notes in [JDK-8315487](https://bugs.openjdk.org/browse/JDK-8315487), we would > like to describe the most relevant decisions taken during the implementation > of this enhancement. These notes are organized by feature,

Re: RFR: 8315487: Security Providers Filter [v12]

2024-11-29 Thread Martin Balao
> In addition to the goals, scope, motivation, specification and requirement > notes in [JDK-8315487](https://bugs.openjdk.org/browse/JDK-8315487), we would > like to describe the most relevant decisions taken during the implementation > of this enhancement. These notes are organized by feature,

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v3]

2024-11-29 Thread Erik Gahlin
On Fri, 29 Nov 2024 12:20:02 GMT, Nizar Benalla wrote: >> Can I please get a review for this PR that add tests to verify the value of >> `@since` tags to the Tools area modules. The test is described in this >> [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). >> Th

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 12:36:19 GMT, Maurizio Cimadamore wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix imports > > src/java.base/share/classes/jdk/internal/foreign/StringSupport.java line 187: > >> 185:

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 09:46:55 GMT, Per Minborg wrote: >> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, >> fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != >> 0`). >> >> This PR also improves performance on modern hardware, as there is no nee

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 09:46:55 GMT, Per Minborg wrote: >> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, >> fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != >> 0`). >> >> This PR also improves performance on modern hardware, as there is no nee

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 09:46:55 GMT, Per Minborg wrote: >> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, >> fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != >> 0`). >> >> This PR also improves performance on modern hardware, as there is no nee

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v2]

2024-11-29 Thread Nizar Benalla
On Fri, 29 Nov 2024 11:08:57 GMT, Nizar Benalla wrote: >> test/jdk/tools/sincechecker/modules/jdk.jlink/JdkJlinkCheckSince.java line >> 29: >> >>> 27: * @summary Test for `@since` in jdk.jlink module >>> 28: * @library /test/lib /test/jdk/tools/sincechecker >>> 29: * @run main SinceChecker j

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v3]

2024-11-29 Thread Nizar Benalla
> Can I please get a review for this PR that add tests to verify the value of > `@since` tags to the Tools area modules. The test is described in this > [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). > This issue is similar to JDK-8341399, JDK-8331051 and JDK-83434

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v3]

2024-11-29 Thread Christian Stein
On Fri, 29 Nov 2024 12:16:54 GMT, Nizar Benalla wrote: >> Can I please get a review for this PR that add tests to verify the value of >> `@since` tags to the Tools area modules. The test is described in this >> [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). >> Th

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 09:46:55 GMT, Per Minborg wrote: >> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, >> fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != >> 0`). >> >> This PR also improves performance on modern hardware, as there is no nee

Re: RFR: 8307513: C2: intrinsify Math.max(long,long) and Math.min(long,long) [v4]

2024-11-29 Thread Emanuel Peter
On Thu, 17 Oct 2024 10:10:56 GMT, Galder Zamarreño wrote: >> This patch intrinsifies `Math.max(long, long)` and `Math.min(long, long)` in >> order to help improve vectorization performance. >> >> Currently vectorization does not kick in for loops containing either of >> these calls because of

Integrated: 8345052: Harden StampedLock

2024-11-29 Thread Doug Lea
On Tue, 26 Nov 2024 18:07:41 GMT, Doug Lea wrote: > This applies the same kinds of recovery on OOME (by spinning) and JVM > Exceptions (by cancelling) seen in AQS. This pull request has now been integrated. Changeset: ece04010 Author:Doug Lea URL: https://git.openjdk.org/jdk/commit

Re: RFR: 8337199: Add jcmd Thread.vthread_scheduler and Thread.vthread_pollers diagnostic commands [v2]

2024-11-29 Thread Alan Bateman
On Fri, 29 Nov 2024 04:48:57 GMT, David Holmes wrote: > The two new `execute` methods differ only in the Symbol naming the method to > call. Can we not at least define a static helper in the file so that we don't > need to duplicate everything? Okay, esp. as we'll likely add more. At some poin

Re: RFR: 8337199: Add jcmd Thread.vthread_scheduler and Thread.vthread_pollers diagnostic commands [v3]

2024-11-29 Thread Alan Bateman
> Adds `jcmd Thread.vthread_scheduler` to print the virtual thread > scheduler and `jcmd Thread.vthread_pollers` to print the I/O pollers > that support virtual threads doing blocking network I/O operations. > > This is a subset of the diagnostics that we've had in the loom repo for a > long

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v2]

2024-11-29 Thread Nizar Benalla
On Fri, 29 Nov 2024 11:00:15 GMT, Christian Stein wrote: >> Nizar Benalla has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add backticks, as they are necessary. Otherwise the `@since` is treated as >> a jtreg tag >> >> Revert "remov

Re: RFR: 8343780: Add since checker tests to the Tools area modules and add missing @since to jdk.jfr.Recording [v2]

2024-11-29 Thread Christian Stein
On Thu, 14 Nov 2024 01:28:15 GMT, Nizar Benalla wrote: >> Can I please get a review for this PR that add tests to verify the value of >> `@since` tags to the Tools area modules. The test is described in this >> [email](https://mail.openjdk.org/pipermail/jdk-dev/2024-October/009474.html). >> Th

Re: RFR: 8341402: BigDecimal's square root optimization [v30]

2024-11-29 Thread fabioromano1
> After changing `BigInteger.sqrt()` algorithm, this can be also used to speed > up `BigDecimal.sqrt()` implementation. Here is how I made it. > > The main steps of the algorithm are as follows: > first argument reduce the value to an integer using the following relations: > > x = y * 10 ^ exp >

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Per Minborg
On Fri, 29 Nov 2024 09:01:35 GMT, Maurizio Cimadamore wrote: >> Per Minborg has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix imports > > src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java > line 400: > >> 3

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v3]

2024-11-29 Thread Per Minborg
> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods, > fixing a bug in the `short_strlen` variant for odd offsets (`offset % 2 != > 0`). > > This PR also improves performance on modern hardware, as there is no need for > pre-looping alignment. Removing this improves perfo

Re: RFR: 8341402: BigDecimal's square root optimization [v29]

2024-11-29 Thread fabioromano1
> After changing `BigInteger.sqrt()` algorithm, this can be also used to speed > up `BigDecimal.sqrt()` implementation. Here is how I made it. > > The main steps of the algorithm are as follows: > first argument reduce the value to an integer using the following relations: > > x = y * 10 ^ exp >

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort [v2]

2024-11-29 Thread Per Minborg
> This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods and > move them to the class `SegmentBulkOperations` where other bulk operations > reside. > > This PR fixes a bug in the `short_strlen` variant for offsets that were odd > (`offset % 2 != 0`). > > This PR also improves

Re: RFR: 8336768: Allow captureCallState and critical linker options to be combined [v2]

2024-11-29 Thread Maurizio Cimadamore
On Thu, 28 Nov 2024 15:22:18 GMT, Jorn Vernee wrote: >> Allow `captureCallState` and `critical(true)` linker options to be combined. >> This allows passing a Java array to capture call state. >> >> One caveat is that the linker expects the memory to be aligned, which means >> that at least an

Integrated: 8344989: Test java/foreign/TestLinker.java failed with zero: IllegalStateException: libffi call failed with status: FFI_BAD_TYPEDEF

2024-11-29 Thread Per Minborg
On Wed, 27 Nov 2024 16:27:34 GMT, Per Minborg wrote: > This PR proposes to check for empty layouts in the fallback linker and then > prevent them from being forwarded. > > Passes tier5 linker tests. This pull request has now been integrated. Changeset: f2c0d186 Author:Per Minborg URL:

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort

2024-11-29 Thread Maurizio Cimadamore
On Fri, 29 Nov 2024 07:55:25 GMT, Per Minborg wrote: > This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods and > move them to the class `SegmentBulkOperations` where other bulk operations > reside. > > This PR fixes a bug in the `short_strlen` variant for offsets that were

Re: RFR: 8340133: Add concise usage message to the java executable [v10]

2024-11-29 Thread Eirik Bjørsnøs
On Fri, 29 Nov 2024 07:25:23 GMT, Jan Lahoda wrote: >> Currently, running `java` without any parameters will lead to an output that >> is a full `--help`, which is over 100 lines (on my computer at least), and >> it feels overwhelming. And many people might actually want to run >> JShell/REPL,

Re: RFR: 8345052: Harden StampedLock [v2]

2024-11-29 Thread Viktor Klang
On Thu, 28 Nov 2024 12:25:28 GMT, Doug Lea wrote: >> This applies the same kinds of recovery on OOME (by spinning) and JVM >> Exceptions (by cancelling) seen in AQS. > > Doug Lea has updated the pull request with a new target base due to a merge > or a rebase. The incremental webrev excludes th

Re: RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort

2024-11-29 Thread Per Minborg
On Fri, 29 Nov 2024 07:55:25 GMT, Per Minborg wrote: > This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods and > move them to the class `SegmentBulkOperations` where other bulk operations > reside. > > This PR fixes a bug in the `short_strlen` variant for offsets that were

RFR: 8345120: A likely bug in StringSupport::chunkedStrlenShort

2024-11-29 Thread Per Minborg
This PR proposes to rewrite the `StringSupport::chunkedStrlen*` methods and move them to the class `SegmentBulkOperations` where other bulk operations reside. This PR fixes a bug in the `short_strlen` variant for offsets that were odd (`offset % 2 != 0`). This PR also improves performance on