Re: RFR: 8334342: Add MergeStore JMH benchmarks [v7]

2024-07-24 Thread duke
On Wed, 24 Jul 2024 16:00:10 GMT, Shaojin Wen wrote: >> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We >> need a JMH Benchmark to evaluate the performance of various batch operations >> and the effect of MergeStore. > > Shaojin Wen has updated the pull request with

Re: RFR: 8337168: Optimize LocalDateTime.toString

2024-07-24 Thread Shaojin Wen
On Thu, 25 Jul 2024 05:06:17 GMT, Shaojin Wen wrote: > The current LocalDateTime.toString implementation concatenates the toString > results of date and time, which can be passed to StringBuilder to reduce > additional object allocation and improve performance. Below are the performance number

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v7]

2024-07-24 Thread Emanuel Peter
On Wed, 24 Jul 2024 16:00:10 GMT, Shaojin Wen wrote: >> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We >> need a JMH Benchmark to evaluate the performance of various batch operations >> and the effect of MergeStore. > > Shaojin Wen has updated the pull request with

RFR: 8337167: StringSize deduplication

2024-07-24 Thread Shaojin Wen
Integer.stringSize and Long.stringSize are used not only in java.lang, but also in other places. We put stringSize in DecimalDigits to reduce duplicate code and the use of JLA. - Commit messages: - stringSize deduplication Changes: https://git.openjdk.org/jdk/pull/20322/files We

RFR: 8337168: Optimize LocalDateTime.toString

2024-07-24 Thread Shaojin Wen
The current LocalDateTime.toString implementation concatenates the toString results of date and time, which can be passed to StringBuilder to reduce additional object allocation and improve performance. - Commit messages: - optimize LocalDateTime.toString, reduce StringBuilder allo

Integrated: 8336254: Virtual thread implementation + test updates

2024-07-24 Thread Alan Bateman
On Thu, 11 Jul 2024 17:30:21 GMT, Alan Bateman wrote: > Bringover some of the changes accumulated in the loom repo to the main line, > most of these changes are test updates and have been baking in the loom repo > for several months. The motive is partly to reduce the large set of changes > th

Re: RFR: 8335150: Test LogGeneratedClassesTest.java fails on rpmbuild mock enviroment [v2]

2024-07-24 Thread Jaikiran Pai
On Wed, 26 Jun 2024 15:40:36 GMT, SendaoYan wrote: >> Hi all, >> Test `test/jdk/java/lang/invoke/lambda/LogGeneratedClassesTest.java` fails >> on rpm build mock environment. The `df -h` command return fail `df: cannot >> read table of mounted file systems: No such file or directory` on the rpm

Re: RFR: 8335150: Test LogGeneratedClassesTest.java fails on rpmbuild mock enviroment [v2]

2024-07-24 Thread SendaoYan
On Wed, 26 Jun 2024 15:40:36 GMT, SendaoYan wrote: >> Hi all, >> Test `test/jdk/java/lang/invoke/lambda/LogGeneratedClassesTest.java` fails >> on rpm build mock environment. The `df -h` command return fail `df: cannot >> read table of mounted file systems: No such file or directory` on the rpm

Re: RFR: 8333893: Optimization for StringBuilder append boolean & null [v4]

2024-07-24 Thread Shaojin Wen
On Wed, 26 Jun 2024 14:39:57 GMT, Emanuel Peter wrote: >>> I filed: >>> >>> [JDK-8335113](https://bugs.openjdk.org/browse/JDK-8335113): C2 MergeStores: >>> allow merging of putChar and other larger stores on smaller array elements >> >> Great! Should we hold off on this optimization and see if

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 15:08:50 GMT, Chen Liang wrote: >> If you do not use TRUSTED Lookup, errors will occur when processing records. >> >> You can see this build error >> https://github.com/wenshao/jdk/actions/runs/10049344961/job/27775952878 >> >> TEST: java/lang/reflect/records/RecordReflecti

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v39]

2024-07-24 Thread fabioromano1
> I have implemented the Zimmermann's square root algorithm, available in works > [here](https://inria.hal.science/inria-00072854/en/) and > [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). > > The algorithm is proved to be asymptotically faster than the New

RFR: 8336895: BufferedReader doesn't read full \r\n line ending when it doesn't fit in buffer

