Re: RFR: 8306773: Problemlist jdk/incubator/vector/ShortMaxVectorTests.java on x86_32

2023-04-24 Thread Aleksey Shipilev
On Mon, 24 Apr 2023 18:26:24 GMT, Aleksey Shipilev wrote: > There is a product bug, see the parent bug. Problemlisting to get cleaner GHA > runs. > > Additional testing: > - [x] GHA Thanks! I am integrating to get cleaner GHA runs. - PR Comment:

Re: RFR: 8305505: NPE in javazic compiler

2023-04-24 Thread Yoshiki Sato
On Tue, 18 Apr 2023 19:50:59 GMT, Naoto Sato wrote: >> Please review this PR. >> With this minor change, the javazic compiler (Main.java) can produce the >> HTML files that display given time zone data correctly. > > test/jdk/sun/util/calendar/zi/GenDoc.java line 159: > >> 157:

RFR: 8305505: NPE in javazic compiler

2023-04-24 Thread Yoshiki Sato
Please review this PR. With this minor change, the javazic compiler (Main.java) can produce the HTML files that display given time zone data correctly. - Commit messages: - Remove trailing spaces - Fix a mistake in the change - 8305505: NPE in javazic compiler Changes:

Re: RFR: 8305505: NPE in javazic compiler

2023-04-24 Thread Naoto Sato
On Tue, 18 Apr 2023 05:08:35 GMT, Yoshiki Sato wrote: > Please review this PR. > With this minor change, the javazic compiler (Main.java) can produce the HTML > files that display given time zone data correctly. test/jdk/sun/util/calendar/zi/GenDoc.java line 159: > 157: if

Integrated: JDK-8304036: Use CommandLine class from shared module

2023-04-24 Thread Christian Stein
On Mon, 13 Mar 2023 08:16:54 GMT, Christian Stein wrote: > This pull request addresses the open ends left by > [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): > - #11272 > > Changes: > - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` > to `jdk.compiler`

Re: RFR: 8233725: ProcessTools.startProcess() has output issues when using an OutputAnalyzer at the same time

2023-04-24 Thread Leonid Mesnik
On Tue, 25 Apr 2023 03:06:09 GMT, Serguei Spitsyn wrote: >> ProcessTools.startProcess() creates process and read it's output error >> streams. So the any other using of corresponding Process.getInputStream() >> and Process.getErrorStream() doesn't get process streams. >> >> This fix preserve

Re: RFR: JDK-8304036: Use CommandLine class from shared module [v7]

2023-04-24 Thread Christian Stein
> This pull request addresses the open ends left by > [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): > - #11272 > > Changes: > - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` > to `jdk.compiler` and `jdk.javadoc` > - [x] Use shared `CommandLine.java` in

Re: RFR: 8233725: ProcessTools.startProcess() has output issues when using an OutputAnalyzer at the same time

2023-04-24 Thread Serguei Spitsyn
On Fri, 21 Apr 2023 21:43:39 GMT, Leonid Mesnik wrote: > ProcessTools.startProcess() creates process and read it's output error > streams. So the any other using of corresponding Process.getInputStream() and > Process.getErrorStream() doesn't get process streams. > > This fix preserve process

RFR: 8306623: (bf) CharBuffer::allocate throws unexpected exception type with some CharSequences

2023-04-24 Thread Brian Burkhalter
When appending a `CharBuffer`, perform a specific check for buffer overflow before invoking `put()`. - Commit messages: - 8306623: (bf) CharBuffer::allocate throws unexpected exception type with some CharSequences Changes: https://git.openjdk.org/jdk/pull/13632/files Webrev:

Re: RFR: 8306623: (bf) CharBuffer::allocate throws unexpected exception type with some CharSequences

2023-04-24 Thread Brian Burkhalter
On Tue, 25 Apr 2023 01:44:14 GMT, Brian Burkhalter wrote: > When appending a `CharBuffer`, perform a specific check for buffer overflow > before invoking `put()`. I'm not entirely comfortable with where I've put the test in this patch. - PR Comment:

