Re: RFR: 8298047: Remove all non-significant trailing whitespace from properties files [v2]

2023-06-23 Thread Vladimir Sitnikov
On Mon, 16 Jan 2023 16:50:06 GMT, Magnus Ihse Bursie wrote: >> [JDK-8295729](https://bugs.openjdk.org/browse/JDK-8295729) was created in an >> attempt to remove all trailing whitespace from properties files, and enable >> a jcheck verification that they did not come back, similar to other sourc

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Glavo
On Sat, 24 Jun 2023 05:24:46 GMT, Jaikiran Pai wrote: > Hello Glavo, I was going to recommend adding a test method to existing jtreg > tests to test these new methods. But it looks like there's no jtreg test for > this `ByteArrayLittleEndian` class. Would you mind creating a new test class > t

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Glavo
On Sat, 24 Jun 2023 05:24:24 GMT, Alan Bateman wrote: >> Using `ByteArrayLittleEndian` is simpler and faster. >> >> `make test TEST="micro:java.util.zip.ZipFileOpen"`: >> >> >> Benchmark (size) Mode Cnt Score Error >> Units >> - ZipFileOpen.openCloseZipFile

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Jaikiran Pai
On Fri, 23 Jun 2023 20:00:12 GMT, Glavo wrote: > Using `ByteArrayLittleEndian` is simpler and faster. > > `make test TEST="micro:java.util.zip.ZipFileOpen"`: > > > Benchmark (size) Mode Cnt Score Error Units > - ZipFileOpen.openCloseZipFile 512 avgt 15

Re: RFR: 8310682: No package-info (and @since) for package jdk.nio.mapmode

2023-06-23 Thread Alan Bateman
On Fri, 23 Jun 2023 16:30:15 GMT, Brian Burkhalter wrote: > Add `package-info.java` for package `jdk.nio.mapmode`. Marked as reviewed by alanb (Reviewer). - PR Review: https://git.openjdk.org/jdk/pull/14628#pullrequestreview-1496355363

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Alan Bateman
On Fri, 23 Jun 2023 20:00:12 GMT, Glavo wrote: > Using `ByteArrayLittleEndian` is simpler and faster. > > `make test TEST="micro:java.util.zip.ZipFileOpen"`: > > > Benchmark (size) Mode Cnt Score Error Units > - ZipFileOpen.openCloseZipFile 512 avgt 15

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Jaikiran Pai
On Fri, 23 Jun 2023 20:00:12 GMT, Glavo wrote: > Using `ByteArrayLittleEndian` is simpler and faster. > > `make test TEST="micro:java.util.zip.ZipFileOpen"`: > > > Benchmark (size) Mode Cnt Score Error Units > - ZipFileOpen.openCloseZipFile 512 avgt 15

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v8]

2023-06-23 Thread Alan Bateman
On Fri, 23 Jun 2023 23:23:07 GMT, Brian Burkhalter wrote: >> Clarify the behavior of `java.lang.Readable` when the specified >> `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. > > Brian Burkhalter has updated the pull request incrementally with one > additional comm

Re: RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Chen Liang
On Fri, 23 Jun 2023 20:00:12 GMT, Glavo wrote: > Using `ByteArrayLittleEndian` is simpler and faster. > > `make test TEST="micro:java.util.zip.ZipFileOpen"`: > > > Benchmark (size) Mode Cnt Score Error Units > - ZipFileOpen.openCloseZipFile 512 avgt 15

RFR: 8310837: Use ByteArrayLittleEndian in java.util.zip

2023-06-23 Thread Glavo
Using `ByteArrayLittleEndian` is simpler and faster. `make test TEST="micro:java.util.zip.ZipFileOpen"`: Benchmark (size) Mode Cnt Score Error Units - ZipFileOpen.openCloseZipFile 512 avgt 15 39052.832 ± 107.496 ns/op + ZipFileOpen.openCloseZipFile

Re: RFR: 8308780: Fix the Java Integer types on Windows [v12]

2023-06-23 Thread Julian Waters
On Fri, 23 Jun 2023 17:09:12 GMT, Julian Waters wrote: >> On Windows, the basic Java Integer types are defined as long and __int64 >> respectively. In particular, the former is rather problematic since it >> breaks compilation as the Visual C++ becomes stricter and more compliant >> with every

Re: RFR: 8308780: Fix the Java Integer types on Windows [v13]

2023-06-23 Thread Julian Waters
> On Windows, the basic Java Integer types are defined as long and __int64 > respectively. In particular, the former is rather problematic since it breaks > compilation as the Visual C++ becomes stricter and more compliant with every > release, which means the way Windows code treats long as a t

Re: RFR: 8310405: Linker.Option.firstVariadicArg should specify which index values are valid [v3]

2023-06-23 Thread Jorn Vernee
On Fri, 23 Jun 2023 23:58:05 GMT, Jorn Vernee wrote: >> Improve the specification of `Linker.Option.firstVariadicArg`, by specifying >> more clearly which index values are valid. > > Jorn Vernee has updated the pull request incrementally with three additional > commits since the last revision:

RFR: 8310838: Correct range notations in MethodTypeDesc specification

2023-06-23 Thread Chen Liang
https://docs.oracle.com/en/java/javase/20/docs/api/java.base/java/lang/constant/MethodTypeDesc.html These 3 typos are discovered while browsing the online documentation. It probably doesn't need a CSR for it doesn't change the specification at all. - Commit messages: - 8310838: Cor

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v8]

2023-06-23 Thread Lance Andersen
On Fri, 23 Jun 2023 23:23:07 GMT, Brian Burkhalter wrote: >> Clarify the behavior of `java.lang.Readable` when the specified >> `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. > > Brian Burkhalter has updated the pull request incrementally with one > additional comm