2024-07-24 Thread Brian Burkhalter
Add some verbiage stating that two buffered readers or input streams should not be used to read from the same reader or input stream, respectively. - Commit messages: - 8336895: BufferedReader doesn't read full \r\n line ending when it doesn't fit in buffer Changes: https://git.op

Re: RFR: 8336856: Optimize String Concat [v5]

2024-07-24 Thread Shaojin Wen
On Tue, 23 Jul 2024 13:35:41 GMT, Claes Redestad wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains six commits: >> >> - Merge remote-tracking branch 'origin/optim_simple_concat_202407' into >> optim_concat_fa

Integrated: 8336741: Optimize LocalTime.toString with StringBuilder.repeat

2024-07-24 Thread Shaojin Wen
On Thu, 18 Jul 2024 11:32:47 GMT, Shaojin Wen wrote: > class LocalTime { > public String toString() { > // ... > if (nanoValue % 1000_000 == 0) { > buf.append(Integer.toString((nanoValue / 1000_000) + > 1000).substring(1)); > } else

Re: RFR: 8336741: Optimize LocalTime.toString with StringBuilder.repeat [v4]

2024-07-24 Thread duke
On Thu, 18 Jul 2024 15:43:05 GMT, Shaojin Wen wrote: >> class LocalTime { >> public String toString() { >> // ... >> if (nanoValue % 1000_000 == 0) { >> buf.append(Integer.toString((nanoValue / 1000_000) + >> 1000).substring(1)); >>

Re: RFR: 8333893: Optimization for StringBuilder append boolean & null [v16]

2024-07-24 Thread Shaojin Wen
> After PR https://github.com/openjdk/jdk/pull/16245, C2 optimizes stores into > primitive arrays by combining values ​​into larger stores. > > This PR rewrites the code of appendNull and append(boolean) methods so that > these two methods can be optimized by C2. Shaojin Wen has updated the pul

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v7]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 16:00:10 GMT, Shaojin Wen wrote: >> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We >> need a JMH Benchmark to evaluate the performance of various batch operations >> and the effect of MergeStore. > > Shaojin Wen has updated the pull request with

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Vladimir Ivanov
On Wed, 24 Jul 2024 16:14:47 GMT, Andrew Haley wrote: >>> I suspect that Klass::search_secondary_supers() won't be inlinined in such >>> case. >> >> That's true, but it's true of every other function in that file. Is it not >> deliberate? > > FYI, somewhat related: AArch64 GCC inlines `lookup_

Re: RFR: 8336741: Optimize LocalTime.toString with StringBuilder.repeat [v4]

2024-07-24 Thread Naoto Sato
On Thu, 18 Jul 2024 15:43:05 GMT, Shaojin Wen wrote: >> class LocalTime { >> public String toString() { >> // ... >> if (nanoValue % 1000_000 == 0) { >> buf.append(Integer.toString((nanoValue / 1000_000) + >> 1000).substring(1)); >>

Integrated: 8336847: Use pattern match switch in NumberFormat classes

2024-07-24 Thread Justin Lu
On Tue, 23 Jul 2024 17:28:02 GMT, Justin Lu wrote: > As discussed in > https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is > code within java.text.NumberFormat (and subclasses) that can use the pattern > match switch to improve readability. > > As this is simply cleanup

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v3]

2024-07-24 Thread Justin Lu
On Wed, 24 Jul 2024 19:45:45 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Integrated: 8336787: Examine java.text.Format API for implSpec usage

2024-07-24 Thread Justin Lu
On Tue, 23 Jul 2024 17:51:04 GMT, Justin Lu wrote: > As discussed in https://bugs.openjdk.org/browse/JDK-8335834, there are > occurrences in the java.text.Format API that would benefit from the implSpec > (and apiNote) tag. > > This is a doc-only change, and a CSR has also been filed. > > I

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v3]

2024-07-24 Thread Chen Liang
On Wed, 24 Jul 2024 19:45:45 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v3]

2024-07-24 Thread Naoto Sato
On Wed, 24 Jul 2024 19:45:45 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v3]

2024-07-24 Thread Justin Lu
> As discussed in > https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is > code within java.text.NumberFormat (and subclasses) that can use the pattern > match switch to improve readability. > > As this is simply cleanup, there is no regression test added. (Tiers 1-3 and

Re: RFR: 8336315: tools/jpackage/windows/WinChildProcessTest.java Failed: Check is calculator process is alive

2024-07-24 Thread Alexander Matveev
On Wed, 24 Jul 2024 12:20:05 GMT, Vanitha B P wrote: > tools/jpackage/windows/WinChildProcessTest.java was failing intermittently, > fixed the issue and changes are tested. Looks good. I will approve once comments from Alexey are resolved. - PR Comment: https://git.openjdk.org/jdk

Re: RFR: 8336754: Remodel TypeAnnotation to "has" instead of "be" an Annotation [v6]

2024-07-24 Thread Chen Liang
On Wed, 24 Jul 2024 19:11:18 GMT, Andrey Turbanov wrote: >> Chen Liang has updated the pull request incrementally with three additional >> commits since the last revision: >> >> - More refinements from alex >> - Artifact -> construct >> - More about Annotation, add equals note > > test/langt

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

2024-07-24 Thread Brian Burkhalter
On Wed, 24 Jul 2024 19:11:42 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. This change passes CI tiers 1-5 jobs on all platforms.

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

2024-07-24 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. - Commit messages: - 8337143: (fc, fs) Move filesystem-related native objects from libnio to libjava Cha

Re: RFR: 8336754: Remodel TypeAnnotation to "has" instead of "be" an Annotation [v6]

2024-07-24 Thread Andrey Turbanov
On Wed, 24 Jul 2024 13:00:47 GMT, Chen Liang wrote: >> `TypeAnnotation` is not an annotation, as it should not be used in places >> like `AnnotationValue.ofAnnotation`. Thus it's remodeled to contain an >> annotation at a given location instead of to be an annotation. >> >> Depends on #20205.

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Vladimir Ivanov
On Wed, 24 Jul 2024 09:03:12 GMT, Andrew Haley wrote: >>> Also also, Klass::is_subtype_of() is used for C1 runtime. >> >> Can you elaborate, please? What I'm seeing in >> `Runtime1::generate_code_for()` for `slow_subtype_check` is a call into >> `MacroAssembler::check_klass_subtype_slow_path()

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v2]

2024-07-24 Thread Andrey Turbanov
On Tue, 23 Jul 2024 20:54:08 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Re: RFR: 8336741: Optimize LocalTime.toString with StringBuilder.repeat [v4]

2024-07-24 Thread Roger Riggs
On Thu, 18 Jul 2024 15:43:05 GMT, Shaojin Wen wrote: >> class LocalTime { >> public String toString() { >> // ... >> if (nanoValue % 1000_000 == 0) { >> buf.append(Integer.toString((nanoValue / 1000_000) + >> 1000).substring(1)); >>

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v38]

2024-07-24 Thread fabioromano1
> I have implemented the Zimmermann's square root algorithm, available in works > [here](https://inria.hal.science/inria-00072854/en/) and > [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). > > The algorithm is proved to be asymptotically faster than the New

Re: want to try out small idea; where is the implementing class for Stream interface?

2024-07-24 Thread Chen Liang
Anil, you are correct. The guide says to set the SDK to your built image, but it will make IDEA use your built image (much like how some user processes hold Microsoft Visual Studio when you try to set the short name) and you will have trouble building. Setting the SDK will also introduce extra

Re: want to try out small idea; where is the implementing class for Stream interface?

2024-07-24 Thread Anil
Thank you! I set up ant and IDEA. If I understood you correctly, SDK should not be set at all (screenshot below). [image: image.png] On Tue, Jul 23, 2024 at 6:41 PM Chen Liang wrote: > Hi Anil, > Ant is not a command-line tool of linux; it's an ancient Java build tool > popular 10 years ago, bef

Integrated: 8336679: Add @implSpec for the default implementations in Process.waitFor()

2024-07-24 Thread Naoto Sato
On Mon, 22 Jul 2024 22:10:07 GMT, Naoto Sato wrote: > This is a simple doc-only change that follows up > [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding > CSR has also been drafted. This pull request has now been integrated. Changeset: 4ea4d7c6 Author:Naoto Sat

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v4]

2024-07-24 Thread Brian Burkhalter
On Wed, 24 Jul 2024 16:41:46 GMT, Naoto Sato wrote: >> This is a simple doc-only change that follows up >> [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding >> CSR has also been drafted. > > Naoto Sato has updated the pull request incrementally with two additional > c

Re: RFR: 8336315: tools/jpackage/windows/WinChildProcessTest.java Failed: Check is calculator process is alive

2024-07-24 Thread Alexey Semenyuk
On Wed, 24 Jul 2024 12:20:05 GMT, Vanitha B P wrote: > tools/jpackage/windows/WinChildProcessTest.java was failing intermittently, > fixed the issue and changes are tested. Changes requested by asemenyuk (Reviewer). @sashamatveev please review test/jdk/tools/jpackage/apps/ChildProcessAppLaunc

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v2]

2024-07-24 Thread Naoto Sato
On Tue, 23 Jul 2024 20:54:08 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v3]

2024-07-24 Thread Naoto Sato
On Tue, 23 Jul 2024 20:58:01 GMT, Naoto Sato wrote: >> This is a simple doc-only change that follows up >> [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding >> CSR has also been drafted. > > Naoto Sato has updated the pull request incrementally with one additional > c

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v4]

2024-07-24 Thread Naoto Sato
> This is a simple doc-only change that follows up > [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding > CSR has also been drafted. Naoto Sato has updated the pull request incrementally with two additional commits since the last revision: - Update src/java.base/share

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Andrew Haley
On Wed, 24 Jul 2024 15:51:26 GMT, Andrew Haley wrote: >>> What happens when users include `klass.hpp`, but not `klass.inline.hpp`? >>> How does it affect generated code? >>> >>> I suspect that `Klass::search_secondary_supers()` won't be inlinined in >>> such case. >> >> That is true. I can't

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v7]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 16:00:10 GMT, Shaojin Wen wrote: >> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We >> need a JMH Benchmark to evaluate the performance of various batch operations >> and the effect of MergeStore. > > Shaojin Wen has updated the pull request with

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v7]