Re: RFR: 8233725: ProcessTools.startProcess() has output issues when using an OutputAnalyzer at the same time

2023-04-24 Thread Leonid Mesnik
On Mon, 24 Apr 2023 20:57:31 GMT, Chris Plummer wrote: >> ProcessTools.startProcess() creates process and read it's output error >> streams. So the any other using of corresponding Process.getInputStream() >> and Process.getErrorStream() doesn't get process streams. >> >> This fix preserve

Re: RFR: 8266571: Sequenced Collections [v12]

2023-04-24 Thread Stuart Marks
On Fri, 24 Mar 2023 22:08:18 GMT, Tagir F. Valeev wrote: >> Stuart Marks has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains 96 commits: >> >> - Merge branch 'master' into JDK-8266571-SequencedCollections >> - Optimizations for

Re: RFR: 8266571: Sequenced Collections [v4]

2023-04-24 Thread Stuart Marks
On Thu, 30 Mar 2023 09:56:58 GMT, Tagir F. Valeev wrote: >> @liach >> >> I understand that you're suggesting adding various default implementations >> in order to make it easier for people to bring up implementations of >> SequencedCollections. However, adding default implementations to >>

Re: RFR: 8266571: Sequenced Collections [v8]

2023-04-24 Thread Stuart Marks
On Sat, 22 Apr 2023 07:56:03 GMT, Nir Lisker wrote: >> Might not work if this map is concurrent. If isEmpty() returns false but >> then the map is emptied before the subsequent calls, next() might throw >> NSEE. The concurrent maps' iterators make sure to cache the element if >> hasNext() has

Re: RFR: 8266571: Sequenced Collections [v12]

2023-04-24 Thread Stuart Marks
On Fri, 24 Mar 2023 22:06:06 GMT, Tagir F. Valeev wrote: >> Stuart Marks has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains 96 commits: >> >> - Merge branch 'master' into JDK-8266571-SequencedCollections >> - Optimizations for

Re: RFR: 8294961: Convert java.base/java.lang.reflect.ProxyGenerator to use the Classfile API to generate proxy classes [v15]

2023-04-24 Thread Chen Liang
On Mon, 27 Mar 2023 16:43:17 GMT, Adam Sotona wrote: >> java.base java.lang.reflect.ProxyGenerator uses ASM to generate proxy >> classes and this patch converts it to use Classfile API. >> >> Please review. >> >> Thank you, >> Adam > > Adam Sotona has updated the pull request incrementally

Re: RFR: 8266571: Sequenced Collections [v10]

2023-04-24 Thread Stuart Marks
On Sat, 22 Apr 2023 09:33:57 GMT, ExE Boss wrote: >> Stuart Marks has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Wording tweaks to SequencedMap / NavigableMap. >> - Change "The implementation in this class" to "... interface." > >

Re: RFR: 8305853: java/text/Format/DateFormat/DateFormatRegression.java fails with "Uncaught exception thrown in test method Test4089106" [v2]

