RFR: JDK-8327640: Allow NumberFormat strict parsing

2024-03-18 Thread Justin Lu
Please review this PR and associated [CSR](https://bugs.openjdk.org/browse/JDK-8327703) which introduces strict parsing for NumberFormat. The concrete subclasses that will utilize this leniency value are `DecimalFormat` and `CompactNumberFormat`. Strict leniency allows for parsing to be used

Re: RFR: 8327839: Crash with unboxing and widening primitive conversion in switch [v2]

2024-03-18 Thread Aggelos Biboudis
> In cases where the compiler needs to unbox a `long`, `float`, `double` and > then run the exactness check, we were getting a crash. While the selector > value is always boxed, the type (which controls the execution flow) was not, > because the `selectorType` was wrong. This PR addresses this

Integrated: 8328074: Add jcheck whitespace checking for assembly files

2024-03-18 Thread Magnus Ihse Bursie
On Wed, 13 Mar 2024 11:18:20 GMT, Magnus Ihse Bursie wrote: > As part of the ongoing effort to enable jcheck whitespace checking to all > text files, it is now time to address assembly (.S) files. The hotspot > assembly files were fixed as part of the hotspot mapfile removal, so only a >

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v20]

2024-03-18 Thread Severin Gehwolf
On Fri, 15 Mar 2024 18:09:36 GMT, Mandy Chung wrote: > > Wasn't the intention to make "creating a linkable runtime image" a build > > only decision and make the relevant infrastructure classes build-only > > artefacts? > > Build-only decision means that the linkable runtime image is only

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v20]

2024-03-18 Thread Severin Gehwolf
On Fri, 15 Mar 2024 19:29:49 GMT, Mandy Chung wrote: > > > If `--enable-runtime-link-image` is enabled, the JDK image does not > > > include the packaged modules. > > > > > > That's not true. Right now `--enable-runtime-link-image` modifies how the > > `lib/modules` image looks like (adds a

RFR: 8328177: Move LDFLAGS_JDK[LIB/EXE] to JdkNativeCompilation.gmk

2024-03-18 Thread Magnus Ihse Bursie
Similar to [JDK-8328157](https://bugs.openjdk.org/browse/JDK-8328157), we want to move the setting of LDFLAGS to LDFLAGS_JDK[LIB/EXE into SetupJdkLibrary and SetupJdkExecutable. - Commit messages: - 8328177: Move LDFLAGS_JDK[LIB/EXE] to JdkNativeCompilation.gmk Changes:

Re: RFR: 8328074: Add jcheck whitespace checking for assembly files [v4]

2024-03-18 Thread Magnus Ihse Bursie
On Sat, 16 Mar 2024 00:08:04 GMT, Sandhya Viswanathan wrote: >> Magnus Ihse Bursie has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Make all ALIGN/.align aligned > > Looks good to me. Thanks @sviswa7! - PR Comment:

Re: RFR: 7036144: GZIPInputStream readTrailer uses faulty available() test for end-of-stream [v9]

2024-03-18 Thread Jaikiran Pai
On Sun, 17 Mar 2024 22:53:55 GMT, Archie Cobbs wrote: >> `GZIPInputStream`, when looking for a concatenated stream, relies on what >> the underlying `InputStream` says is how many bytes are `available()`. But >> this is inappropriate because `InputStream.available()` is just an estimate >>

Re: RFR: JDK-8326853 Missing @since tags for Charset related methods added in Java 10 [v6]

2024-03-18 Thread Nizar Benalla
> # Issue > - JDK-8326853 Incorrect @\since Tags for Charset Related Methods Added in JDK > 10 > > I changed the @\since tags to better accurately show when the methods and > constructors were introduced. Nizar Benalla has updated the pull request incrementally with one additional commit

Integrated: 8327839: Crash with unboxing and widening primitive conversion in switch

2024-03-18 Thread Aggelos Biboudis
On Tue, 12 Mar 2024 14:06:11 GMT, Aggelos Biboudis wrote: > In cases where the compiler needs to unbox a `long`, `float`, `double` and > then run the exactness check, we were getting a crash. While the selector > value is always boxed, the type (which controls the execution flow) was not, >

Re: RFR: 8326941: Remove StringUTF16::isBigEndian

2024-03-18 Thread Per Minborg
On Mon, 18 Mar 2024 14:35:06 GMT, Claes Redestad wrote: > Does this change how early `Unsafe` is initialized, and does it in turn have > dependencies on `StringUTF16`? `StringUTF16` is loaded very early, especially > if `-XX:-CompactStrings` is supplied and I would assume the only reason this

Re: RFR: 8326941: Remove StringUTF16::isBigEndian

2024-03-18 Thread Roger Riggs
On Mon, 18 Mar 2024 14:09:09 GMT, Per Minborg wrote: > This PR proposes to remove the native method `StringUTF16::isBigEndian` and > its corresponding C implementation and instead rely on the > `jdk.internal.misc.Unsafe::isBigEndian` method. Nice Cleanup. - Marked as reviewed by

Re: RFR: 8326941: Remove StringUTF16::isBigEndian

2024-03-18 Thread Claes Redestad
On Mon, 18 Mar 2024 14:09:09 GMT, Per Minborg wrote: > This PR proposes to remove the native method `StringUTF16::isBigEndian` and > its corresponding C implementation and instead rely on the > `jdk.internal.misc.Unsafe::isBigEndian` method. Does this change how early `Unsafe` is initialized,

RFR: JDK-8327474 Review use of java.io.tmpdir in jdk tests

2024-03-18 Thread Bill Huang
This task addresses an essential aspect of our testing infrastructure: the proper handling and cleanup of temporary files and socket files created during test execution. The motivation behind these changes is to prevent the accumulation of unnecessary files in the default temporary directory,

RFR: 8297879: javadoc link to preview JEP 1000 has grouping character comma

2024-03-18 Thread Pavel Rappo
Please review this simple bugfix to properly construct links to preview JEPs. The most straightforward fix I could think of was to pass `String` rather than `int` (`Integer`) to a method, which eventually calls `java.text.MessageFormat.format(String, Object...)`. For the test, I decided to be

Re: RFR: 8297879: javadoc link to preview JEP 1000 has grouping character comma

2024-03-18 Thread Jonathan Gibbons
On Mon, 18 Mar 2024 14:53:44 GMT, Pavel Rappo wrote: > Please review this simple bugfix to properly construct links to preview JEPs. > > The most straightforward fix I could think of was to pass `String` rather > than `int` (`Integer`) to a method, which eventually calls >

Re: RFR: 8327964: Simplify BigInteger.implMultiplyToLen intrinsic

2024-03-18 Thread Roger Riggs
On Tue, 12 Mar 2024 10:44:54 GMT, Yudi Zheng wrote: > Moving array construction within BigInteger.implMultiplyToLen intrinsic > candidate to its caller simplifies the intrinsic implementation in JIT > compiler. src/java.base/share/classes/java/math/BigInteger.java line 1836: > 1834: > 1835:

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v2]

