Re: RFR: JDK-8266431: Dual-Pivot Quicksort improvements (Radix sort) [v11]

2023-12-08 Thread Srinivas Vamsi Parasa
On Fri, 8 Dec 2023 20:08:22 GMT, Vladimir Yaroslavskiy wrote: >> Hi Vladimir (@iaroslavski), >> >> Please see the data below. >> >> Thanks, >> Vamsi >> >> > xmlns:o="urn:schemas-microsoft-com:office:office" >> xmlns:x="urn:schemas-microsoft-com:office:excel" >>

Integrated: 8319577: x86_64 AVX2 intrinsics for Arrays.sort methods (int, float arrays)

2023-12-08 Thread Srinivas Vamsi Parasa
On Tue, 7 Nov 2023 00:12:41 GMT, Srinivas Vamsi Parasa wrote: > The goal is to develop faster sort routines for x86_64 CPUs by taking > advantage of AVX2 instructions. This enhancement provides an order of > magnitude speedup for Arrays.sort() using int, long, float and double arrays. > > For

Re: RFR: 8319577: x86_64 AVX2 intrinsics for Arrays.sort methods (int, float arrays) [v12]

2023-12-08 Thread Srinivas Vamsi Parasa
On Fri, 8 Dec 2023 22:37:26 GMT, Vladimir Kozlov wrote: > I pushed closed changes. Thanks Vladimir! - PR Comment: https://git.openjdk.org/jdk/pull/16534#issuecomment-1847939767

Re: RFR: 8319577: x86_64 AVX2 intrinsics for Arrays.sort methods (int, float arrays) [v12]