2023-04-24 Thread Justin Lu
> This PR fixes an intermittent failure (that only occurs on Windows) in > _DateFormatRegression.java_. > > With the integration of > [JDK-8304982](https://bugs.openjdk.org/browse/JDK-8304982), > _LocaleProviderAdapter.java_ now emits a compat warning when the class is > loaded. This warning

Re: RFR: 8305853: java/text/Format/DateFormat/DateFormatRegression.java fails with "Uncaught exception thrown in test method Test4089106"

2023-04-24 Thread Naoto Sato
On Mon, 24 Apr 2023 21:02:01 GMT, Justin Lu wrote: > This PR fixes an intermittent failure (that only occurs on Windows) in > _DateFormatRegression.java_. > > With the integration of > [JDK-8304982](https://bugs.openjdk.org/browse/JDK-8304982), > _LocaleProviderAdapter.java_ now emits a

Re: RFR: 8305734: BitSet.get(int, int) always returns the empty BitSet when the Integer.MAX VALUE is set

2023-04-24 Thread Stuart Marks
On Fri, 7 Apr 2023 12:22:03 GMT, Andy-Tatman wrote: > See https://bugs.java.com/bugdatabase/view_bug?bug_id=8305734 The `size()` call is rather odd, as it's mainly about the implementation and is not considered part of the actual value of the BitSet. I note that `equals()` is specified not to

Re: RFR: 8304918: Remove unused decl field from AnnotatedType implementations

2023-04-24 Thread Chen Liang
On Sat, 25 Mar 2023 05:52:44 GMT, Chen Liang wrote: > In `AnnotatedTypeBaseImpl`, a `decl` field is declared, referring to the > declaration that the AnnotatedType is from. However, this field is not used > anywhere except passing to constructors of other implementations; it's not > used in

Re: RFR: 8266571: Sequenced Collections [v12]

2023-04-24 Thread Stuart Marks
> PR for Sequenced Collections implementation. Stuart Marks has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 96 commits: - Merge branch 'master' into JDK-8266571-SequencedCollections - Optimizations for ReverseOrderListView; check

Re: RFR: 8266571: Sequenced Collections [v11]

2023-04-24 Thread Stuart Marks
> PR for Sequenced Collections implementation. Stuart Marks has updated the pull request incrementally with one additional commit since the last revision: Optimizations for ReverseOrderListView; check indexes in reversed domain. - Changes: - all:

RFR: 8305853: java/text/Format/DateFormat/DateFormatRegression.java fails with "Uncaught exception thrown in test method Test4089106"

2023-04-24 Thread Justin Lu
This PR fixes an intermittent failure (that only occurs on Windows) in _DateFormatRegression.java_. With the integration of [JDK-8304982](https://bugs.openjdk.org/browse/JDK-8304982), _LocaleProviderAdapter.java_ now emits a compat warning when the class is loaded. This warning calls

Re: RFR: 8233725: ProcessTools.startProcess() has output issues when using an OutputAnalyzer at the same time

2023-04-24 Thread Chris Plummer
On Fri, 21 Apr 2023 21:43:39 GMT, Leonid Mesnik wrote: > ProcessTools.startProcess() creates process and read it's output error > streams. So the any other using of corresponding Process.getInputStream() and > Process.getErrorStream() doesn't get process streams. > > This fix preserve process

Re: RFR: JDK-8304036: Use CommandLine class from shared module [v6]

2023-04-24 Thread Mandy Chung
On Mon, 24 Apr 2023 15:31:53 GMT, Christian Stein wrote: >> This pull request addresses the open ends left by >> [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): >> - #11272 >> >> Changes: >> - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` >> to

Re: RFR: 8306678: Replace use of os.version with an internal Version record [v2]

2023-04-24 Thread ExE Boss
On Mon, 24 Apr 2023 19:43:15 GMT, Roger Riggs wrote: >> src/java.base/macosx/classes/jdk/internal/loader/ClassLoaderHelper.java line >> 39: >> >>> 37: // SDK 10.15 and earlier always reports 10.16 instead of 11.x.x >>> 38: hasDynamicLoaderCache = OperatingSystem.version() >>>

Re: RFR: 8306678: Replace use of os.version with an internal Version record [v2]

2023-04-24 Thread ExE Boss
On Mon, 24 Apr 2023 19:56:19 GMT, Roger Riggs wrote: >> Create an internal Version record to hold and compare versions of the form >> (major, minor, micro). >> Add `OperatingSystem.version()` to return the version of the running OS. >> Replace uses of os.version in java.base. >> Subsequent PRs

Re: RFR: 8306773: Problemlist jdk/incubator/vector/ShortMaxVectorTests.java on x86_32

2023-04-24 Thread Vladimir Kozlov
On Mon, 24 Apr 2023 18:26:24 GMT, Aleksey Shipilev wrote: > There is a product bug, see the parent bug. Problemlisting to get cleaner GHA > runs. > > Additional testing: > - [ ] GHA Good. - Marked as reviewed by kvn (Reviewer). PR Review:

Re: RFR: 8306678: Replace use of os.version with an internal Version record [v2]

2023-04-24 Thread Roger Riggs
> Create an internal Version record to hold and compare versions of the form > (major, minor, micro). > Add `OperatingSystem.version()` to return the version of the running OS. > Replace uses of os.version in java.base. > Subsequent PRs will apply to uses in other modules including, jdk.jlink, >

Re: RFR: 8306678: Replace use of os.version with an internal Version record

2023-04-24 Thread Roger Riggs
On Sat, 22 Apr 2023 09:21:09 GMT, ExE Boss wrote: >> Create an internal Version record to hold and compare versions of the form >> (major, minor, micro). >> Add `OperatingSystem.version()` to return the version of the running OS. >> Replace uses of os.version in java.base. >> Subsequent PRs

Re: RFR: 8306678: Replace use of os.version with an internal Version record

2023-04-24 Thread Roger Riggs
On Fri, 21 Apr 2023 17:02:23 GMT, Alan Bateman wrote: >> Create an internal Version record to hold and compare versions of the form >> (major, minor, micro). >> Add `OperatingSystem.version()` to return the version of the running OS. >> Replace uses of os.version in java.base. >> Subsequent PRs

Integrated: 8306780: ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp

2023-04-24 Thread Daniel D . Daugherty
On Mon, 24 Apr 2023 19:28:41 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in > Xcomp. This pull request has now been integrated. Changeset: 328e512d Author:Daniel D. Daugherty URL:

Re: Integrated: 8306780: ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp

2023-04-24 Thread Daniel D . Daugherty
On Mon, 24 Apr 2023 19:34:01 GMT, Joe Darcy wrote: >> A trivial fix to ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in >> Xcomp. > > Marked as reviewed by darcy (Reviewer). @jddarcy - Thanks for the fast review! - PR Comment:

Re: Integrated: 8306780: ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp

2023-04-24 Thread Joe Darcy
On Mon, 24 Apr 2023 19:28:41 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in > Xcomp. Marked as reviewed by darcy (Reviewer). - PR Review: https://git.openjdk.org/jdk/pull/13627#pullrequestreview-1398673003

Integrated: 8306780: ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp

2023-04-24 Thread Daniel D . Daugherty
A trivial fix to ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp. - Commit messages: - 8306780: ProblemList java/lang/Thread/virtual/HoldsLock.java#id0 in Xcomp Changes: https://git.openjdk.org/jdk/pull/13627/files Webrev:

RFR: 8306773: Problemlist jdk/incubator/vector/ShortMaxVectorTests.java on x86_32

2023-04-24 Thread Aleksey Shipilev
There is a product bug, see the parent bug. Problemlisting to get cleaner GHA runs. Additional testing: - [ ] GHA - Commit messages: - Fix Changes: https://git.openjdk.org/jdk/pull/13623/files Webrev: https://webrevs.openjdk.org/?repo=jdk=13623=00 Issue:

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v6]

2023-04-24 Thread Vicente Romero
On Mon, 24 Apr 2023 15:16:18 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v6]

2023-04-24 Thread Vicente Romero
On Mon, 24 Apr 2023 15:16:18 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v6]

