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

2023-04-25 Thread Per Minborg
On Tue, 25 Apr 2023 19:43:29 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. Ever

RFR: 8180892: Correct handling of annotations on parameters

2023-04-25 Thread Chen Liang
This patch aims to correct handling of annotations on parameters with the help of `MethodParameters` attribute, which will be always available once #9862 is integrated. It utilizes and expands upon the existing parameter matching logic present in `Executable::getAllGenericParameterTypes`, and d

Re: RFR: 8299748: java/util/zip/Deinflate.java failing on s390x [v2]

2023-04-25 Thread Amit Kumar
On Tue, 7 Mar 2023 05:57:34 GMT, Jaikiran Pai wrote: >>> Finally, are you or someone in your team, in contact with the author(s) of >>> the custom zlib implementation >>> [iii-i/zlib@1132034](https://github.com/iii-i/zlib/commit/113203437eda67261848b14b6c80a33ff7e33d34)? >>> Would you be able

Re: RFR: 8305505: NPE in javazic compiler [v2]

2023-04-25 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. Yoshiki Sato has updated the pull request incrementally with one additional commit since the last revision: Insert null check for map

Re: RFR: 8304425: ClassHierarchyResolver from Reflection [v6]

2023-04-25 Thread Chen Liang
On Mon, 20 Mar 2023 15:21:57 GMT, Adam Sotona wrote: >> Marked as reviewed by asotona (Committer). > >> @asotona So should I simply throw an `IllegalAccessError` when the Lookup >> encounters a `IllegalAccessException`, or should I return null? I favor >> throwing an `IllegalAccessError` as the

Re: RFR: 8205592: BigDecimal.doubleValue() is depressingly slow

2023-04-25 Thread Joe Darcy
On Thu, 7 Jul 2022 15:20:32 GMT, Raffaello Giulietti wrote: > A reimplementation of `BigDecimal.[double|float]Value()` to enhance > performance, avoiding an intermediate string and its subsequent parsing on > the slow path. Marked as reviewed by darcy (Reviewer). - PR Review: ht

Re: RFR: 8205592: BigDecimal.doubleValue() is depressingly slow

2023-04-25 Thread Joe Darcy
On Thu, 7 Jul 2022 15:20:32 GMT, Raffaello Giulietti wrote: > A reimplementation of `BigDecimal.[double|float]Value()` to enhance > performance, avoiding an intermediate string and its subsequent parsing on > the slow path. src/java.base/share/classes/java/math/BigDecimal.java line 308: > 30

Re: RFR: 8306711: Improve diagnosis of `IntlTest` framework [v3]

2023-04-25 Thread Justin Lu
On Tue, 25 Apr 2023 23:58:59 GMT, Justin Lu wrote: >> Please review changes to the IntlTest (test framework) class. >> >> These changes include >> - Logging the actual exception + stack trace. Previously, the test framework >> would throw `InvocationTargetException` but hide the actual underly

Re: RFR: 8306711: Improve diagnosis of `IntlTest` framework [v3]

2023-04-25 Thread Justin Lu
> Please review changes to the IntlTest (test framework) class. > > These changes include > - Logging the actual exception + stack trace. Previously, the test framework > would throw `InvocationTargetException` but hide the actual underlying > exception of the failing test unless the test class

Re: RFR: 8306697: Add method to obtain String for CONSTANT_Class_info in ClassDesc [v2]

2023-04-25 Thread Mandy Chung
On Sat, 22 Apr 2023 18:40:45 GMT, Chen Liang wrote: >> Add a method `internalName` to `ClassDesc`, and unifies handling of string >> representation of a class constant in CONSTANT_Class_info via >> `ofInternalName` and `internalName` APIs, documented in `ClassDesc` itself. >> In particular, `o

RFR: 8302182: Update Public Suffix List to 88467c9

2023-04-25 Thread Weijun Wang
Update PSL for JDK 21. - Commit messages: - the upgrade Changes: https://git.openjdk.org/jdk/pull/13662/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13662&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8302182 Stats: 1479 lines in 5 files changed: 647 ins; 697 de

Re: RFR: 8306697: Add method to obtain String for CONSTANT_Class_info in ClassDesc [v2]

2023-04-25 Thread Chen Liang
On Sat, 22 Apr 2023 18:40:45 GMT, Chen Liang wrote: >> Add a method `internalName` to `ClassDesc`, and unifies handling of string >> representation of a class constant in CONSTANT_Class_info via >> `ofInternalName` and `internalName` APIs, documented in `ClassDesc` itself. >> In particular, `o

Integrated: 8304918: Remove unused decl field from AnnotatedType implementations

2023-04-25 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 de

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

2023-04-25 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 de

Re: RFR: 8306711: Improve diagnosis of `IntlTest` framework [v2]

2023-04-25 Thread Naoto Sato
On Tue, 25 Apr 2023 22:08:09 GMT, Justin Lu wrote: >> Please review changes to the IntlTest (test framework) class. >> >> These changes include >> - Logging the actual exception + stack trace. Previously, the test framework >> would throw `InvocationTargetException` but hide the actual underly

Re: RFR: 8304265: Implementation of Foreign Function and Memory API (Third Preview) [v24]

2023-04-25 Thread Paul Sandoz
On Wed, 19 Apr 2023 13:37:15 GMT, Per Minborg wrote: >> API changes for the FFM API (third preview) >> >> ### Specdiff >> https://cr.openjdk.org/~pminborg/panama/21/v2/specdiff/overview-summary.html >> >> ### Javadoc >> https://cr.openjdk.org/~pminborg/panama/21/v2/javadoc/api/java.base/java/la

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

2023-04-25 Thread Joe Darcy
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 de

Re: RFR: 8304265: Implementation of Foreign Function and Memory API (Third Preview) [v24]

2023-04-25 Thread Paul Sandoz
On Wed, 19 Apr 2023 13:37:15 GMT, Per Minborg wrote: >> API changes for the FFM API (third preview) >> >> ### Specdiff >> https://cr.openjdk.org/~pminborg/panama/21/v2/specdiff/overview-summary.html >> >> ### Javadoc >> https://cr.openjdk.org/~pminborg/panama/21/v2/javadoc/api/java.base/java/la

Re: RFR: 8306711: Improve diagnosis of `IntlTest` framework [v2]

2023-04-25 Thread Justin Lu
> Please review changes to the IntlTest (test framework) class. > > These changes include > - Logging the actual exception + stack trace. Previously, the test framework > would throw `InvocationTargetException` but hide the actual underlying > exception of the failing test unless the test class

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

2023-04-25 Thread Mandy Chung
On Tue, 25 Apr 2023 19:43:29 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. Ever

RFR: 8298993: (process) java/lang/ProcessBuilder/UnblockSignals.java fails

2023-04-25 Thread Roger Riggs
It appears that -Xcomp causes the relative timing of the commands to be disturbed enough to prevent the correct operation of the test. The test should not be run with -Xcomp - Commit messages: - 8298993: (process) java/lang/ProcessBuilder/UnblockSignals.java fails Changes: https:/

Re: RFR: 8304265: Implementation of Foreign Function and Memory API (Third Preview) [v24]

2023-04-25 Thread Paul Sandoz
On Wed, 19 Apr 2023 13:37:15 GMT, Per Minborg wrote: >> API changes for the FFM API (third preview) >> >> ### Specdiff >> https://cr.openjdk.org/~pminborg/panama/21/v2/specdiff/overview-summary.html >> >> ### Javadoc >> https://cr.openjdk.org/~pminborg/panama/21/v2/javadoc/api/java.base/java/la

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

2023-04-25 Thread Roger Riggs
On Mon, 24 Apr 2023 15:58:41 GMT, Aleksey Shipilev wrote: >> Volker Simonis has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Addresed review comments of @turbanoff, @shipilev and @RogerRiggs > > test/jdk/java/io/ObjectInputStream/Negative

RFR: 8306711: Improve diagnosis of `IntlTest` framework

2023-04-25 Thread Justin Lu
Please review changes to the IntlTest (test framework) class. These changes include - Logging the actual exception + stack trace. Previously, the test framework would throw `InvocationTargetException` but hide the actual underlying exception of the failing test unless the test class was ran wit

Integrated: 8306031: Update IANA Language Subtag Registry to Version 2023-04-13

2023-04-25 Thread Justin Lu
On Mon, 17 Apr 2023 19:48:10 GMT, Justin Lu wrote: > Update the registry and accompanying tests with the **IANA 4/13/2022** update. > > This update introduces the case where an IANA entry can have a preferred > value, but that preferred value has a preferred value as well. > > This causes unex

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

2023-04-25 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()`. This pull request has now been integrated. Changeset: e3ccaa65 Author:Brian Burkhalter URL: https://git.openjdk.org/jdk

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

2023-04-25 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 model

Integrated: JDK-8304423: Refactor FdLibm.java

2023-04-25 Thread Joe Darcy
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. This pull request has now been integrated. Changeset: d819deba Author:Joe Darcy URL: https://git.openjdk.org/

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

2023-04-25 Thread Adam Sotona
On Tue, 25 Apr 2023 16:26:01 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> added custom toString() methods > > src/java.base/share/classes/java/lang/constant/PackageDesc.java line 44: > >> 42:

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

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 22:05:18 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/ModuleDesc.java line 43: > >>

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

2023-04-25 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 model

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

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 20:56:03 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/PackageDesc.java line 30: > >>

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

2023-04-25 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 model

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

2023-04-25 Thread Lance Andersen
On Tue, 25 Apr 2023 19:04:10 GMT, Brian Burkhalter wrote: >> When appending a `CharBuffer`, perform a specific check for buffer overflow >> before invoking `put()`. > > Brian Burkhalter has updated the pull request incrementally with one > additional commit since the last revision: > > 83066

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

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 21:59:29 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/ModuleDesc.java line 30: > >>

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

2023-04-25 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 model

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

2023-04-25 Thread Brian Burkhalter
> When appending a `CharBuffer`, perform a specific check for buffer overflow > before invoking `put()`. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8306623: Add overlooked issue ID to @bug - Changes: - all: h

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

2023-04-25 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 model

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

2023-04-25 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 model

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

2023-04-25 Thread Alan Bateman
On Tue, 25 Apr 2023 16:50:10 GMT, Brian Burkhalter wrote: >> When appending a `CharBuffer`, perform a specific check for buffer overflow >> before invoking `put()`. > > Brian Burkhalter has updated the pull request incrementally with one > additional commit since the last revision: > > 83066

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

2023-04-25 Thread Brian Burkhalter
On Tue, 25 Apr 2023 06:25:10 GMT, Alan Bateman wrote: > [...] I think this regression was missed because this tests didn't check this > case. It definitely was. - PR Comment: https://git.openjdk.org/jdk/pull/13632#issuecomment-1522142226

Re: RFR: 8305505: NPE in javazic compiler

2023-04-25 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. I revisited the code, and now think that `mapList` better be `null`, as it indic

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

2023-04-25 Thread Mandy Chung
On Tue, 25 Apr 2023 14:17:22 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 w

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

2023-04-25 Thread Lance Andersen
On Mon, 24 Apr 2023 23:47:05 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: 8306729: Add nominal descriptors of modules and packages to Constants API [v4]

2023-04-25 Thread Mandy Chung
On Tue, 25 Apr 2023 08:11:24 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. Ever

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

2023-04-25 Thread Mandy Chung
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. Ever

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

2023-04-25 Thread Brian Burkhalter
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. LGTM2 - Marked as reviewed by bpb (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/13604#pullrequest

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

2023-04-25 Thread Brian Burkhalter
> When appending a `CharBuffer`, perform a specific check for buffer overflow > before invoking `put()`. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8306623: Update comment; move test code location - Changes:

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

2023-04-25 Thread Brian Burkhalter
On Tue, 25 Apr 2023 06:27:12 GMT, Alan Bateman wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8306623: Update comment; move test code location > > src/java.base/share/classes/java/nio/X-Buffer.java.template li

Re: RFR: 8266571: Sequenced Collections [v12]

2023-04-25 Thread Chen Liang
On Mon, 24 Apr 2023 21:39:43 GMT, Stuart Marks wrote: >> 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-Sequen

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

2023-04-25 Thread Naoto Sato
On Mon, 24 Apr 2023 23:47:05 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

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

2023-04-25 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: 8233725: ProcessTools.startProcess() has output issues when using an OutputAnalyzer at the same time

2023-04-25 Thread Daniel D . Daugherty
On Tue, 25 Apr 2023 04:05:05 GMT, Leonid Mesnik wrote: >> test/lib/jdk/test/lib/process/ProcessTools.java line 792: >> >>> 790: @Override >>> 791: public InputStream getInputStream() { >>> 792: return out; >> >> This is a little bit confusing that the `getInputStream

Integrated: 8266571: Sequenced Collections

2023-04-25 Thread Stuart Marks
On Tue, 8 Feb 2022 17:23:38 GMT, Stuart Marks wrote: > PR for Sequenced Collections implementation. This pull request has now been integrated. Changeset: 17ce0976 Author:Stuart Marks URL: https://git.openjdk.org/jdk/commit/17ce0976e442d5fabb14daed40fa9a768989f02e Stats: 7067 lin

Re: RFR: 8266571: Sequenced Collections [v12]

2023-04-25 Thread Alan Bateman
On Mon, 24 Apr 2023 21:39:43 GMT, Stuart Marks wrote: >> 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-Sequen

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

2023-04-25 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: 8302987: Add uniform and spatially equidistributed bounded double streams to RandomGenerator [v7]

2023-04-25 Thread Raffaello Giulietti
> The `default` method `nextDouble(double origin, double bound)` in > `java.util.random.RandomGenerator` aims at generating a uniformly and > spatially equidistributed random `double` in the left-closed and right-open > range [`origin`, `bound`). It does so by applying the affine transform > `o

Re: RFR: 8302987: Add uniform and spatially equidistributed bounded double streams to RandomGenerator [v6]

2023-04-25 Thread Raffaello Giulietti
> The `default` method `nextDouble(double origin, double bound)` in > `java.util.random.RandomGenerator` aims at generating a uniformly and > spatially equidistributed random `double` in the left-closed and right-open > range [`origin`, `bound`). It does so by applying the affine transform > `o

Re: RFR: 8303762: [vectorapi] Intrinsification of Vector.slice [v6]

2023-04-25 Thread Jatin Bhateja
On Tue, 25 Apr 2023 11:57:21 GMT, Jatin Bhateja wrote: >> Quan Anh Mai has updated the pull request incrementally with one additional >> commit since the last revision: >> >> style > > src/hotspot/share/opto/vectorIntrinsics.cpp line 1914: > >> 1912: if (vector_klass->const_oop() == NULL |

Re: RFR: 8303762: [vectorapi] Intrinsification of Vector.slice [v6]

2023-04-25 Thread Jatin Bhateja
On Tue, 4 Apr 2023 13:46:12 GMT, Quan Anh Mai wrote: >> `Vector::slice` is a method at the top-level class of the Vector API that >> concatenates the 2 inputs into an intermediate composite and extracts a >> window equal to the size of the inputs into the result. It is used in vector >> conver

Re: RFR: 8305990: Stripping debug info of ASM 9.5 fails [v9]

2023-04-25 Thread Adam Sotona
> Classfile API didn't handle transformations of class files version 50 and > below correctly. > > Proposed fix have two parts: > 1. Inflation of branch targets does not depend on StackMapTable attribute > presence for class file version 50 and below. Alternative fallback > implementation is

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

2023-04-25 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 label

Re: RFR: 8305990: Stripping debug info of ASM 9.5 fails [v8]

2023-04-25 Thread Adam Sotona
> Classfile API didn't handle transformations of class files version 50 and > below correctly. > > Proposed fix have two parts: > 1. Inflation of branch targets does not depend on StackMapTable attribute > presence for class file version 50 and below. Alternative fallback > implementation is

Re: RFR: 8305092: Improve Thread.sleep(millis, nanos) for sub-millisecond granularity [v11]

2023-04-25 Thread Aleksey Shipilev
> Java API has the `Thread.sleep(millis, nanos)` method exposed to users. The > documentation for that method clearly says the precision and accuracy are > dependent on the underlying system behavior. However, it always rounds up > `nanos` to 1ms when doing the actual sleep. This means users can

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

2023-04-25 Thread Maurizio Cimadamore
On Tue, 25 Apr 2023 10:23:11 GMT, Maurizio Cimadamore wrote: >> test/langtools/tools/javac/patterns/Exhaustiveness.java line 1: >> >>> 1: /* >> >> Isn't `Isn't `testCoversType1` the same as `testExhaustiveStatement3` ? > > Some of the tests called `testExhaustiveStatement` do not seem to test

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

2023-04-25 Thread Maurizio Cimadamore
On Tue, 25 Apr 2023 10:22:40 GMT, Maurizio Cimadamore wrote: >> Jan Lahoda has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Reflecting review changes. > > test/langtools/tools/javac/patterns/Exhaustiveness.java line 1: > >> 1: /* > > I

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

2023-04-25 Thread Maurizio Cimadamore
On Tue, 25 Apr 2023 10:33:33 GMT, Maurizio Cimadamore wrote: >> Some of the tests called `testExhaustiveStatement` do not seem to test >> statements at all > > In the two `testXYZExhaustiveIntersection` the class hierarchy seems the same > - can we reuse it across multiple test cases? I see so

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

2023-04-25 Thread Maurizio Cimadamore
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 removed.

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

2023-04-25 Thread Maurizio Cimadamore
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 removed.

Re: RFR: 8266571: Sequenced Collections [v7]

2023-04-25 Thread Pavel Rappo
On Thu, 20 Apr 2023 16:19:05 GMT, Stuart Marks wrote: >>> I didn't know about the need to specify `@throws` in order to generate the >>> throws-clauses in the docs. >> >> You need to explicitly inherit `@throws` only for exceptions that aren't >> mentioned in the `throws` clause. >> >>> As a

Re: RFR: 8305990: Stripping debug info of ASM 9.5 fails [v3]

2023-04-25 Thread Adam Sotona
On Thu, 20 Apr 2023 08:24:40 GMT, Adam Sotona wrote: >> src/java.base/share/classes/jdk/internal/classfile/impl/BufWriterImpl.java >> line 86: >> >>> 84: } >>> 85: >>> 86: public void setMajorVersion(int majorVersion) { >> >> We should ensure the version is not changed once writing ha

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

2023-04-25 Thread Adam Sotona
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 wit

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

2023-04-25 Thread Sergey Tsypanov
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 de

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

2023-04-25 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 model

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

2023-04-25 Thread Adam Sotona
On Tue, 25 Apr 2023 07:38:41 GMT, Adam Sotona 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. BTW: for example `ClassDesc:of(String name)` performs repeated

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

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 16:33:58 GMT, Chen Liang 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. Performing validation in constructors I see as a blocker for po