2023-12-08 Thread Vladimir Kozlov
On Wed, 6 Dec 2023 23:12:13 GMT, Srinivas Vamsi Parasa wrote: >> The goal is to develop faster sort routines for x86_64 CPUs by taking >> advantage of AVX2 instructions. This enhancement provides an order of >> magnitude speedup for Arrays.sort() using int, long, float and double arrays. >>

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Glavo
On Mon, 20 Nov 2023 17:18:11 GMT, Per Minborg wrote: > Can we use `Objects::checkIndex` here instead? No, because these classes need to be compiled with `--release 8`. Javadoc: /** * @implNote This class needs to maintain JDK 8 source compatibility. * * It is used internally in the JDK to

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Claes Redestad
On Fri, 8 Dec 2023 21:35:34 GMT, Glavo wrote: > Does anyone want to take a look at this PR? RFE: https://bugs.openjdk.org/browse/JDK-8321620 - update the bug ID and this should PR should reach a wider audience. I'll have some time next week to help review. - PR Comment:

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Claes Redestad
On Wed, 8 Nov 2023 11:55:22 GMT, Glavo wrote: > This PR significantly speeds up decompressing resources in Jimage while > significantly reducing temporary memory allocations in the process. > > This will improve startup speed for runtime images generated using `jlink > --compress 1` and

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Per Minborg
On Wed, 8 Nov 2023 11:55:22 GMT, Glavo wrote: > This PR significantly speeds up decompressing resources in Jimage while > significantly reducing temporary memory allocations in the process. > > This will improve startup speed for runtime images generated using `jlink > --compress 1` and

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Chen Liang
On Wed, 8 Nov 2023 11:55:22 GMT, Glavo wrote: > This PR significantly speeds up decompressing resources in Jimage while > significantly reducing temporary memory allocations in the process. > > This will improve startup speed for runtime images generated using `jlink > --compress 1` and

RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Glavo
This PR significantly speeds up decompressing resources in Jimage while significantly reducing temporary memory allocations in the process. This will improve startup speed for runtime images generated using `jlink --compress 1` and `jlink --compress 2` . I generated a runtime image containing

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Glavo
On Wed, 8 Nov 2023 11:55:22 GMT, Glavo wrote: > This PR significantly speeds up decompressing resources in Jimage while > significantly reducing temporary memory allocations in the process. > > This will improve startup speed for runtime images generated using `jlink > --compress 1` and

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Glavo
On Thu, 9 Nov 2023 02:07:57 GMT, Chen Liang wrote: >> This PR significantly speeds up decompressing resources in Jimage while >> significantly reducing temporary memory allocations in the process. >> >> This will improve startup speed for runtime images generated using `jlink >> --compress 1`

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Sergey Tsypanov
On Wed, 8 Nov 2023 11:55:22 GMT, Glavo wrote: > This PR significantly speeds up decompressing resources in Jimage while > significantly reducing temporary memory allocations in the process. > > This will improve startup speed for runtime images generated using `jlink > --compress 1` and

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Claes Redestad
On Mon, 20 Nov 2023 17:39:19 GMT, Glavo wrote: >> src/java.base/share/classes/jdk/internal/jimage/decompressor/StringSharingDecompressor.java >> line 94: >> >>> 92:int offset, long originalSize) >>> throws IOException { >>> 93: if (originalSize >

Re: RFR: 8321620: Optimize JImage decompressors

2023-12-08 Thread Glavo
On Mon, 20 Nov 2023 23:36:51 GMT, Claes Redestad wrote: > But to make comparisons fair you need to take care to compare apples to > apples: is the uncompressed baseline a similar jlink image generated without > --compress? Or the default JDK image (uncompressed, with CDS)? The uncompressed

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one [v3]

2023-12-08 Thread Roger Riggs
> In the compact string implementation of non-latin1 (UTF16) strings the length > is constrained by VM implementation limit on the size a byte array that can > be allocated. To produce a useful exception the implementation checks the > string size against the maximum byte array size. The

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v7]

2023-12-08 Thread Sergey Tsypanov
> It looks like we can skip copying of `byte[]` in > `BufferedInputStream.implTransferTo()` for `OutputStreams` residing in > `java.io`. > > See comment by @vlsi in > https://github.com/openjdk/jdk/pull/10525/files#diff-e19c508d1bb6ee78697ecca66947c395adda0d9c49a85bf696e677ecbd977af1R612

Re: RFR: 8321206: Make Locale related system properties `StaticProperty` [v2]

2023-12-08 Thread Naoto Sato
On Wed, 6 Dec 2023 20:55:48 GMT, Naoto Sato wrote: >> Currently, Locale-related system properties, such as `user.language` or >> `user.country`, are initialized when the `Locale` class is loaded. Making >> them static properties is safer than relying on the `Locale` class loading >> timing,

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v6]

2023-12-08 Thread Sergey Tsypanov
> It looks like we can skip copying of `byte[]` in > `BufferedInputStream.implTransferTo()` for `OutputStreams` residing in > `java.io`. > > See comment by @vlsi in > https://github.com/openjdk/jdk/pull/10525/files#diff-e19c508d1bb6ee78697ecca66947c395adda0d9c49a85bf696e677ecbd977af1R612

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one [v2]

2023-12-08 Thread Raffaello Giulietti
On Fri, 8 Dec 2023 19:50:30 GMT, Roger Riggs wrote: >> In the compact string implementation of non-latin1 (UTF16) strings the >> length is constrained by VM implementation limit on the size a byte array >> that can be allocated. To produce a useful exception the implementation >> checks the

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v5]

2023-12-08 Thread Sergey Tsypanov
On Fri, 8 Dec 2023 17:23:59 GMT, Markus KARG wrote: >> Sergey Tsypanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8320971: Use same approach as BAOS > > src/java.base/share/classes/java/io/OutputStream.java line 212: > >> 210:

Re: RFR: JDK-8266431: Dual-Pivot Quicksort improvements (Radix sort) [v11]

2023-12-08 Thread Vladimir Yaroslavskiy
On Fri, 8 Dec 2023 01:27:35 GMT, Srinivas Vamsi Parasa wrote: >> Hello Vamsi (@vamsi-parasa), >> >> Did you have a chance to run benchmarking? > > Hi Vladimir (@iaroslavski), > > Please see the data below. > > Thanks, > Vamsi > > xmlns:o="urn:schemas-microsoft-com:office:office" >

Re: RFR: 8321206: Make Locale related system properties `StaticProperty` [v2]

2023-12-08 Thread Bernd
On Wed, 6 Dec 2023 20:55:48 GMT, Naoto Sato wrote: >> Currently, Locale-related system properties, such as `user.language` or >> `user.country`, are initialized when the `Locale` class is loaded. Making >> them static properties is safer than relying on the `Locale` class loading >> timing,

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one [v2]

2023-12-08 Thread Roger Riggs
On Fri, 8 Dec 2023 19:32:02 GMT, Raffaello Giulietti wrote: >> src/java.base/share/classes/java/lang/StringUTF16.java line 59: >> >>> 57: if (len >= MAX_LENGTH) { >>> 58: throw new OutOfMemoryError("UTF16 String size is " + len + >>> 59:

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one [v2]

2023-12-08 Thread Roger Riggs
> In the compact string implementation of non-latin1 (UTF16) strings the length > is constrained by VM implementation limit on the size a byte array that can > be allocated. To produce a useful exception the implementation checks the > string size against the maximum byte array size. The

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one

2023-12-08 Thread Raffaello Giulietti
On Fri, 8 Dec 2023 16:28:21 GMT, ExE Boss wrote: >> In the compact string implementation of non-latin1 (UTF16) strings the >> length is constrained by VM implementation limit on the size a byte array >> that can be allocated. To produce a useful exception the implementation >> checks the

Integrated: 8321206: Make Locale related system properties `StaticProperty`

2023-12-08 Thread Naoto Sato
On Tue, 5 Dec 2023 23:04:55 GMT, Naoto Sato wrote: > Currently, Locale-related system properties, such as `user.language` or > `user.country`, are initialized when the `Locale` class is loaded. Making > them static properties is safer than relying on the `Locale` class loading > timing, which

Re: RFR: 8321206: Make Locale related system properties `StaticProperty` [v2]

2023-12-08 Thread Naoto Sato
On Wed, 6 Dec 2023 20:55:48 GMT, Naoto Sato wrote: >> Currently, Locale-related system properties, such as `user.language` or >> `user.country`, are initialized when the `Locale` class is loaded. Making >> them static properties is safer than relying on the `Locale` class loading >> timing,

Re: RFR: JDK-8266431: Dual-Pivot Quicksort improvements (Radix sort) [v11]

2023-12-08 Thread Vladimir Yaroslavskiy
On Fri, 8 Dec 2023 01:27:35 GMT, Srinivas Vamsi Parasa wrote: >> Hello Vamsi (@vamsi-parasa), >> >> Did you have a chance to run benchmarking? > > Hi Vladimir (@iaroslavski), > > Please see the data below. > > Thanks, > Vamsi > > xmlns:o="urn:schemas-microsoft-com:office:office" >

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v5]

2023-12-08 Thread Alan Bateman
On Fri, 8 Dec 2023 17:54:21 GMT, Vladimir Sitnikov wrote: >> src/java.base/share/classes/java/io/OutputStream.java line 212: >> >>> 210: * @return true if the argument of {@link #write(byte[])}} and >>> {@link #write(byte[], int, int)}} needn't be copied >>> 211: */ >>> 212:

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v5]