2023-04-24 Thread Vicente Romero
On Mon, 24 Apr 2023 15:16:18 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

Re: RFR: JDK-8304423: Refactor FdLibm.java

2023-04-24 Thread Joe Darcy
On Mon, 24 Apr 2023 12:00:58 GMT, Raffaello Giulietti wrote: >> Minor refactoring of FdLibm.java; will consider future refactorings with >> more substantive code changes in the future. > > src/java.base/share/classes/java/lang/FdLibm.java line 76: > >> 74: private static final int

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread ExE Boss
On Mon, 24 Apr 2023 16:26:02 GMT, Adam Sotona wrote: >> Constants API already provides models for all loadable constants to help >> programs manipulating class files and modelling bytecode instructions. >> However no models of module and package constants are provided by Constants >> API.

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread Chen Liang
On Mon, 24 Apr 2023 16:27:28 GMT, ExE Boss wrote: > Note that other `*Impl` classes in `java.lang.constant` perform validation in  > their constructors and provide custom `toString()` formatting and they also > don’t use records. Records were only added in Java 16; the constant API was added

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread Adam Sotona
> Constants API already provides models for all loadable constants to help > programs manipulating class files and modelling bytecode instructions. > However no models of module and package constants are provided by Constants > API. Every program manipulating class files must implement own

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v2]