2024-07-24 Thread Shaojin Wen
> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We > need a JMH Benchmark to evaluate the performance of various batch operations > and the effect of MergeStore. Shaojin Wen has updated the pull request with a new target base due to a merge or a rebase. The incrementa

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Andrew Haley
On Wed, 24 Jul 2024 14:29:09 GMT, Andrew Haley wrote: > I suspect that Klass::search_secondary_supers() won't be inlinined in such > case. That's true, but it's true of every other function in that file. Is it not deliberate? - PR Review Comment: https://git.openjdk.org/jdk/pull/

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v3]

2024-07-24 Thread Brian Burkhalter
On Tue, 23 Jul 2024 20:58:01 GMT, Naoto Sato wrote: >> This is a simple doc-only change that follows up >> [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding >> CSR has also been drafted. > > Naoto Sato has updated the pull request incrementally with one additional > c

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Chen Liang
On Wed, 24 Jul 2024 14:56:48 GMT, Shaojin Wen wrote: >> src/java.base/share/classes/java/lang/invoke/StringConcatFactory.java line >> 1119: >> >>> 1117: >>> 1118: private static MethodHandle generate(Lookup lookup, >>> MethodType args, String[] constants) throws Exception { >>> 1119:

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 14:34:01 GMT, Chen Liang wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains 32 commits: >> >> - Merge remote-tracking branch 'upstream/master' into >> optim_concat_factory_202407 >> - typo

Re: RFR: 8322256: Define and document GZIPInputStream concatenated stream semantics [v7]

2024-07-24 Thread Archie Cobbs
> `GZIPInputStream` supports reading data from multiple concatenated GZIP data > streams since [JDK-4691425](https://bugs.openjdk.org/browse/JDK-4691425). In > order to do this, after a GZIP trailer frame is read, it attempts to read a > GZIP header frame and, if successful, proceeds onward to d

Re: RFR: 8336856: Optimize String Concat [v13]

2024-07-24 Thread Shaojin Wen
> The current implementation of StringConcat is to mix the coder and length > into a long. This operation will have some overhead for int/long/boolean > types. We can separate the calculation of the coder from the calculation of > the length, which can improve the performance in the scenario of

Re: RFR: 8336856: Optimize String Concat [v12]

2024-07-24 Thread Shaojin Wen
> The current implementation of StringConcat is to mix the coder and length > into a long. This operation will have some overhead for int/long/boolean > types. We can separate the calculation of the coder from the calculation of > the length, which can improve the performance in the scenario of

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v3]

2024-07-24 Thread Chen Liang
On Tue, 23 Jul 2024 20:58:01 GMT, Naoto Sato wrote: >> This is a simple doc-only change that follows up >> [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding >> CSR has also been drafted. > > Naoto Sato has updated the pull request incrementally with one additional > c

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Chen Liang
On Wed, 24 Jul 2024 11:43:45 GMT, Shaojin Wen wrote: >> The current implementation of StringConcat is to mix the coder and length >> into a long. This operation will have some overhead for int/long/boolean >> types. We can separate the calculation of the coder from the calculation of >> the le

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Andrew Haley
On Tue, 23 Jul 2024 19:00:02 GMT, Vladimir Ivanov wrote: > What happens when users include `klass.hpp`, but not `klass.inline.hpp`? How > does it affect generated code? > > I suspect that `Klass::search_secondary_supers()` won't be inlinined in such > case. That is true. I can't tell from thi

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v6]

2024-07-24 Thread Andrew Haley
> This patch expands the use of a hash table for secondary superclasses > to the interpreter, C1, and runtime. It also adds a C2 implementation > of hashed lookup in cases where the superclass isn't known at compile > time. > > HotSpot shared runtime > -- > > Building hashed s

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 11:43:45 GMT, Shaojin Wen wrote: >> The current implementation of StringConcat is to mix the coder and length >> into a long. This operation will have some overhead for int/long/boolean >> types. We can separate the calculation of the coder from the calculation of >> the le

Re: RFR: 8333265: De-duplicate method references in java.util.stream.FindOps [v3]

2024-07-24 Thread Chen Liang
On Tue, 18 Jun 2024 10:00:46 GMT, Claes Redestad wrote: >> Extracting duplicate method references to static field reduce proxy class >> spinning and loading. In this case 2 less classes loaded when using >> `findAny()` on each type of stream. > > Claes Redestad has updated the pull request incr

Re: RFR: 8336847: Use pattern match switch in NumberFormat classes [v2]

2024-07-24 Thread Chen Liang
On Tue, 23 Jul 2024 20:54:08 GMT, Justin Lu wrote: >> As discussed in >> https://github.com/openjdk/jdk/pull/19513#discussion_r1684957942, there is >> code within java.text.NumberFormat (and subclasses) that can use the pattern >> match switch to improve readability. >> >> As this is simply c

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v6]

2024-07-24 Thread Emanuel Peter
On Wed, 24 Jul 2024 13:33:43 GMT, Chen Liang wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains 14 additional >> commits sinc

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v5]

