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

2023-06-22 Thread Alan Bateman
On Thu, 22 Jun 2023 22:52:23 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: 8308780: Fix the Java Integer types on Windows [v11]

2023-06-22 Thread Daniel Jeliński
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: 8308286 Fix clang warnings in linux code [v6]

2023-06-22 Thread Daniel Jeliński
On Thu, 22 Jun 2023 09:58:19 GMT, Daniel Jeliński wrote: >> Artem Semenov has updated the pull request incrementally with one additional >> commit since the last revision: >> >> update > > make/modules/java.desktop/lib/Awt2dLibraries.gmk line 241: > >> 239: DISABLED_WARNINGS_

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

2023-06-22 Thread Julian Waters
On Thu, 8 Jun 2023 11:20:05 GMT, Alexey Ivanov wrote: >> Julian Waters has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fix the code that is actually warning > > I'll take a look… hopefully next week. Wait a minute, I was right, it was a

Re: RFR: 8305341: Alignment should be enforced by alignas instead of compiler specific attributes [v5]

2023-06-22 Thread Daniel Jeliński
On Fri, 23 Jun 2023 02:25:47 GMT, Julian Waters wrote: >> Julian Waters has updated the pull request incrementally with three >> additional commits since the last revision: >> >> - Whitespace >> - Revert >> - _MSC_VER > > @djelinski Sorry for the tag, it's just that this PR has been collecti

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

2023-06-22 Thread 温绍锦
On Fri, 23 Jun 2023 04:22:07 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

[jdk21] Integrated: 8309853: StructuredTaskScope.join description improvements

2023-06-22 Thread Alan Bateman
On Thu, 22 Jun 2023 10:45:02 GMT, Alan Bateman wrote: > 8309853: StructuredTaskScope.join description improvements This pull request has now been integrated. Changeset: e86d765b Author:Alan Bateman URL: https://git.openjdk.org/jdk21/commit/e86d765b229d6cc2270dcc90b40252851e50c959 St

Re: RFR: 8310242: Clarify the name parameter to Class::forName [v8]

2023-06-22 Thread David Holmes
On Thu, 22 Jun 2023 17:47:16 GMT, Mandy Chung wrote: >> This PR clarifies the spec of the 3-arg Class::forName regarding the format >> of the name for an array type which is of the form: one or more of "[" + >> binary name of the element type + ";'. > > Mandy Chung has updated the pull request

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

2023-06-22 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: 8305341: Alignment should be enforced by alignas instead of compiler specific attributes [v6]

2023-06-22 Thread Julian Waters
> C11 has been stable for a long time on all platforms, so native code can use > the standard alignas operator for alignment requirements Julian Waters has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 18 commits: - Merge branch 'open

Re: RFR: 8309819: Clarify API note in Class::getName and MethodType::toMethodDescriptorString [v7]

2023-06-22 Thread Chen Liang
On Thu, 22 Jun 2023 01:38:05 GMT, Chen Liang wrote: >> The API specification for descriptorString not being a strict inverse of >> Class::forName and MethodType::fromDescriptorString are not entirely correct. >> >> 1. Class::descriptorString was never an inverse of Class::forName, which >> tak

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

2023-06-22 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: 8305341: Alignment should be enforced by alignas instead of compiler specific attributes [v5]

2023-06-22 Thread Julian Waters
On Tue, 20 Jun 2023 07:20:12 GMT, Julian Waters wrote: >> C11 has been stable for a long time on all platforms, so native code can use >> the standard alignas operator for alignment requirements > > Julian Waters has updated the pull request incrementally with three > additional commits since t

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

2023-06-22 Thread Julian Waters
On Fri, 23 Jun 2023 00:31:28 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 [v10]

2023-06-22 Thread David Holmes
On Fri, 23 Jun 2023 00:31:28 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: 8310242: Clarify the name parameter to Class::forName [v8]