2023-04-24 Thread Adam Sotona
On Mon, 24 Apr 2023 14:35:30 GMT, Roger Riggs wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> added links to JVMS and utility methods moved to ConstantUtils > >

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v6]

2023-04-24 Thread Vicente Romero
On Mon, 24 Apr 2023 15:16:18 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions [v2]

2023-04-24 Thread Aleksey Shipilev
On Mon, 24 Apr 2023 14:41:58 GMT, Volker Simonis wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions [v2]

2023-04-24 Thread Aleksey Shipilev
On Mon, 24 Apr 2023 14:41:58 GMT, Volker Simonis wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v2]

2023-04-24 Thread Adam Sotona
On Mon, 24 Apr 2023 14:30:46 GMT, Roger Riggs wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> added links to JVMS and utility methods moved to ConstantUtils > >

Integrated: 8304896: Update to use jtreg 7.2

2023-04-24 Thread Christian Stein
On Mon, 17 Apr 2023 14:56:16 GMT, Christian Stein wrote: > Please review the change to update to using jtreg 7.2. > > The primary change is to the `jib-profiles.js` file, which specifies the > version of jtreg to use, for those systems that rely on this file. In > addition, the

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Vicente Romero
On Mon, 24 Apr 2023 13:08:44 GMT, Jan Lahoda wrote: >> src/java.base/share/classes/java/lang/runtime/SwitchBootstraps.java line 315: >> >>> 313: Object[] labels = resolvedLabels.resolvedLabels; >>> 314: >>> 315: // Dumbest possible strategy >> >> I guess that given that we

Re: RFR: JDK-8304036: Use CommandLine class from shared module [v5]

2023-04-24 Thread Christian Stein
On Sat, 22 Apr 2023 12:15:38 GMT, Christian Stein wrote: >> This pull request addresses the open ends left by >> [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): >> - #11272 >> >> Changes: >> - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` >> to

Integrated: 8304836: Make MALLOC_MIN4 macro more robust

2023-04-24 Thread Naoto Sato
On Thu, 20 Apr 2023 18:39:29 GMT, Naoto Sato wrote: > The current macro assumes the argument is `jint` because all locations pass > `jint`. However, this would not work if a wider type such as `jlong` is > passed. Removing the `unsigned` cast and make the condition explicit would > make the

Re: RFR: JDK-8304036: Use CommandLine class from shared module [v5]

2023-04-24 Thread Mandy Chung
On Sat, 22 Apr 2023 12:15:38 GMT, Christian Stein wrote: >> This pull request addresses the open ends left by >> [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): >> - #11272 >> >> Changes: >> - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` >> to

Re: RFR: JDK-8304036: Use CommandLine class from shared module [v6]

2023-04-24 Thread Christian Stein
> This pull request addresses the open ends left by > [JDK-8236919](https://bugs.openjdk.org/browse/JDK-8236919): > - #11272 > > Changes: > - [x] Extend list of targeted exports of `jdk.internal.opt/jdk.internal.opt` > to `jdk.compiler` and `jdk.javadoc` > - [x] Use shared `CommandLine.java` in

Re: RFR: 8306008: Several Vector API tests fail for client VM after JDK-8304450

2023-04-24 Thread Quan Anh Mai
On Tue, 18 Apr 2023 12:21:11 GMT, Quan Anh Mai wrote: > Hi, > > Please review this patch which fixes the errors on machines where > TypeMaxVector has a length of 64 bits. I take an extra cautious approach and > fall back to putting elements one by one if the length is an unexpected value. >

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v6]