2024-07-24 Thread Emanuel Peter
On Tue, 18 Jun 2024 01:09:49 GMT, Shaojin Wen wrote: >> Shaojin Wen has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains 13 additional >> commits sin

Re: RFR: 8336754: Remodel TypeAnnotation to "has" instead of "be" an Annotation [v6]

2024-07-24 Thread Adam Sotona
On Wed, 24 Jul 2024 13:00:47 GMT, Chen Liang wrote: >> `TypeAnnotation` is not an annotation, as it should not be used in places >> like `AnnotationValue.ofAnnotation`. Thus it's remodeled to contain an >> annotation at a given location instead of to be an annotation. >> >> Depends on #20205.

Re: RFR: 8334342: Add MergeStore JMH benchmarks [v6]

2024-07-24 Thread Chen Liang
On Thu, 18 Jul 2024 00:52:17 GMT, Shaojin Wen wrote: >> [8318446](https://github.com/openjdk/jdk/pull/16245) brings MergeStore. We >> need a JMH Benchmark to evaluate the performance of various batch operations >> and the effect of MergeStore. > > Shaojin Wen has updated the pull request with

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v35]

2024-07-24 Thread fabioromano1
On Wed, 24 Jul 2024 11:46:03 GMT, Raffaello Giulietti wrote: >> fabioromano1 has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Made normalization consistent with that of the C code in the paper > > The aim is not about having even more ef

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v37]