2024-03-18 Thread Suchismith Roy
On Mon, 18 Mar 2024 17:24:05 GMT, Jaikiran Pai wrote: >> Suchismith Roy has updated the pull request incrementally with seven >> additional commits since the last revision: >> >> - remove space >> - remove debug print lines >> - remove debug print lines >> - remove debug lines >> -

Integrated: 8327180: Failed: java/io/ObjectStreamClass/ObjectStreamClassCaching.java#G1

2024-03-18 Thread Roger Riggs
On Wed, 13 Mar 2024 18:01:21 GMT, Roger Riggs wrote: > The intermittent failure of ObjectStreamClassCaching is due to an incorrect > assumption about GC behavior and a race condition. > > Removed test based on incorrect assumptions about simultaneous clearing of > WeakReferences. > Added a

Re: RFR: 8327180: Failed: java/io/ObjectStreamClass/ObjectStreamClassCaching.java#G1 [v3]

2024-03-18 Thread Roger Riggs
On Wed, 13 Mar 2024 20:10:25 GMT, Roger Riggs wrote: >> The intermittent failure of ObjectStreamClassCaching is due to an incorrect >> assumption about GC behavior and a race condition. >> >> Removed test based on incorrect assumptions about simultaneous clearing of >> WeakReferences. >>

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v2]