2023-04-24 Thread Jan Lahoda
> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: > > - the pattern matching for switch and record patterns features are made > final, together with updates to tests. > - parenthesized patterns are removed. > - qualified enum constants are supported for case

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v2]

2023-04-24 Thread Roger Riggs
On Mon, 24 Apr 2023 13:18:09 GMT, Adam Sotona wrote: >> Constants API already provides models for all loadable constants to help >> programs manipulating class files and modelling bytecode instructions. >> However no models of module and package constants are provided by Constants >> API.

Re: RFR: 8305093: Linker cache should not take layout names into account [v2]

2023-04-24 Thread Maurizio Cimadamore
On Fri, 21 Apr 2023 01:03:57 GMT, Jorn Vernee wrote: >> Strip names from the function descriptors used in linkage requests. The >> names are not important for classification, and this will allow the cached >> MethodHandle/UpcallStubFactory to be shared across linkage request with the >> same

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions [v2]

2023-04-24 Thread Volker Simonis
> This issue was reported by: Yakov Shafranovich > ([yako...@amazon.com](mailto:yako...@amazon.com)) > > Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a > negative array length in the deserialization stream. Instead it calls > `j.l.r.Array::newInstance(..)` with

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Wed, 19 Apr 2023 16:47:33 GMT, Volker Simonis wrote: > This issue was reported by: Yakov Shafranovich > ([yako...@amazon.com](mailto:yako...@amazon.com)) > > Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a > negative array length in the deserialization stream.

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Jan Lahoda
On Fri, 21 Apr 2023 16:49:54 GMT, Vicente Romero wrote: >> Jan Lahoda has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Adding test. >> - Removing redundant continue, as noted on the review. > >

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Maurizio Cimadamore
On Mon, 24 Apr 2023 12:53:59 GMT, Jan Lahoda wrote: > In this case, as long as the union type could only be present at the top > level (as opposed to e.g. a type of a record component), we could simply > require all components to be covered for union types for exhaustiveness in >

Withdrawn: 8304986: Upcall stubs should support capureCallState

2023-04-24 Thread Jorn Vernee
On Fri, 21 Apr 2023 18:25:32 GMT, Jorn Vernee wrote: > Implement captureCallState support for upcall stubs. > > The method handle of an upcall stub linked with this linker option has an > additional leading memory segment parameter into which the capture state > (e.g. errno) should be

Re: RFR: 8304986: Upcall stubs should support capureCallState

2023-04-24 Thread Jorn Vernee
On Fri, 21 Apr 2023 18:25:32 GMT, Jorn Vernee wrote: > Implement captureCallState support for upcall stubs. > > The method handle of an upcall stub linked with this linker option has an > additional leading memory segment parameter into which the capture state > (e.g. errno) should be

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v2]

2023-04-24 Thread Adam Sotona
On Mon, 24 Apr 2023 12:28:37 GMT, Chen Liang wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> added links to JVMS and utility methods moved to ConstantUtils > >

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v2]

2023-04-24 Thread Adam Sotona
> Constants API already provides models for all loadable constants to help > programs manipulating class files and modelling bytecode instructions. > However no models of module and package constants are provided by Constants > API. Every program manipulating class files must implement own

Re: RFR: 8305093: Linker cache should not take layout names into account [v2]

2023-04-24 Thread Jorn Vernee
On Mon, 24 Apr 2023 11:46:57 GMT, Maurizio Cimadamore wrote: >> Jorn Vernee has updated the pull request incrementally with one additional >> commit since the last revision: >> >> use al instead of ValueLayout.ADDRESS > >

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Jan Lahoda
On Mon, 24 Apr 2023 12:05:35 GMT, Maurizio Cimadamore wrote: > > > I believe the exhaustiveness algorithm needs rules for union types, both > > > in javac and in the JLS: > > > ... > > > I would expect the above switch to be exhaustive, since it covers all > > > possible components of the

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API