2024-07-24 Thread fabioromano1
> I have implemented the Zimmermann's square root algorithm, available in works > [here](https://inria.hal.science/inria-00072854/en/) and > [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). > > The algorithm is proved to be asymptotically faster than the New

Re: RFR: 8336754: Remodel TypeAnnotation to "has" instead of "be" an Annotation [v6]

2024-07-24 Thread Chen Liang
> `TypeAnnotation` is not an annotation, as it should not be used in places > like `AnnotationValue.ofAnnotation`. Thus it's remodeled to contain an > annotation at a given location instead of to be an annotation. > > Depends on #20205. Chen Liang has updated the pull request incrementally with

RFR: 8336315: tools/jpackage/windows/WinChildProcessTest.java Failed: Check is calculator process is alive

2024-07-24 Thread Vanitha B P
tools/jpackage/windows/WinChildProcessTest.java was failing intermittently, fixed the issue and changes are tested. - Commit messages: - 8336315: tools/jpackage/windows/WinChildProcessTest.java Failed: Check is calculator process is alive Changes: https://git.openjdk.org/jdk/pull/

Integrated: 8336927: Missing equals and hashCode in java.lang.classfile.Annotation

2024-07-24 Thread Chen Liang
On Tue, 23 Jul 2024 04:44:57 GMT, Chen Liang wrote: > Convert `AnnotationImpl` to a record so it comes with proper `equals` and > `hashCode` implementations. This also fixes the comparison for > annotation-valued annotation element values. This pull request has now been integrated. Changeset:

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v36]