2023-06-22 Thread Chen Liang
On Thu, 22 Jun 2023 17:47:16 GMT, Mandy Chung wrote: >> This PR clarifies the spec of the 3-arg Class::forName regarding the format >> of the name for an array type which is of the form: one or more of "[" + >> binary name of the element type + ";'. > > Mandy Chung has updated the pull request

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

2023-06-22 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: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-22 Thread Chen Liang
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: 8308780: Fix the Java Integer types on Windows [v10]

2023-06-22 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: 8308780: Fix the Java Integer types on Windows [v9]

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 19:51:42 GMT, Alexey Ivanov wrote: >> Julian Waters has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Revert "GetDIBits should take an LPVOID" >> >> This reverts commit 7dbe5dea84b1afb2235b66da581bcd3c1da4d6ac. > >

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 19:37:56 GMT, Alexey Ivanov wrote: >> src/java.desktop/windows/native/libawt/windows/ShellFolder2.cpp line 1084: >> >>> 1082: >>> 1083: jint *colorBits = nullptr; >>> 1084: int *maskBits = nullptr; >> >> Suggestion: >> >> jint *colorBits

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 19:24:29 GMT, Alexey Ivanov wrote: >> src/java.desktop/windows/native/libawt/java2d/windows/GDIRenderer.cpp line >> 605: >> >>> 603: return; >>> 604: } >>> 605: jint sx, sy, ex, ey; >> >> Again these don't seem to need to be Java types. > > I've got the same

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 19:20:09 GMT, Alexey Ivanov wrote: >> Julian Waters has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Revert "GetDIBits should take an LPVOID" >> >> This reverts commit 7dbe5dea84b1afb2235b66da581bcd3c1da4d6ac. > >

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

2023-06-22 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: Correct return verbiage of

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

2023-06-22 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: "elements remaining" -> "sp

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

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 21:38:42 GMT, Roger Riggs wrote: >> Or "no remaining space" / "no space remaining"? > > 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. - PR Review Comment:

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

2023-06-22 Thread 温绍锦
On Thu, 22 Jun 2023 21:44:12 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: 8305734: BitSet.get(int, int) always returns the empty BitSet when the Integer.MAX VALUE is set

2023-06-22 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 OK. Feel free to discuss things here before trying to wordsmith the CSR. It's probably easier to discuss and get agreement on a sketch of a solution before trying to commit the s

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

2023-06-22 Thread Stuart Marks
On Thu, 15 Jun 2023 22:38:43 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 > and th

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

2023-06-22 Thread Stuart Marks
> 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 > and then file the CSR. Stuart Marks has updated the pull requ

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

2023-06-22 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: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v2]

2023-06-22 Thread Roger Riggs
On Thu, 22 Jun 2023 21:25:32 GMT, Brian Burkhalter wrote: >> For a buffer that is being written into, it sounds a bit odd to say "no >> remaining elements"; that phrasing is ok for reading/getting bytes but >> doesn't sound like there's free space to put anything. >> >> Would "no remaining fre

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v4]

2023-06-22 Thread Naoto Sato
On Thu, 22 Jun 2023 20:41:33 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

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

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 21:21:56 GMT, Roger Riggs wrote: >> src/java.base/share/classes/java/io/Reader.java line 193: >> >>> 191: * changes made are the results of a put operation. No flipping or >>> 192: * rewinding of the buffer is performed. If the specified >>> character >>> 193:

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

2023-06-22 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: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer [v2]

2023-06-22 Thread Roger Riggs
On Thu, 22 Jun 2023 19:39:16 GMT, Brian Burkhalter wrote: >> Brian Burkhalter has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8222329: rephrase "full" to "no elements remaining" > > src/java.base/share/classes/java/io/Reader.java line 19

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

2023-06-22 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: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-22 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: 8310182: DateTimeFormatter date formats (ISO_LOCAL_DATE) separated with hyphen, not dash