2023-04-24 Thread Chen Liang
On Mon, 24 Apr 2023 11:59:03 GMT, Adam Sotona wrote: > Constants API already provides models for all loadable constants to help > programs manipulating class files and modelling bytecode instructions. > However no models of module and package constants are provided by Constants > API. Every

Re: RFR: 8305486: Add split() variants that keep the delimiters to String and j.u.r.Pattern [v5]

2023-04-24 Thread Raffaello Giulietti
> Add `split()` overloads to `String` and `java.util.regex.Pattern` that, in > addition to the substrings returned by current `split()` variants, also > return the delimiters matching the regular expression. Raffaello Giulietti has updated the pull request incrementally with one additional

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 11:58:50 GMT, Aleksey Shipilev wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 11:42:51 GMT, Aleksey Shipilev wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: JDK-8304423: Refactor FdLibm.java

2023-04-24 Thread Raffaello Giulietti
On Sun, 23 Apr 2023 22:34:43 GMT, Joe Darcy wrote: > Minor refactoring of FdLibm.java; will consider future refactorings with more > substantive code changes in the future. src/java.base/share/classes/java/lang/FdLibm.java line 76: > 74: private static final int SIGN_BIT=

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Maurizio Cimadamore
On Mon, 24 Apr 2023 09:05:56 GMT, Rémi Forax wrote: > > I believe the exhaustiveness algorithm needs rules for union types, both in > > javac and in the JLS: > > ... > > I would expect the above switch to be exhaustive, since it covers all > > possible components of the union type. In other

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 11:41:24 GMT, Aleksey Shipilev wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

RFR: 8306729: Add nominal descriptors of modules and packages to Constants API