Re: RFR: 8310405: Linker.Option.firstVariadicArg should specify which index values are valid [v3]

2023-06-23 Thread Jorn Vernee
> Improve the specification of `Linker.Option.firstVariadicArg`, by specifying > more clearly which index values are valid. Jorn Vernee has updated the pull request incrementally with three additional commits since the last revision: - review comments - Update src/java.base/share/classes/java

Re: RFR: JDK-8310502 : Optimization for j.l.Long.fastUUID() [v21]

2023-06-23 Thread 温绍锦
On Fri, 23 Jun 2023 19:30:31 GMT, ExE Boss wrote: >> 温绍锦 has updated the pull request incrementally with one additional commit >> since the last revision: >> >> format code > > src/java.base/share/classes/java/lang/Long.java line 493: > >> 491: | H256[((int) lsb) & 0x

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v8]

2023-06-23 Thread Brian Burkhalter
> Clarify the behavior of `java.lang.Readable` when the specified > `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8222329: Disambiguate length/remaini

Integrated: JDK-8310571: Use inline @return tag on java.util.Objects

2023-06-23 Thread Joe Darcy
On Thu, 22 Jun 2023 00:19:03 GMT, Joe Darcy wrote: > Small cleanup, minor differences in the wording of portions of > toString(Object, String), nonNull(Object), requireNonNullElse, and > requireNonNullElseGet. This pull request has now been integrated. Changeset: 0db63ec7 Author:Joe Darcy

Re: RFR: JDK-8310571: Use inline @return tag on java.util.Objects [v3]

2023-06-23 Thread Joe Darcy
> Small cleanup, minor differences in the wording of portions of > toString(Object, String), nonNull(Object), requireNonNullElse, and > requireNonNullElseGet. Joe Darcy has updated the pull request incrementally with one additional commit since the last revision: Make sure there is not an un

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Wed, 1 Feb 2023 10:36:12 GMT, Sergey Tsypanov wrote: >> `ResourceBundle.CacheKey.equals()` and `Bundles.CacheKey.equals()` are quire >> outdated. This simple clean-up modernizes them. > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last r

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 21:59:21 GMT, Pavel Rappo wrote: > NPE was seemingly caught to cover for other being null. Unlike that of other file in this PR. - PR Review Comment: https://git.openjdk.org/jdk/pull/12328#discussion_r1240446275

Re: RFR: JDK-8310571: Use inline @return tag on java.util.Objects [v2]

2023-06-23 Thread Joe Darcy
> Small cleanup, minor differences in the wording of portions of > toString(Object, String), nonNull(Object), requireNonNullElse, and > requireNonNullElseGet. Joe Darcy has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated

Integrated: 8310234: Refactor Locale tests to use JUnit

2023-06-23 Thread Justin Lu
On Thu, 22 Jun 2023 01:08:30 GMT, Justin Lu wrote: > Please review this PR as apart of > [JDK-8307843](https://bugs.openjdk.org/browse/JDK-8307843) which refactors > some tests in Locale to use JUnit. Other cleanup and small changes are > included as well. More refactoring in Locale tests will

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v7]

2023-06-23 Thread Roger Riggs
On Fri, 23 Jun 2023 20:56:14 GMT, Brian Burkhalter wrote: >> Clarify the behavior of `java.lang.Readable` when the specified >> `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. > > Brian Burkhalter has updated the pull request incrementally with one > additional comm

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v6]