2024-03-18 Thread Suchismith Roy
> Allow support for both .a and .so files in AIX. > If .so file is not found, allow fallback to .a extension. > JBS Issue: [JDK-8319516](https://bugs.openjdk.org/browse/JDK-8319516) Suchismith Roy has updated the pull request incrementally with seven additional commits since the last revision:

RFR: 8326941: Remove StringUTF16::isBigEndian

2024-03-18 Thread Per Minborg
This PR proposes to remove the native method `StringUTF16::isBigEndian` and its corresponding C implementation and instead rely on the `jdk.internal.misc.Unsafe::isBigEndian` method. - Commit messages: - Update copyright years - Remove native method Changes:

Re: RFR: 8297879: javadoc link to preview JEP 1000 has grouping character comma

2024-03-18 Thread Vicente Romero
On Mon, 18 Mar 2024 14:53:44 GMT, Pavel Rappo wrote: > Please review this simple bugfix to properly construct links to preview JEPs. > > The most straightforward fix I could think of was to pass `String` rather > than `int` (`Integer`) to a method, which eventually calls >

Re: RFR: 8326744: Class-File API transition to Second Preview

2024-03-18 Thread Jan Lahoda
On Tue, 27 Feb 2024 08:45:12 GMT, Adam Sotona wrote: > Task providing Class-File API transition to Second Preview. Looks good to me. - Marked as reviewed by jlahoda (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/18021#pullrequestreview-1943355591

Re: RFR: 8327964: Simplify BigInteger.implMultiplyToLen intrinsic

2024-03-18 Thread Damon Fenacci
On Tue, 12 Mar 2024 10:44:54 GMT, Yudi Zheng wrote: > Moving array construction within BigInteger.implMultiplyToLen intrinsic > candidate to its caller simplifies the intrinsic implementation in JIT > compiler. Quite a simplification! Have you checked if there are any performance differences?

Re: RFR: 8297879: javadoc link to preview JEP 1000 has grouping character comma

2024-03-18 Thread Pavel Rappo
On Mon, 18 Mar 2024 14:53:44 GMT, Pavel Rappo wrote: > Please review this simple bugfix to properly construct links to preview JEPs. > > The most straightforward fix I could think of was to pass `String` rather > than `int` (`Integer`) to a method, which eventually calls >

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v2]

2024-03-18 Thread Jaikiran Pai
On Mon, 18 Mar 2024 16:17:41 GMT, Suchismith Roy wrote: >> Allow support for both .a and .so files in AIX. >> If .so file is not found, allow fallback to .a extension. >> JBS Issue: [JDK-8319516](https://bugs.openjdk.org/browse/JDK-8319516) > > Suchismith Roy has updated the pull request

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v20]

2024-03-18 Thread Erik Joelsson
On Mon, 18 Mar 2024 18:40:36 GMT, Severin Gehwolf wrote: > What I mean to convey is that how the directory tree in `images/jdk` looks > like shouldn't change based on the `--enable-linkable-runtime-image` > configure flag. That is, there will be a `images/jdk/jmods` folder unless >

Re: RFR: 8314480: Memory ordering spec updates in java.lang.ref [v13]

2024-03-18 Thread Y . Srinivas Ramakrishna
On Thu, 14 Mar 2024 23:23:07 GMT, Brent Christian wrote: >> Classes in the `java.lang.ref` package would benefit from an update to bring >> the spec in line with how the VM already behaves. The changes would focus on >> _happens-before_ edges at some key points during reference processing. >>

Re: RFR: 8326941: Remove StringUTF16::isBigEndian

2024-03-18 Thread Claes Redestad
On Mon, 18 Mar 2024 14:09:09 GMT, Per Minborg wrote: > This PR proposes to remove the native method `StringUTF16::isBigEndian` and > its corresponding C implementation and instead rely on the > `jdk.internal.misc.Unsafe::isBigEndian` method. > > This PR passes tier1-3 tests. > Initialization

Re: RFR: JDK-8327640: Allow NumberFormat strict parsing [v2]

2024-03-18 Thread Justin Lu
> Please review this PR and associated > [CSR](https://bugs.openjdk.org/browse/JDK-8327703) which introduces strict > parsing for NumberFormat. > > The concrete subclasses that will utilize this leniency value are > `DecimalFormat` and `CompactNumberFormat`. Strict leniency allows for parsing

Re: RFR: JDK-8327474 Review use of java.io.tmpdir in jdk tests

2024-03-18 Thread Alan Bateman
On Mon, 18 Mar 2024 16:47:24 GMT, Bill Huang wrote: > This task addresses an essential aspect of our testing infrastructure: the > proper handling and cleanup of temporary files and socket files created > during test execution. The motivation behind these changes is to prevent the >

Re: RFR: JDK-8326853 Missing @since tags for Charset related methods added in Java 10 [v6]

2024-03-18 Thread Justin Lu
On Mon, 18 Mar 2024 12:44:46 GMT, Nizar Benalla wrote: >> # Issue >> - JDK-8326853 Incorrect @\since Tags for Charset Related Methods Added in >> JDK 10 >> >> I changed the @\since tags to better accurately show when the methods and >> constructors were introduced. > > Nizar Benalla has

Re: RFR: 8328261: public lookup fails with IllegalAccessException when used while module system is being initialized

2024-03-18 Thread Alan Bateman
On Mon, 18 Mar 2024 17:40:26 GMT, Mandy Chung wrote: > A simple fix. This is caused by a bug in `VerifyAccess::isClassAccessible` > that checks if a class is exported from `java.base` before the exports are > fully setup.It should check if the module system is fully initialized > before

Re: RFR: 8314480: Memory ordering spec updates in java.lang.ref [v13]

2024-03-18 Thread David Holmes
On Tue, 19 Mar 2024 00:40:02 GMT, Y. Srinivas Ramakrishna wrote: >> Brent Christian has updated the pull request incrementally with one >> additional commit since the last revision: >> >> further tweaks to reachability > > src/java.base/share/classes/java/lang/ref/package-info.java line

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v3]

2024-03-18 Thread Suchismith Roy
> Allow support for both .a and .so files in AIX. > If .so file is not found, allow fallback to .a extension. > JBS Issue: [JDK-8319516](https://bugs.openjdk.org/browse/JDK-8319516) Suchismith Roy has updated the pull request incrementally with one additional commit since the last revision:

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v20]

2024-03-18 Thread Mandy Chung
On Mon, 18 Mar 2024 13:01:10 GMT, Severin Gehwolf wrote: > Yes we do. The main reason being that the `jdk` image has more to it than > just the image. `src.zip`, CDS data, `demo` and so on. We don't want to > duplicate that. To us, including the `jmods` folder is something that comes > into

Re: RFR: 8327964: Simplify BigInteger.implMultiplyToLen intrinsic

2024-03-18 Thread Dean Long
On Tue, 12 Mar 2024 10:44:54 GMT, Yudi Zheng wrote: > Moving array construction within BigInteger.implMultiplyToLen intrinsic > candidate to its caller simplifies the intrinsic implementation in JIT > compiler. src/hotspot/share/opto/library_call.cpp line 5934: > 5932: // 'y_start'

Re: RFR: 8328261: public lookup fails with IllegalAccessException when used while module system is being initialized

2024-03-18 Thread Roger Riggs
On Mon, 18 Mar 2024 17:40:26 GMT, Mandy Chung wrote: > A simple fix. This is caused by a bug in `VerifyAccess::isClassAccessible` > that checks if a class is exported from `java.base` before the exports are > fully setup.It should check if the module system is fully initialized > before

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v21]