2023-04-24 Thread Adam Sotona
Constants API already provides models for all loadable constants to help programs manipulating class files and modelling bytecode instructions. However no models of module and package constants are provided by Constants API. Every program manipulating class files must implement own models and

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 18:53:53 GMT, Roger Riggs wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 18:44:54 GMT, Roger Riggs wrote: >> src/java.base/share/classes/java/io/ObjectInputStream.java line 2142: >> >>> 2140: int len = bin.readInt(); >>> 2141: if (len < 0) { >>> 2142: throw new InvalidClassException(desc.getName(), "Array >>> length <

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Thu, 20 Apr 2023 10:57:30 GMT, Aleksey Shipilev wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8305201: Improve error message for GroupLayouts that are too large on SysV

2023-04-24 Thread Maurizio Cimadamore
On Fri, 21 Apr 2023 14:25:26 GMT, Jorn Vernee wrote: > Using for instance a struct layout that contains an unbounded array will > produce the exception from the JBS issue. > > This patch checks for the case where a GroupLayout is too large more > explicitly, and reports the issue using a more

Re: RFR: 8305093: Linker cache should not take layout names into account [v2]

2023-04-24 Thread Maurizio Cimadamore
On Fri, 21 Apr 2023 01:03:57 GMT, Jorn Vernee wrote: >> Strip names from the function descriptors used in linkage requests. The >> names are not important for classification, and this will allow the cached >> MethodHandle/UpcallStubFactory to be shared across linkage request with the >> same

Re: RFR: 8306461: ObjectInputStream::readObject() should handle negative array sizes without throwing NegativeArraySizeExceptions

2023-04-24 Thread Volker Simonis
On Wed, 19 Apr 2023 19:05:49 GMT, Andrey Turbanov wrote: >> This issue was reported by: Yakov Shafranovich >> ([yako...@amazon.com](mailto:yako...@amazon.com)) >> >> Currently, `ObjectInputStream::readObject()` doesn't explicitly checks for a >> negative array length in the deserialization

Re: RFR: 8304915: Create jdk.internal.util.Architecture enum and apply [v17]

2023-04-24 Thread Martin Doerr
On Fri, 21 Apr 2023 20:26:12 GMT, Roger Riggs wrote: >> Define an internal jdk.internal.util.Architecture enumeration and static >> methods to replace uses of the system property `os.arch`. >> The enumeration values are defined to match those used in the build. >> The initial values are: `X64,

Re: RFR: 8305734: BitSet.get(int, int) always returns the empty BitSet when the Integer.MAX VALUE is set

2023-04-24 Thread Andy-Tatman
On Fri, 7 Apr 2023 12:22:03 GMT, Andy-Tatman wrote: > See https://bugs.java.com/bugdatabase/view_bug?bug_id=8305734 I realise this is a bit off-topic for this specific bug, but perhaps relevant for the specification: The size() function can already start to overflow with much smaller indices

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Rémi Forax
On Fri, 21 Apr 2023 16:25:04 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

Re: RFR: 8300543 Compiler Implementation for Pattern Matching for switch [v5]

2023-04-24 Thread Maurizio Cimadamore
On Fri, 21 Apr 2023 16:25:04 GMT, Jan Lahoda wrote: >> This is the first draft of a patch for JEP 440 and JEP 441. Changes included: >> >> - the pattern matching for switch and record patterns features are made >> final, together with updates to tests. >> - parenthesized patterns are

RFR: 8304888: Add dedicated VMProps for linker and fallback linker

2023-04-24 Thread Jorn Vernee
This patch adds a dedicated jtreg property to check which CABI is being used by the JDK, which can be used both to check whether the foreign linker is supported, and whether the fallback linker is being used. (and, possibly it can also be use to check for a particular ABI in case we want to add

Re: RFR: 8306431: File.listRoots method description should be re-examined [v4]

2023-04-24 Thread Nagata-Haruhito
> I fixed File.listRoots description. > * remove "the insertion or ejection of removable media" > * change "available" to "existing" > > Please review this change. Nagata-Haruhito has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the

Re: RFR: 8302204: Optimize BigDecimal.divide [v2]

2023-04-24 Thread Xiaowei Lu
On Fri, 17 Feb 2023 04:43:00 GMT, Xiaowei Lu wrote: >> [JDK-8269667](https://bugs.openjdk.org/browse/JDK-8269667) has uncovered the >> poor performance of BigDecimal.divide under certain circumstance. >> >> We confront similar situations when benchmarking Spark3 on TPC-DS test kit. >>

Re: RFR: 8304986: Upcall stubs should support capureCallState

2023-04-24 Thread ExE Boss
On Fri, 21 Apr 2023 18:25:32 GMT, Jorn Vernee wrote: > Implement captureCallState support for upcall stubs. > > The method handle of an upcall stub linked with this linker option has an > additional leading memory segment parameter into which the capture state > (e.g. errno) should be

Re: RFR: 8304986: Upcall stubs should support capureCallState

2023-04-24 Thread Jorn Vernee
On Fri, 21 Apr 2023 18:25:32 GMT, Jorn Vernee wrote: > Implement captureCallState support for upcall stubs. > > The method handle of an upcall stub linked with this linker option has an > additional leading memory segment parameter into which the capture state > (e.g. errno) should be

RFR: 8304986: Upcall stubs should support capureCallState

2023-04-24 Thread Jorn Vernee
Implement captureCallState support for upcall stubs. The method handle of an upcall stub linked with this linker option has an additional leading memory segment parameter into which the capture state (e.g. errno) should be written. After returning from Java, this value is then actually written

RFR: 8305201: Improve error message for GroupLayouts that are too large on SysV

2023-04-24 Thread Jorn Vernee
Using for instance a struct layout that contains an unbounded array will produce the exception from the JBS issue. This patch checks for the case where a GroupLayout is too large more explicitly, and reports the issue using a more informative exception. - Depends on:

Re: RFR: 8306008: Several Vector API tests fail for client VM after JDK-8304450

2023-04-24 Thread Gui Cao
On Tue, 18 Apr 2023 12:21:11 GMT, Quan Anh Mai wrote: > Hi, > > Please review this patch which fixes the errors on machines where > TypeMaxVector has a length of 64 bits. I take an extra cautious approach and > fall back to putting elements one by one if the length is an unexpected value. >