2023-06-23 Thread Brian Burkhalter
On Fri, 23 Jun 2023 20:46:29 GMT, Brian Burkhalter wrote: >> src/java.base/share/classes/java/io/Reader.java line 194: >> >>> 192: * rewinding of the buffer is performed. If the specified >>> character >>> 193: * buffer has no space {@linkplain java.nio.Buffer#hasRemaining >>> 194:

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v7]

2023-06-23 Thread Brian Burkhalter
> Clarify the behavior of `java.lang.Readable` when the specified > `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8222329: "or or" -> "or" --

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v6]

2023-06-23 Thread Brian Burkhalter
On Fri, 23 Jun 2023 20:36:59 GMT, Roger Riggs wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8222329: Remove redundancy of length vs. remaining in CharBuffer::read doc > > src/java.base/share/classes/java/io/R

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Naoto Sato
On Wed, 1 Feb 2023 10:36:12 GMT, Sergey Tsypanov wrote: >> `ResourceBundle.CacheKey.equals()` and `Bundles.CacheKey.equals()` are quire >> outdated. This simple clean-up modernizes them. > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last r

Re: RFR: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-23 Thread Roger Riggs
On Wed, 21 Jun 2023 15:03:12 GMT, Sergey Tsypanov wrote: >> Just a tiny clean-up to remove racy read within synchronized method > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last revision: > > Update src/java.base/share/classes/java/io/P

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v6]

2023-06-23 Thread Roger Riggs
On Fri, 23 Jun 2023 17:19:10 GMT, Brian Burkhalter wrote: >> Clarify the behavior of `java.lang.Readable` when the specified >> `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. > > Brian Burkhalter has updated the pull request incrementally with one > additional comm

Re: RFR: 8308694: Clarify reversed() default methods' implementation requirements [v2]

2023-06-23 Thread Roger Riggs
On Thu, 22 Jun 2023 22:07:19 GMT, Stuart Marks wrote: >> Can I get a preliminary review of the wording for Deque.reversed()? If the >> text is good, I'll make corresponding changes to the implSpecs of the other >> reversed() default methods, namely those in List, SortedMap, and SortedSet >> an

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Wed, 1 Feb 2023 10:36:12 GMT, Sergey Tsypanov wrote: >> `ResourceBundle.CacheKey.equals()` and `Bundles.CacheKey.equals()` are quire >> outdated. This simple clean-up modernizes them. > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last r

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 17:05:19 GMT, Naoto Sato wrote: >> I'll run our CI, and if all good, I'll approve this PR. If nothing else, >> this change seems reasonable and correct. > > Thanks Pavel for jumping in. I too think this change looks good. Yep; all good. - PR Review Comment: htt

[jdk21] Integrated: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Daniel D . Daugherty
On Fri, 23 Jun 2023 19:30:56 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java > on generic-x64. This pull request has now been integrated. Changeset: af3a56e5 Author:Daniel D. Daugherty URL: https://git.openjdk.org/jdk21