2024-03-18 Thread Mandy Chung
On Fri, 15 Mar 2024 15:19:17 GMT, Severin Gehwolf wrote: >> Please review this patch which adds a jlink mode to the JDK which doesn't >> need the packaged modules being present. A.k.a run-time image based jlink. >> Fundamentally this patch adds an option to use `jlink` even though your JDK >>

Re: RFR: 8314480: Memory ordering spec updates in java.lang.ref [v13]

2024-03-18 Thread Brent Christian
On Sat, 16 Mar 2024 04:21:55 GMT, Stuart Marks wrote: >> Brent Christian has updated the pull request incrementally with one >> additional commit since the last revision: >> >> further tweaks to reachability > > src/java.base/share/classes/java/lang/ref/package-info.java line 127: > >> 125:

RFR: 8328261: public lookup fails with IllegalAccessException when used while module system is being initialized

2024-03-18 Thread Mandy Chung
A simple fix. This is caused by a bug in `VerifyAccess::isClassAccessible` that checks if a class is exported from `java.base` before the exports are fully setup.It should check if the module system is fully initialized before checking the module exports instead. - Commit

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v4]

2024-03-18 Thread Suchismith Roy
> Allow support for both .a and .so files in AIX. > If .so file is not found, allow fallback to .a extension. > JBS Issue: [JDK-8319516](https://bugs.openjdk.org/browse/JDK-8319516) Suchismith Roy has updated the pull request incrementally with one additional commit since the last revision:

Re: RFR: 8311302: Allow for jlinking a custom runtime without packaged modules being present [v20]

2024-03-18 Thread Severin Gehwolf
On Mon, 18 Mar 2024 18:08:23 GMT, Mandy Chung wrote: > > Yes we do. The main reason being that the `jdk` image has more to it than > > just the image. `src.zip`, CDS data, `demo` and so on. We don't want to > > duplicate that. To us, including the `jmods` folder is something that comes > >

Re: RFR: 8314480: Memory ordering spec updates in java.lang.ref [v13]

2024-03-18 Thread Brent Christian
On Sat, 16 Mar 2024 04:20:44 GMT, Stuart Marks wrote: >> Brent Christian has updated the pull request incrementally with one >> additional commit since the last revision: >> >> further tweaks to reachability > > src/java.base/share/classes/java/lang/ref/Reference.java line 402: > >> 400:

Re: RFR: JDK-8319516 - Native library suffix impact on the library loading in AIX- Java Class Loader [v2]

2024-03-18 Thread Jaikiran Pai
On Mon, 18 Mar 2024 17:31:21 GMT, Suchismith Roy wrote: > In AIX, we have an usecase where shared libraries have certain member objects > to be referred to. E.g libclang.a(shr_64.o) . Would you happen to know any official documentation which explains that AIX syntax? > When we provide the

Re: RFR: 8314480: Memory ordering spec updates in java.lang.ref [v14]

2024-03-18 Thread Brent Christian
> Classes in the `java.lang.ref` package would benefit from an update to bring > the spec in line with how the VM already behaves. The changes would focus on > _happens-before_ edges at some key points during reference processing. > > A couple key things we want to be able to say are: > -