2024-07-24 Thread fabioromano1
> I have implemented the Zimmermann's square root algorithm, available in works > [here](https://inria.hal.science/inria-00072854/en/) and > [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). > > The algorithm is proved to be asymptotically faster than the New

Re: RFR: 8316662: Remove one allocation per conversion in Double.toString(double) and Float.toString(float) [v4]

2024-07-24 Thread Raffaello Giulietti
On Tue, 30 Apr 2024 08:44:32 GMT, Raffaello Giulietti wrote: >> By correctly sizing an intermediate `byte[]` and making use of the internal >> `newStringNoRepl()` method, one allocation per conversion can be avoided >> when the runtime uses compact strings. > > Raffaello Giulietti has updated

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v35]

2024-07-24 Thread Raffaello Giulietti
On Wed, 24 Jul 2024 10:32:08 GMT, fabioromano1 wrote: >> I have implemented the Zimmermann's square root algorithm, available in >> works [here](https://inria.hal.science/inria-00072854/en/) and >> [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). >> >> The

Re: RFR: 8336856: Optimize String Concat [v11]

2024-07-24 Thread Shaojin Wen
> The current implementation of StringConcat is to mix the coder and length > into a long. This operation will have some overhead for int/long/boolean > types. We can separate the calculation of the coder from the calculation of > the length, which can improve the performance in the scenario of

Re: RFR: 8336856: Optimize String Concat [v10]

2024-07-24 Thread Claes Redestad
On Wed, 24 Jul 2024 10:18:03 GMT, Shaojin Wen wrote: >> The current implementation of StringConcat is to mix the coder and length >> into a long. This operation will have some overhead for int/long/boolean >> types. We can separate the calculation of the coder from the calculation of >> the le

Re: RFR: 8336254: Virtual thread implementation + test updates [v2]

2024-07-24 Thread Serguei Spitsyn
On Fri, 19 Jul 2024 16:59:54 GMT, Alan Bateman wrote: >> Bringover some of the changes accumulated in the loom repo to the main line, >> most of these changes are test updates and have been baking in the loom repo >> for several months. The motive is partly to reduce the large set of changes >

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v34]

2024-07-24 Thread fabioromano1
On Wed, 24 Jul 2024 10:07:48 GMT, Raffaello Giulietti wrote: > As I see it, there are some advantages in making the PR code as similar as > possible to the code in the paper: > > * It might result in simpler code (and maybe even faster code). > > * It would make the Java code easier t

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v35]

2024-07-24 Thread fabioromano1
> I have implemented the Zimmermann's square root algorithm, available in works > [here](https://inria.hal.science/inria-00072854/en/) and > [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). > > The algorithm is proved to be asymptotically faster than the New

Re: RFR: 8336741: Optimize LocalTime.toString with StringBuilder.repeat [v4]