Re: [jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Daniel D . Daugherty
On Fri, 23 Jun 2023 19:44:50 GMT, Iris Clark wrote: >> A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java >> on generic-x64. > > Marked as reviewed by iris (Reviewer). @irisclark and @lmesnik - Thanks for the fast reviews! - PR Comment: https://git.openjdk

Re: [jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Daniel D . Daugherty
On Fri, 23 Jun 2023 19:45:19 GMT, Leonid Mesnik wrote: >> A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java >> on generic-x64. > > test/jdk/ProblemList-Xcomp.txt line 31: > >> 29: >> 30: java/lang/invoke/MethodHandles/CatchExceptionTest.java 8146623 >> generic-all >>

Re: [jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Leonid Mesnik
On Fri, 23 Jun 2023 19:30:56 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java > on generic-x64. Marked as reviewed by lmesnik (Reviewer). - PR Review: https://git.openjdk.org/jdk21/pull/60#pullrequestreview-1495844009

Re: [jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Iris Clark
On Fri, 23 Jun 2023 19:30:56 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java > on generic-x64. Marked as reviewed by iris (Reviewer). - PR Review: https://git.openjdk.org/jdk21/pull/60#pullrequestreview-1495822256

Re: [jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Leonid Mesnik
On Fri, 23 Jun 2023 19:30:56 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java > on generic-x64. Changes requested by lmesnik (Reviewer). test/jdk/ProblemList-Xcomp.txt line 31: > 29: > 30: java/lang/invoke/MethodHandles/CatchExcep

Integrated: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-23 Thread Joe Darcy
On Wed, 21 Jun 2023 00:00:54 GMT, Joe Darcy wrote: > Correct misstatement that the Class object for a primitive type can only be > be access via fields like java.lang.Integer.TYPE. This pull request has now been integrated. Changeset: 0314292c Author:Joe Darcy URL: https://git.open

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v4]

2023-06-23 Thread Joe Darcy
> Correct misstatement that the Class object for a primitive type can only be > be access via fields like java.lang.Integer.TYPE. Joe Darcy has updated the pull request incrementally with one additional commit since the last revision: Fix another typo and reflow paragraphs. - Ch

[jdk21] RFR: 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64

2023-06-23 Thread Daniel D . Daugherty
A trivial fix to ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64. - Commit messages: - 8310822: JDK21: ProblemList java/lang/ScopedValue/StressStackOverflow.java on generic-x64 Changes: https://git.openjdk.org/jdk21/pull/60/files Webrev: https://webrevs.

Re: RFR: JDK-8310502 : Optimization for j.l.Long.fastUUID() [v21]

2023-06-23 Thread ExE Boss
On Fri, 23 Jun 2023 11:24:23 GMT, 温绍锦 wrote: >> By optimizing the implementation of java.lang.Long#fastUUID, the performance >> of the java.util.UUID#toString method can be significantly improved. >> >> The following are the test results of JMH: >> >> Benchmark Mode Cnt

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v3]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 17:57:22 GMT, Joe Darcy wrote: >> Correct misstatement that the Class object for a primitive type can only be >> be access via fields like java.lang.Integer.TYPE. > > Joe Darcy has updated the pull request incrementally with one additional > commit since the last revision: >

Re: RFR: 8308780: Fix the Java Integer types on Windows [v12]

2023-06-23 Thread Alexey Ivanov
On Fri, 23 Jun 2023 17:09:12 GMT, Julian Waters wrote: >> On Windows, the basic Java Integer types are defined as long and __int64 >> respectively. In particular, the former is rather problematic since it >> breaks compilation as the Visual C++ becomes stricter and more compliant >> with every

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v3]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 17:57:22 GMT, Joe Darcy wrote: >> Correct misstatement that the Class object for a primitive type can only be >> be access via fields like java.lang.Integer.TYPE. > > Joe Darcy has updated the pull request incrementally with one additional > commit since the last revision: >

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v3]

2023-06-23 Thread Joe Darcy
> Correct misstatement that the Class object for a primitive type can only be > be access via fields like java.lang.Integer.TYPE. Joe Darcy has updated the pull request incrementally with one additional commit since the last revision: Fix typo. - Changes: - all: https://git.op

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v2]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 17:25:00 GMT, Joe Darcy wrote: >> Correct misstatement that the Class object for a primitive type can only be >> be access via fields like java.lang.Integer.TYPE. > > Joe Darcy has updated the pull request with a new target base due to a merge > or a rebase. The incremental

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v2]

2023-06-23 Thread Joe Darcy
On Fri, 23 Jun 2023 11:58:00 GMT, Pavel Rappo wrote: >> Thanks for the links, @pavelrappo. >> >> I understand the point you're making; however, there is still ambiguous >> wording in the documentation for this method. >> >> The method is called `isPrimitive`, and it returns `true` for >> `isP

Re: RFR: 8310405: Linker.Option.firstVariadicArg should specify which index values are valid [v2]

2023-06-23 Thread Maurizio Cimadamore
On Fri, 23 Jun 2023 17:24:30 GMT, Maurizio Cimadamore wrote: >> Jorn Vernee has updated the pull request incrementally with one additional >> commit since the last revision: >> >> polish doc, review comments > > src/java.base/share/classes/java/lang/foreign/Linker.java line 659: > >> 657:

Re: RFR: 8310405: Linker.Option.firstVariadicArg should specify which index values are valid [v2]

2023-06-23 Thread Maurizio Cimadamore
On Wed, 21 Jun 2023 23:33:37 GMT, Jorn Vernee wrote: >> Improve the specification of `Linker.Option.firstVariadicArg`, by specifying >> more clearly which index values are valid. > > Jorn Vernee has updated the pull request incrementally with one additional > commit since the last revision: >

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives [v2]

2023-06-23 Thread Joe Darcy
> Correct misstatement that the Class object for a primitive type can only be > be access via fields like java.lang.Integer.TYPE. Joe Darcy 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 mer

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v6]

2023-06-23 Thread Brian Burkhalter
> Clarify the behavior of `java.lang.Readable` when the specified > `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8222329: Remove redundancy of length

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v4]

2023-06-23 Thread Brian Burkhalter
On Fri, 23 Jun 2023 17:07:34 GMT, Brian Burkhalter wrote: >> I checked the update but it now has "no source remaining or its length is >> zero". In CB, length == remaining so I think you just want one in the >> description. > > Ah, good catch! Fixed by 7281b482c24a3c74da15dbf637f7627c5dc5407b.

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v4]

2023-06-23 Thread Brian Burkhalter
On Fri, 23 Jun 2023 16:50:28 GMT, Alan Bateman wrote: >> Addressed in 94505a45ce099faf3e31a07b8500ac456345a3b1; CSR not yet updated. > > I checked the update but it now has "no source remaining or its length is > zero". In CB, length == remaining so I think you just want one in the > descriptio

Integrated: JDK-8310460: Remove jdeps -profile option

2023-06-23 Thread Mandy Chung
On Tue, 20 Jun 2023 18:42:30 GMT, Mandy Chung wrote: > Compact profiles are defined in Java SE 8 and are legacy in Java SE 9. jdeps > -profile option was deprecated for removal in JDK 21. This option can be > removed in JDK 22. Customers can use jdeps to find the set of modules > required by t

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Julian Waters
On Fri, 23 Jun 2023 02:38:13 GMT, Julian Waters wrote: >> On Windows, the basic Java Integer types are defined as long and __int64 >> respectively. In particular, the former is rather problematic since it >> breaks compilation as the Visual C++ becomes stricter and more compliant >> with every

Re: RFR: 8308780: Fix the Java Integer types on Windows [v12]

2023-06-23 Thread Julian Waters
> On Windows, the basic Java Integer types are defined as long and __int64 > respectively. In particular, the former is rather problematic since it breaks > compilation as the Visual C++ becomes stricter and more compliant with every > release, which means the way Windows code treats long as a t

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Naoto Sato
On Fri, 23 Jun 2023 15:11:47 GMT, Pavel Rappo wrote: >> Yes: >> >> CacheKey(String baseName, Locale locale, Module module, Module caller) { >> Objects.requireNonNull(module); >> Objects.requireNonNull(caller); >> >> this.name = baseName; >> this.locale = locale; >> this.modu

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Julian Waters
On Fri, 23 Jun 2023 16:53:01 GMT, Alexey Ivanov wrote: >> Hmm, I lean towards jint as I feel it conveys the fact that it is a Java >> parameter clearer, intuitively to me it makes sense that a Java integer type >> would still work in a C++ for loop in native code > > You're right… it gives a hi

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Alexey Ivanov
On Fri, 23 Jun 2023 14:30:49 GMT, Julian Waters wrote: >> To minimise the number of changes, we can go for using `jint` in >> `AwtMenu::GetItem`. >> >> What do you thing, @djelinski and @TheShermanTanker? > > Hmm, I lean towards jint as I feel it conveys the fact that it is a Java > parameter

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v4]

2023-06-23 Thread Alan Bateman
On Fri, 23 Jun 2023 15:38:52 GMT, Brian Burkhalter wrote: >> src/java.base/share/classes/java/nio/X-Buffer.java.template line 484: >> >>> 482: * @throws ReadOnlyBufferException if target is a read only buffer, >>> 483: * even if it is empty >>> 484: * @since 1.5 >> >> It

RFR: 8310459: [BACKOUT] 8304450: [vectorapi] Refactor VectorShuffle implementation

2023-06-23 Thread Jatin Bhateja
Backing out shuffle related overhaul done with [JDK-8304450](https://bugs.openjdk.org/browse/JDK-8304450), we saw significant performance degradation with VectorAPI JMH and our internal benchmarks. Following two issues were filed on this recently. 1/ [JDK-8310459](https://bugs.openjdk.org/brows

RFR: 8310682: No package-info (and @since) for package jdk.nio.mapmode

2023-06-23 Thread Brian Burkhalter
Add `package-info.java` for package `jdk.nio.mapmode`. - Commit messages: - 8310682: No package-info (and @since) for package jdk.nio.mapmode Changes: https://git.openjdk.org/jdk/pull/14628/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=14628&range=00 Issue: https://bugs.

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v5]

2023-06-23 Thread Brian Burkhalter
On Thu, 22 Jun 2023 22:15:11 GMT, Brian Burkhalter wrote: >> I have a slight preference for "no space remaining"; remaining can still be >> a linkplain to the method if that helps it be specific. > > I concur. Thanks. Addressed in 055107bddcc38a331ee93e178402473ab9f91740. - PR Rev

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v4]

2023-06-23 Thread Brian Burkhalter
On Fri, 23 Jun 2023 06:49:31 GMT, Alan Bateman wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8222329: Correct return verbiage of Reader and CharBuffer > > src/java.base/share/classes/java/nio/X-Buffer.java.te

Re: RFR: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v5]

2023-06-23 Thread Brian Burkhalter
> Clarify the behavior of `java.lang.Readable` when the specified > `java.nio.CharBuffer` parameter is empty but read-only, and when it is full. Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision: 8222329: Tweak verbiage some more -

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 13:46:04 GMT, Sergey Tsypanov wrote: >> src/java.base/share/classes/java/util/ResourceBundle.java line 743: >> >>> 741: return ((module != null) && >>> (module.equals(otherEntry.getModule())) && >>> 742: (caller != null) && >>> (calle

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Julian Waters
On Fri, 23 Jun 2023 14:28:51 GMT, Alexey Ivanov wrote: >> The declaration and implementation have to match. > > To minimise the number of changes, we can go for using `jint` in > `AwtMenu::GetItem`. > > What do you thing, @djelinski and @TheShermanTanker? Hmm, I lean towards jint as I feel it

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Alexey Ivanov
On Fri, 23 Jun 2023 14:24:44 GMT, Alexey Ivanov wrote: >> src/java.desktop/windows/native/libawt/windows/awt_Menu.h line 76: >> >>> 74: /*for multifont menu */ >>> 75: BOOL IsTopMenu(); >>> 76: virtual AwtMenuItem* GetItem(jobject target, int index); >> >> Hi @aivanov-jdk are you OK

Re: RFR: 8308780: Fix the Java Integer types on Windows [v9]

2023-06-23 Thread Alexey Ivanov
On Fri, 23 Jun 2023 00:16:45 GMT, Julian Waters wrote: >> src/java.desktop/windows/native/libawt/windows/awt_MenuBar.cpp line 148: >> >>> 146: } >>> 147: >>> 148: AwtMenuItem* AwtMenuBar::GetItem(jobject target, jint index) >> >> What is the reason for using `jint` instead of `int`? >> >> The

Re: RFR: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-23 Thread Alexey Ivanov
On Fri, 23 Jun 2023 06:10:05 GMT, Daniel Jeliński wrote: >> Julian Waters has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Revert wrong Copyright >> - Copyright > > src/java.desktop/windows/native/libawt/windows/awt_Menu.h line 76: >

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Sergey Tsypanov
On Fri, 23 Jun 2023 10:41:49 GMT, Pavel Rappo wrote: >> Sergey Tsypanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Restore logic > > src/java.base/share/classes/java/util/ResourceBundle.java line 743: > >> 741: retu

Re: RFR: 8307512: Provide more information in message of NoSuchFieldException thrown by Class

2023-06-23 Thread Chen Liang
On Fri, 23 Jun 2023 07:44:31 GMT, Daohan Qu wrote: > Similar to #11745 , this patch adds more information for > `NoSuchFieldException` thrown by `getField()` or `getDeclaredField()` of > `java.lang.Class`. The error message changes like the example below: > 1. For `getField()` > > Before this

Re: RFR: 8240567: MethodTooLargeException thrown while creating a jlink image [v5]

2023-06-23 Thread Oliver Kopp
> Fix for [JDK-8240567](https://bugs.openjdk.org/browse/JDK-8240567): > "MethodTooLargeException thrown while creating a jlink image". > > Java still has a 64kb limit: A method may not be longer than 64kb. The idea > of the fix is to split up the generated methods in several smaller methods > >

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-23 Thread Pavel Rappo
On Fri, 23 Jun 2023 11:52:12 GMT, Sam Brannen wrote: > Along that line of thinking, it might be best to change the first sentence to > "Determines if the specified Class object represents a primitive type or > void." I was just about to suggest exactly that, but from the superinterface method'

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-23 Thread Sam Brannen
On Fri, 23 Jun 2023 11:34:43 GMT, Pavel Rappo wrote: >> Hmm. I'll consider that. The javadoc in java.lang.Class is inconsistent in >> the formatting of "void" as a type name, some instances are in code markup >> while others are not. > >> @jddarcy and @pavelrappo, as I understood it, @liach is

[jdk21] RFR: 8309670: java -help output for --module-path / -p is incomplete

2023-06-23 Thread Christian Stein
Hi all, This pull request contains a backport of commit [4bf78162](https://github.com/openjdk/jdk/commit/4bf78162c52564645af79b8324b69d89102dc024) from the [openjdk/jdk](https://git.openjdk.org/jdk) repository. The commit being backported was authored by Christian Stein on 23 Jun 2023 and was

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-23 Thread Pavel Rappo
On Wed, 21 Jun 2023 00:35:09 GMT, Joe Darcy wrote: >> src/java.base/share/classes/java/lang/Class.java line 818: >> >>> 816: * they represent, namely {@code boolean}, {@code byte}, >>> 817: * {@code char}, {@code short}, {@code int}, >>> 818: * {@code long}, {@code float}, and {@c

Re: RFR: JDK-8310502 : Optimization for j.l.Long.fastUUID() [v21]

2023-06-23 Thread 温绍锦
> By optimizing the implementation of java.lang.Long#fastUUID, the performance > of the java.util.UUID#toString method can be significantly improved. > > The following are the test results of JMH: > > Benchmark Mode Cnt Score Error Units > UUIDUtilsBenchmark.new

Re: RFR: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-23 Thread Sam Brannen
On Wed, 21 Jun 2023 00:35:09 GMT, Joe Darcy wrote: >> src/java.base/share/classes/java/lang/Class.java line 818: >> >>> 816: * they represent, namely {@code boolean}, {@code byte}, >>> 817: * {@code char}, {@code short}, {@code int}, >>> 818: * {@code long}, {@code float}, and {@c

Integrated: 8309670: java -help output for --module-path / -p is incomplete

2023-06-23 Thread Christian Stein
On Tue, 20 Jun 2023 13:54:15 GMT, Christian Stein wrote: > Please review this update to `java`'s help output for `--module-path`/`-p`. > > This PR also updates the output for the closely related > `--upgrade-module-path` option. > > Thanks in advance! This pull request has now been integrated

Re: RFR: JDK-8310502 : Optimization for j.l.Long.fastUUID() [v20]

2023-06-23 Thread 温绍锦
> By optimizing the implementation of java.lang.Long#fastUUID, the performance > of the java.util.UUID#toString method can be significantly improved. > > The following are the test results of JMH: > > Benchmark Mode Cnt Score Error Units > UUIDUtilsBenchmark.new

Re: RFR: 8307512: Provide more information in message of NoSuchFieldException thrown by Class

2023-06-23 Thread Daohan Qu
On Fri, 23 Jun 2023 09:30:43 GMT, Chen Liang wrote: > I think a message like 'Class.field' is better, more consistent with > methodToString's behavior. Hi, @liach, thanks for your suggestions, this `Class.field` format is indeed more succinct. But I'm following this format (`NoSuchFieldError`

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Pavel Rappo
On Wed, 1 Feb 2023 10:36:12 GMT, Sergey Tsypanov wrote: >> `ResourceBundle.CacheKey.equals()` and `Bundles.CacheKey.equals()` are quire >> outdated. This simple clean-up modernizes them. > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last r

Re: RFR: 8309670: java -help output for --module-path / -p is incomplete [v2]

2023-06-23 Thread Alan Bateman
On Fri, 23 Jun 2023 09:37:47 GMT, Christian Stein wrote: >> Please review this update to `java`'s help output for `--module-path`/`-p`. >> >> This PR also updates the output for the closely related >> `--upgrade-module-path` option. >> >> Thanks in advance! > > Christian Stein has updated the

Re: RFR: 8309670: java -help output for --module-path / -p is incomplete [v2]

2023-06-23 Thread Christian Stein
> Please review this update to `java`'s help output for `--module-path`/`-p`. > > This PR also updates the output for the closely related > `--upgrade-module-path` option. > > Thanks in advance! Christian Stein has updated the pull request incrementally with one additional commit since the las

Re: RFR: 8307512: Provide more information in message of NoSuchFieldException thrown by Class

2023-06-23 Thread Chen Liang
On Fri, 23 Jun 2023 07:44:31 GMT, Daohan Qu wrote: > Similar to #11745 , this patch adds more information for > `NoSuchFieldException` thrown by `getField()` or `getDeclaredField()` of > `java.lang.Class`. The error message changes like the example below: > 1. For `getField()` > > Before this

Re: RFR: 8294982: Implementation of Classfile API [v58]

2023-06-23 Thread Andrey Turbanov
On Wed, 8 Mar 2023 08:50:24 GMT, Adam Sotona wrote: >> This is root pull request with Classfile API implementation, tests and >> benchmarks initial drop into JDK. >> >> Following pull requests consolidating JDK class files parsing, generating, >> and transforming >> ([JDK-8294957](https://bug

Re: RFR: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-23 Thread Sergey Tsypanov
On Thu, 22 Jun 2023 21:00:18 GMT, Roger Riggs wrote: >> Sergey Tsypanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Update src/java.base/share/classes/java/io/PipedOutputStream.java >> >> Co-authored-by: liach <7806504+li...@use

Re: RFR: 8301492: Modernize equals() method of ResourceBundle.CacheKey and Bundles.CacheKey [v3]

2023-06-23 Thread Sergey Tsypanov
On Wed, 1 Feb 2023 10:36:12 GMT, Sergey Tsypanov wrote: >> `ResourceBundle.CacheKey.equals()` and `Bundles.CacheKey.equals()` are quire >> outdated. This simple clean-up modernizes them. > > Sergey Tsypanov has updated the pull request incrementally with one > additional commit since the last r

Re: RFR: JDK-8310380: Handle problems in core-related tests on macOS when codesign tool does not work [v3]

2023-06-23 Thread Matthias Baesken
On Thu, 22 Jun 2023 11:51:15 GMT, Matthias Baesken wrote: >> Currently, a number of tests fail on macOS because they miss the core file >> (e.g. serviceability/sa/TestJmapCore.java). >> The reason is that configure detects on some setups that codesign does not >> work ("checking if debug mode c

Re: RFR: 8308286 Fix clang warnings in linux code [v8]

2023-06-23 Thread Daniel Jeliński
On Fri, 23 Jun 2023 08:03:45 GMT, Artem Semenov wrote: >> When using the clang compiler to build OpenJDk on Linux, we encounter >> various "warnings as errors". >> They can be fixed with small changes. > > Artem Semenov has updated the pull request incrementally with one additional > commit sin

Re: RFR: 8308286 Fix clang warnings in linux code [v6]

2023-06-23 Thread Artem Semenov
On Fri, 23 Jun 2023 06:19:31 GMT, Daniel Jeliński wrote: >> make/modules/java.desktop/lib/Awt2dLibraries.gmk line 241: >> >>> 239: DISABLED_WARNINGS_gcc_OGLPaints.c := >>> format-nonliteral, \ >>> 240: DISABLED_WARNINGS_gcc_sun_awt_X11_GtkFileDialogPeer.c >>> :=

Re: RFR: 8308286 Fix clang warnings in linux code [v8]

2023-06-23 Thread Artem Semenov
> When using the clang compiler to build OpenJDk on Linux, we encounter various > "warnings as errors". > They can be fixed with small changes. Artem Semenov has updated the pull request incrementally with one additional commit since the last revision: update - Changes: - all:

RFR: 8307512: Provide more information in message of NoSuchFieldException thrown by Class

2023-06-23 Thread Daohan Qu
Similar to #11745 , this patch adds more information for `NoSuchFieldException` thrown by `getField()` or `getDeclaredField()` of `java.lang.Class`. The error message changes like the example below: 1. For `getField()` Before this change: Exception in thread "main" java.lang.NoSuchFieldExceptio