2023-12-08 Thread Vladimir Sitnikov
On Fri, 8 Dec 2023 17:23:59 GMT, Markus KARG wrote: >> Sergey Tsypanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8320971: Use same approach as BAOS > > src/java.base/share/classes/java/io/OutputStream.java line 212: > >> 210:

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v5]

2023-12-08 Thread Markus KARG
On Fri, 8 Dec 2023 15:46:31 GMT, Sergey Tsypanov wrote: >> It looks like we can skip copying of `byte[]` in >> `BufferedInputStream.implTransferTo()` for `OutputStreams` residing in >> `java.io`. >> >> See comment by @vlsi in >>

Integrated: 8316141: Improve CEN header validation checking

2023-12-08 Thread Lance Andersen
On Wed, 8 Nov 2023 19:59:34 GMT, Lance Andersen wrote: > Please review this PR which enhances the existing CEN header validation > checking to ensure that the > size of the CEN Header + name length + comment length + extra length do not > exceed 65,535 bytes per the PKWare APP.NOTE 4.4.10,

Re: RFR: 8321180: Condition for non-latin1 string size too large exception is off by one

2023-12-08 Thread ExE Boss
On Wed, 6 Dec 2023 23:31:26 GMT, Roger Riggs wrote: > In the compact string implementation of non-latin1 (UTF16) strings the length > is constrained by VM implementation limit on the size a byte array that can > be allocated. To produce a useful exception the implementation checks the >

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v5]