2023-06-22 Thread Roger Riggs
On Thu, 22 Jun 2023 20:36:48 GMT, Naoto Sato wrote: > Replacing the ambiguous `dash` with `hyphen-minus` for more clarity. There > are other locations than `ISO_LOCAL_DATE` that have the same description. > Those are corrected too. Correcting the description of the delimiter seems like the bes

RFR: 8310182: DateTimeFormatter date formats (ISO_LOCAL_DATE) separated with hyphen, not dash

2023-06-22 Thread Naoto Sato
Replacing the ambiguous `dash` with `hyphen-minus` for more clarity. There are other locations than `ISO_LOCAL_DATE` that have the same description. Those are corrected too. - Commit messages: - 8310182: DateTimeFormatter date formats (ISO_LOCAL_DATE) separated with hyphen, not da

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v4]

2023-06-22 Thread Justin Lu
On Thu, 22 Jun 2023 20:02:12 GMT, Naoto Sato wrote: >> Unless I am mistaken, both bug IDs, 4122700 8282319 are in the combined file. > > Yes. I wanted to make it clear that this `nonEmptyLocalesTest` was for the > issue 4122700. Sorry, I totally misread you said 'method'. Fixed `nonEmptyLocales

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v4]

2023-06-22 Thread Justin Lu
> 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 be done in separate > PRs. > > If the test had a b

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

2023-06-22 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: rephrase "full" to "no elem

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

2023-06-22 Thread Lance Andersen
On Thu, 22 Jun 2023 19:00:58 GMT, Brian Burkhalter wrote: >> src/java.base/share/classes/java/lang/Readable.java line 49: >> >>> 47: * @param cb the buffer to read characters into >>> 48: * @return The number of {@code char} values added to the buffer, >>> 49: * possibly z

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

2023-06-22 Thread Sergey Tsypanov
On Thu, 22 Jun 2023 15:45:21 GMT, Brian Burkhalter 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..

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

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 15:45:21 GMT, Brian Burkhalter 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..

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v3]

2023-06-22 Thread Naoto Sato
On Thu, 22 Jun 2023 19:23:27 GMT, Justin Lu wrote: >> test/jdk/java/util/Locale/AvailableLocalesTest.java line 46: >> >>> 44: /** >>> 45: * Test that Locale.getAvailableLocales() is non-empty. >>> 46: * Print out the locales. >> >> If you combine two tests into a single one, I'd p

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

2023-06-22 Thread Alexey Ivanov
On Thu, 22 Jun 2023 19:33:17 GMT, Alexey Ivanov wrote: >> Julian Waters has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Revert "GetDIBits should take an LPVOID" >> >> This reverts commit 7dbe5dea84b1afb2235b66da581bcd3c1da4d6ac. > >

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

2023-06-22 Thread Alexey Ivanov
On Thu, 25 May 2023 01:30:34 GMT, David Holmes wrote: >> Julian Waters has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Revert "GetDIBits should take an LPVOID" >> >> This reverts commit 7dbe5dea84b1afb2235b66da581bcd3c1da4d6ac. > >

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

2023-06-22 Thread Alexey Ivanov
On Thu, 22 Jun 2023 14:40:23 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: 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 18:22:35 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. src/java.base/share/classes/java/io/Reader.java line 193: > 191: * changes made are th

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v3]

2023-06-22 Thread Justin Lu
> 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 be done in separate > PRs. > > If the test had a b

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v3]

2023-06-22 Thread Justin Lu
On Thu, 22 Jun 2023 18:47:06 GMT, Naoto Sato wrote: >> Justin Lu has updated the pull request incrementally with four additional >> commits since the last revision: >> >> - Method signature is too long >> - Exceptions in GetInstanceCheck.java are distinct, catch clause should be >> reserved

Re: RFR: 8308452: Extend internal Architecture enum with byte order and address size [v6]

2023-06-22 Thread Roger Riggs
> The internal enum jdk.internal.util.Architecture does not provide information > about the big or little endianness or the address size (64 or 32 bits). The > endian-ness and address size are intrinsic to the architecture. > > The values of the enum are extended to separately identify the big

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

2023-06-22 Thread Lance Andersen
On Thu, 22 Jun 2023 18:22:35 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. Marked as reviewed by lancea (Reviewer). - PR Review: https://git.openjdk.org/

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v2]

2023-06-22 Thread Naoto Sato
On Thu, 22 Jun 2023 18:55:31 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

Re: RFR: 8310242: Clarify the name parameter to Class::forName [v8]

2023-06-22 Thread Mandy Chung
On Thu, 22 Jun 2023 17:47:16 GMT, Mandy Chung wrote: >> This PR clarifies the spec of the 3-arg Class::forName regarding the format >> of the name for an array type which is of the form: one or more of "[" + >> binary name of the element type + ";'. > > Mandy Chung has updated the pull request

RFR: 8310241: OffsetDateTime compareTo redundant computation

2023-06-22 Thread Roger Riggs
Remove a redundant comparison in java.time `OffsetDateTime.compareTo()`. If the `compareInstant` utility method returns 0 (equal), it compares the `LocalDateTime`. However, `compareInstant` has already done that comparison; if it found equal, the `compareTo` method unnecessarily does it again. T

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

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 18:43:19 GMT, Lance Andersen 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. > > src/java.base/share/classes/java/lang/Readable.java line 49: > >> 47: * @param cb t

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v2]

2023-06-22 Thread Justin Lu
On Thu, 22 Jun 2023 18:34:26 GMT, Lance Andersen wrote: >> Justin Lu has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Review: Clarify LocaleConstructors.java with comment for each test method > > test/jdk/java/util/Locale/LocaleConstructo

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v2]

2023-06-22 Thread Justin Lu
> 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 be done in separate > PRs. > > If the test had a b

Re: RFR: 8310234: Refactor Locale tests to use JUnit [v2]

2023-06-22 Thread Justin Lu
On Thu, 22 Jun 2023 18:30:55 GMT, Lance Andersen wrote: >> test/jdk/java/util/Locale/LocaleConstructors.java line 51: >> >>> 49: public void langTest() { >>> 50: Locale aLocale = Locale.of(LANG); >>> 51: Locale otherLocale = new Locale(LANG); >> >> Is there a preference on t

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

2023-06-22 Thread Roger Riggs
On Thu, 22 Jun 2023 18:22:35 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. Looks good. - Marked as reviewed by rriggs (Reviewer). PR Review: https://git

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

2023-06-22 Thread Lance Andersen
On Thu, 22 Jun 2023 18:22:35 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. src/java.base/share/classes/java/lang/Readable.java line 49: > 47: * @param cb the buf

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

2023-06-22 Thread Brian Burkhalter
On Thu, 22 Jun 2023 18:22:35 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. CSR will be filed if consensus is reached here. - PR Comment: https://git.open

Re: RFR: 8310234: Refactor Locale tests to use JUnit

2023-06-22 Thread Lance Andersen
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: 8310234: Refactor Locale tests to use JUnit

2023-06-22 Thread Lance Andersen
On Thu, 22 Jun 2023 18:25:24 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

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

2023-06-22 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. - Commit messages: - 8222329: Readable read(CharBuffer) does not specify that 0 is returned when there is no remaining space in buffer Chang

Re: RFR: 8310234: Refactor Locale tests to use JUnit

2023-06-22 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: 8310242: Clarify the name parameter to Class::forName [v8]

2023-06-22 Thread Mandy Chung
> This PR clarifies the spec of the 3-arg Class::forName regarding the format > of the name for an array type which is of the form: one or more of "[" + > binary name of the element type + ";'. Mandy Chung has updated the pull request incrementally with one additional commit since the last rev

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

2023-06-22 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:

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

2023-06-22 Thread Artem Semenov
On Thu, 22 Jun 2023 09:58:49 GMT, Daniel Jeliński wrote: >> Artem Semenov has updated the pull request incrementally with one additional >> commit since the last revision: >> >> update > > make/modules/java.desktop/lib/Awt2dLibraries.gmk line 260: > >> 258: DISABLED_WARNINGS_clang_ai

Re: RFR: 8310242: Clarify the name parameter to Class::forName [v7]

2023-06-22 Thread Chen Liang
On Thu, 22 Jun 2023 16:49:05 GMT, Mandy Chung wrote: >> src/java.base/share/classes/java/lang/Class.java line 426: >> >>> 424: /** >>> 425: * Returns the {@code Class} object associated with the class or >>> 426: * interface with the given string name, using the given class >>> lo

Re: RFR: 8310242: Clarify the name parameter to Class::forName [v7]

2023-06-22 Thread Mandy Chung
On Thu, 22 Jun 2023 00:49:17 GMT, Chen Liang wrote: >> Mandy Chung has updated the pull request incrementally with one additional >> commit since the last revision: >> >> review comments > > src/java.base/share/classes/java/lang/Class.java line 426: > >> 424: /** >> 425: * Returns t

Re: [jdk21] RFR: 8309853: StructuredTaskScope.join description improvements

2023-06-22 Thread Joe Darcy
On Thu, 22 Jun 2023 10:45:02 GMT, Alan Bateman wrote: > 8309853: StructuredTaskScope.join description improvements Marked as reviewed by darcy (Reviewer). - PR Review: https://git.openjdk.org/jdk21/pull/55#pullrequestreview-1493621677

Integrated: JDK-8310453: Update javadoc of java.lang.Object

2023-06-22 Thread Joe Darcy
On Tue, 20 Jun 2023 17:13:26 GMT, Joe Darcy wrote: > I had occasion to read over the javadoc sources in java.lang.Object recently > and noticed a few items that could be updated. > > There are some new or expanded API notes referring to methods in > java.util.Objects. I added these references

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

2023-06-22 Thread Roger Riggs
On Thu, 22 Jun 2023 07:25:34 GMT, 温绍锦 wrote: >> 温绍锦 has updated the pull request incrementally with one additional commit >> since the last revision: >> >> fix compile error > >> I've tested the benchmarks and the patch and baseline (with extra stable >> annotation) with a slightly varied ve

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

2023-06-22 Thread Brian Burkhalter
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: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-22 Thread Daniel Fuchs
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: 8310530: PipedOutputStream.flush() accesses sink racily [v2]

2023-06-22 Thread Brian Burkhalter
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: JDK-8310267: Javadoc for Class#isPrimitive() is incorrect regarding Class objects for primitives

2023-06-22 Thread Pavel Rappo
On Wed, 21 Jun 2023 00:13:24 GMT, Chen Liang wrote: >> Correct misstatement that the Class object for a primitive type can only be >> be access via fields like java.lang.Integer.TYPE. > > src/java.base/share/classes/java/lang/Class.java line 818: > >> 816: * they represent, namely {@code b

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 14:40:23 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 [v9]

2023-06-22 Thread Daniel Jeliński
On Thu, 22 Jun 2023 14:40:23 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 [v9]

2023-06-22 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: 8308780: Fix the Java Integer types on Windows [v8]

2023-06-22 Thread Daniel Jeliński
On Thu, 22 Jun 2023 14:23:25 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-8310502 : Optimization for j.l.Long.fastUUID() [v14]

2023-06-22 Thread Glavo
On Thu, 22 Jun 2023 11:07:09 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: 8308780: Fix the Java Integer types on Windows [v7]

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 14:16:28 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 [v8]

2023-06-22 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: JDK-8310550: Adjust references to rt.jar

2023-06-22 Thread Alan Bateman
On Wed, 21 Jun 2023 15:18:19 GMT, Matthias Baesken wrote: > There are a few references to rt.jar in comments and in the codebase itself. > Some of them might be removed or adjusted. src/java.sql/share/classes/java/sql/DriverManager.java line 658: > 656: * (which is invoking this class

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 14:05:15 GMT, Julian Waters wrote: >> I'm currently running version 13.1, win32 threads > > I'll retry again, maybe the warning has changed now Seems like it doesn't trigger any longer, I'll revert the cast. Thanks for catching this - PR Review Comment: https:/

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

2023-06-22 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: JDK-8310453: Update javadoc of java.lang.Object

2023-06-22 Thread Alan Bateman
On Wed, 21 Jun 2023 17:25:19 GMT, Joe Darcy wrote: >> This method has an existing apiNote and implSpec. I suspect Joe meant to add >> this sentence to the apiNote, not the implSpec. > > I did mean to add the cross-reference to Objects.toIdentityString to the > implSpec section since earlier in

Re: RFR: JDK-8310453: Update javadoc of java.lang.Object

2023-06-22 Thread Alan Bateman
On Tue, 20 Jun 2023 17:13:26 GMT, Joe Darcy wrote: > I had occasion to read over the javadoc sources in java.lang.Object recently > and noticed a few items that could be updated. > > There are some new or expanded API notes referring to methods in > java.util.Objects. I added these references

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

2023-06-22 Thread Daniel Jeliński
On Thu, 22 Jun 2023 13:48:53 GMT, Julian Waters wrote: >> src/jdk.accessibility/windows/native/jaccesswalker/jaccesswalker.cpp line >> 547: >> >>> 545: snprintf( s, sizeof(s), >>> 546: "ERROR calling GetAccessibleContextInfo; vmID = %lX, >>> context = %p", >>> 547:

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 14:03:26 GMT, Daniel Jeliński wrote: >> gcc will crash with a warning about a mismatched format specifier between >> signed and unsigned if this isn't done, unfortunately > > Which gcc? This code compiles without warnings: > > #include > int main() { > unsigned long i

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 14:04:48 GMT, Julian Waters wrote: >> Which gcc? This code compiles without warnings: >> >> #include >> int main() { >> unsigned long i = 1; >> long j = 2; >> printf("%ld %ld %lx %lx %lu %lu\n", i, j, i, j, i, j); >> return 0; >> } >> >> >> # gcc -Wall

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

2023-06-22 Thread Julian Waters
On Thu, 22 Jun 2023 10:37:11 GMT, Daniel Jeliński wrote: >> Julian Waters has refreshed the contents of this pull request, and previous >> commits have been removed. The incremental views will show differences >> compared to the previous content of the PR. The pull request contains one >> new

Re: RFR: 8310242: Clarify the name parameter to Class::forName [v7]

2023-06-22 Thread Alan Bateman
On Thu, 22 Jun 2023 00:33:33 GMT, Mandy Chung wrote: >> This PR clarifies the spec of the 3-arg Class::forName regarding the format >> of the name for an array type which is of the form: one or more of "[" + >> binary name of the element type + ";'. > > Mandy Chung has updated the pull request

Re: RFR: 8308995: Update Network IO JFR events to be static mirror events

2023-06-22 Thread Erik Gahlin
On Thu, 22 Jun 2023 11:53:59 GMT, Daniel Fuchs wrote: > The new code seems to accurately correspond to what the various > `*Instrumentor` classes were doing, so that is good. I agree with Alan that > potential exception that may arise when generating the event are an issue > (e.g. call to getR

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

2023-06-22 Thread Sergey Tsypanov
On Wed, 21 Jun 2023 14:58:35 GMT, Daniel Fuchs wrote: >> On second thought, this is probably not necessary; write to the sink field >> is in another synchronized method, and this method is synchronized already. >> Is the goal here to remove the synchronized on flush? > > Good observation. Remov

  1   2   >