2024-07-24 Thread Shaojin Wen
On Thu, 18 Jul 2024 15:43:05 GMT, Shaojin Wen wrote: >> class LocalTime { >> public String toString() { >> // ... >> if (nanoValue % 1000_000 == 0) { >> buf.append(Integer.toString((nanoValue / 1000_000) + >> 1000).substring(1)); >>

Re: RFR: 8336856: Optimize String Concat [v10]

2024-07-24 Thread Shaojin Wen
On Wed, 24 Jul 2024 10:18:03 GMT, Shaojin Wen wrote: >> The current implementation of StringConcat is to mix the coder and length >> into a long. This operation will have some overhead for int/long/boolean >> types. We can separate the calculation of the coder from the calculation of >> the le

Re: RFR: 8336856: Optimize String Concat [v10]

2024-07-24 Thread Shaojin Wen
> The current implementation of StringConcat is to mix the coder and length > into a long. This operation will have some overhead for int/long/boolean > types. We can separate the calculation of the coder from the calculation of > the length, which can improve the performance in the scenario of

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v34]

2024-07-24 Thread Raffaello Giulietti
On Thu, 18 Jul 2024 17:22:50 GMT, fabioromano1 wrote: >> I have implemented the Zimmermann's square root algorithm, available in >> works [here](https://inria.hal.science/inria-00072854/en/) and >> [here](https://www.researchgate.net/publication/220532560_A_proof_of_GMP_square_root). >> >> The

Re: RFR: 8334755: Asymptotically faster implementation of square root algorithm [v34]

2024-07-24 Thread fabioromano1
On Tue, 23 Jul 2024 15:19:30 GMT, Raffaello Giulietti wrote: >> fabioromano1 has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Conditions' order reversed in MBI.ulongSqrt() > > To clarify, the PR's code seems correct, but I wonder if it c

Re: RFR: 8331341: secondary_super_cache does not scale well: C1 and interpreter [v5]

2024-07-24 Thread Andrew Haley
On Tue, 23 Jul 2024 19:14:57 GMT, Vladimir Ivanov wrote: > > Also also, Klass::is_subtype_of() is used for C1 runtime. > > Can you elaborate, please? Sorry, that was rather vague. In C1-compiled code, the Java method `Class::isInstance(Object)`calls `Klass::is_subtype_of()`. In general, I fi

Re: RFR: 8307818: Convert Indify tool to Classfile API [v16]

2024-07-24 Thread Adam Sotona
On Wed, 24 Jul 2024 07:58:31 GMT, ExE Boss wrote: >> This transformation is called only after the `classModel` is transformed: >> - at line 472 and 380 when the `transformToBytes()` method is called is >> after effectively transforming the `classModel` inside the `Logic` class. > > There isn’t

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

2024-07-24 Thread Galder Zamarreño
On Tue, 9 Jul 2024 12:07:37 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 the fo

Re: RFR: 8307818: Convert Indify tool to Classfile API [v16]

2024-07-24 Thread ExE Boss
On Sat, 22 Jun 2024 15:55:28 GMT, Oussama Louati wrote: >> An indify tool in j.l.i tests (also in vmTestBase) convert some source-code >> private static methods with MT_ MH_, and INDY_ prefixes into MethodHandle, >> MethodType, and CallSite constants. >> ### Purpose of Indify >> >> - **Transf

Re: RFR: 8307818: Convert Indify tool to Classfile API [v16]

2024-07-24 Thread ExE Boss
On Tue, 25 Jun 2024 13:54:07 GMT, Oussama Louati wrote: >> And what is the purpose of parsing a model from bytes and transforming it >> back to bytes without a change? > > This transformation is called only after the `classModel` is transformed: > - at line 472 and 380 when the `transformToByt

Re: RFR: 8336679: Add @implSpec for the default implementations in Process.waitFor() [v3]

2024-07-24 Thread ExE Boss
On Tue, 23 Jul 2024 20:58:01 GMT, Naoto Sato wrote: >> This is a simple doc-only change that follows up >> [JDK-8336479](https://bugs.openjdk.org/browse/JDK-8336479). A corresponding >> CSR has also been drafted. > > Naoto Sato has updated the pull request incrementally with one additional > c