2023-12-08 Thread Sergey Tsypanov
> It looks like we can skip copying of `byte[]` in > `BufferedInputStream.implTransferTo()` for `OutputStreams` residing in > `java.io`. > > See comment by @vlsi in > https://github.com/openjdk/jdk/pull/10525/files#diff-e19c508d1bb6ee78697ecca66947c395adda0d9c49a85bf696e677ecbd977af1R612

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

2023-12-08 Thread Alan Bateman
On Tue, 5 Dec 2023 19:15:53 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: 8268276: Base64 Decoding optimization for x86 using AVX-512 [v8]

2023-12-08 Thread Evgeny Astigeevich
On Thu, 24 Jun 2021 17:02:03 GMT, Scott Gibbons wrote: >> Add the Base64 Decode intrinsic for x86 to utilize AVX-512 for acceleration. >> Also allows for performance improvement for non-AVX-512 enabled platforms. >> Due to the nature of MIME-encoded inputs, modify the intrinsic signature to

Re: RFR: 8320971: Use BufferedInputStream.buf directly when param of implTransferTo() is trusted [v4]

2023-12-08 Thread Sergey Tsypanov
> It looks like we can skip copying of `byte[]` in > `BufferedInputStream.implTransferTo()` for `OutputStreams` residing in > `java.io`. > > See comment by @vlsi in > https://github.com/openjdk/jdk/pull/10525/files#diff-e19c508d1bb6ee78697ecca66947c395adda0d9c49a85bf696e677ecbd977af1R612

Re: RFR: 8321396: Retire test/jdk/java/util/zip/NoExtensionSignature.java

2023-12-08 Thread Eirik Bjorsnos
On Tue, 5 Dec 2023 15:58:14 GMT, Eirik Bjorsnos wrote: > Please review this PR which suggests we retire the ZIP test > `NoExtensionSignature` along with its `test.jar` test vector. > > The concern of a missing data descriptor signature is covered by the recently > updated

Re: RFR: 8311218: fatal error: stuck in JvmtiVTMSTransitionDisabler::VTMS_transition_disable [v3]

2023-12-08 Thread Alan Bateman
On Fri, 8 Dec 2023 11:54:40 GMT, Serguei Spitsyn wrote: >> This fix is for JDK 23 but the intention is to back port it to 22 in RDP-1 >> time frame. >> It is fixing a deadlock issue between `VirtualThread` class critical >> sections with the `interruptLock` (in methods: `unpark()`,

Re: RFR: 8311218: fatal error: stuck in JvmtiVTMSTransitionDisabler::VTMS_transition_disable [v3]

2023-12-08 Thread Serguei Spitsyn
> This fix is for JDK 23 but the intention is to back port it to 22 in RDP-1 > time frame. > It is fixing a deadlock issue between `VirtualThread` class critical sections > with the `interruptLock` (in methods: `unpark()`, `interrupt()`, > `getAndClearInterrupt()`, `threadState()`,

Re: RFR: JDK-8319626: Override toString() for ZipFile [v7]

2023-12-08 Thread Jaikiran Pai
On Fri, 1 Dec 2023 21:32:57 GMT, Justin Lu wrote: >> Please review this PR and [CSR](https://bugs.openjdk.org/browse/JDK-8319982) >> which overrides and provides an implementation of `toString()` in >> _java.util.zip.ZipFile_ (and by extension, _java.util.jar.JarFile_). > > Justin Lu has

Re: RFR: 8316141: Improve CEN header validation checking

2023-12-08 Thread Alan Bateman
On Wed, 8 Nov 2023 19:59:34 GMT, Lance Andersen wrote: > Please review this PR which enhances the existing CEN header validation > checking to ensure that the > size of the CEN Header + name length + comment length + extra length do not > exceed 65,535 bytes per the PKWare APP.NOTE 4.4.10,

Integrated: 8320786: Remove ThreadGroup.stop

2023-12-08 Thread Alan Bateman
On Mon, 27 Nov 2023 16:58:29 GMT, Alan Bateman wrote: > ThreadGroup.stop was deprecated since JDK 1.2, deprecated for removal in Java > 18, and re-specified/degraded to throw UnsupportedOperationException > unconditionally in Java 20. Early in Java 23 seems a fine time to finally > remove