Re: RFR: 8272600: (test) Use native "sleep" in Basic.java [v3]

2021-09-02 Thread David Holmes
On 3/09/2021 12:45 am, Roger Riggs wrote: On Sat, 28 Aug 2021 02:34:48 GMT, Roger Riggs wrote: The intermittent test in java/lang/ProcessBuilder/Basic.java has identified unexpected messages from a child Java VM as the cause of the test failure. Attempts to control the output of the child

Re: better random numbers

2021-09-02 Thread John Rose
On Sep 2, 2021, at 4:35 PM, John Rose mailto:john.r.r...@oracle.com>> wrote: The state of the art for PRNGs (pseudo-random number generators) is much advanced since ju.Random was written. Surely at some point we will refresh our APIs that produce random numbers. In fact, we have added

Integrated: 8214761: Bug in parallel Kahan summation implementation

2021-09-02 Thread Ian Graves
On Fri, 2 Jul 2021 20:12:39 GMT, Ian Graves wrote: > 8214761: Bug in parallel Kahan summation implementation This pull request has now been integrated. Changeset: dd871819 Author:Ian Graves URL: https://git.openjdk.java.net/jdk/commit/dd871819a05886ee09fc00c7c778268440ebedb7 Stats:

Re: RFR: 8078641: MethodHandle.asTypeCache can retain classes from unloading [v3]

2021-09-02 Thread Mandy Chung
On Thu, 2 Sep 2021 11:35:52 GMT, Vladimir Ivanov wrote: >> `MethodHandle.asTypeCache` keeps a strong reference to adapted >> `MethodHandle` and it can introduce a class loader leak through its >> `MethodType`. >> >> Proposed fix introduces a 2-level cache (1 element each) where 1st level can

better random numbers

2021-09-02 Thread John Rose
The state of the art for PRNGs (pseudo-random number generators) is much advanced since ju.Random was written. Surely at some point we will refresh our APIs that produce random numbers. In fact, we have added SplittableRandom, but I think the state of the art is farther enough along to consider

Re: RFR: 8273259: Character.getName doesn't follow Unicode spec for ideographs

2021-09-02 Thread Iris Clark
On Thu, 2 Sep 2021 19:26:12 GMT, Naoto Sato wrote: > Simple spec clarification. A CSR has also been drafted > (https://bugs.openjdk.java.net/browse/JDK-8273296). Associated CSR also "Reviewed". - Marked as reviewed by iris (Reviewer). PR:

Re: RFR: 8273259: Character.getName doesn't follow Unicode spec for ideographs

2021-09-02 Thread Lance Andersen
On Thu, 2 Sep 2021 19:26:12 GMT, Naoto Sato wrote: > Simple spec clarification. A CSR has also been drafted > (https://bugs.openjdk.java.net/browse/JDK-8273296). Marked as reviewed by lancea (Reviewer). - PR: https://git.openjdk.java.net/jdk/pull/5354

Re: RFR: 8273259: Character.getName doesn't follow Unicode spec for ideographs

2021-09-02 Thread Brian Burkhalter
On Thu, 2 Sep 2021 19:26:12 GMT, Naoto Sato wrote: > Simple spec clarification. A CSR has also been drafted > (https://bugs.openjdk.java.net/browse/JDK-8273296). Marked as reviewed by bpb (Reviewer). - PR: https://git.openjdk.java.net/jdk/pull/5354

RFR: 8273259: Character.getName doesn't follow Unicode spec for ideographs

2021-09-02 Thread Naoto Sato
Simple spec clarification. A CSR has also been drafted (https://bugs.openjdk.java.net/browse/JDK-8273296). - Commit messages: - 8273259: Character.getName doesn't follow Unicode spec for ideographs Changes: https://git.openjdk.java.net/jdk/pull/5354/files Webrev:

Re: RFR: JDK-8273194: Document the two possible cases when Lookup::ensureInitialized returns [v2]

2021-09-02 Thread Mandy Chung
> Improve the specification to document the cases when > `Lookup::ensureInitialized` returns as specified JVMS 5.5 and matches the > implementation. > > Please also review CSR: https://bugs.openjdk.java.net/browse/JDK-8273253 Mandy Chung has updated the pull request incrementally with one

Re: RFR: JDK-8273194: Document the two possible cases when Lookup::ensureInitialized returns [v2]

2021-09-02 Thread Mandy Chung
On Thu, 2 Sep 2021 14:00:03 GMT, Alan Bateman wrote: >> Mandy Chung has updated the pull request incrementally with one additional >> commit since the last revision: >> >> review comment > > src/java.base/share/classes/java/lang/invoke/MethodHandles.java line 2787: > >> 2785: *

Re: RFR: JDK-8273194: Document the two possible cases when Lookup::ensureInitialized returns [v2]

2021-09-02 Thread Alan Bateman
On Thu, 2 Sep 2021 16:18:03 GMT, Mandy Chung wrote: >> Improve the specification to document the cases when >> `Lookup::ensureInitialized` returns as specified JVMS 5.5 and matches the >> implementation. >> >> Please also review CSR: https://bugs.openjdk.java.net/browse/JDK-8273253 > > Mandy

Integrated: 8273250: Address javadoc issues in Deflater::setDictionationary

2021-09-02 Thread Lance Andersen
On Wed, 1 Sep 2021 19:26:17 GMT, Lance Andersen wrote: > Hi, > > Please review this trivial fix to the javadoc which addresses an issue shown > via Intellij where the error: "Symbol 'getAdler' is inaccessible from here" > is generated for the "@See Inflater#getAlder" references. > > Best >

Re: RFR: 8273261: Replace 'while' cycles with iterator with enhanced-for in java.base

2021-09-02 Thread Iris Clark
On Wed, 1 Sep 2021 07:37:53 GMT, Andrey Turbanov wrote: > There are few places in code where manual while loop is used with Iterator to > iterate over Collection. > Instead of manual while cycles it's preferred to use enhanced-for cycle > instead: it's less verbose, makes code easier to read

Re: RFR: 8272600: (test) Use native "sleep" in Basic.java [v3]

2021-09-02 Thread Roger Riggs
On Sat, 28 Aug 2021 02:34:48 GMT, Roger Riggs wrote: >> The intermittent test in java/lang/ProcessBuilder/Basic.java has identified >> unexpected messages from a child Java VM >> as the cause of the test failure. Attempts to control the output of the >> child VM have failed, the VM is

Re: RFR: 8273111: Default timezone should return zone ID if /etc/localtime is valid but not canonicalization on linux

2021-09-02 Thread Wu Yan
On Wed, 1 Sep 2021 12:38:38 GMT, Alan Bateman wrote: > I haven't come across this configuration like but changing it to use realpath > seem reasonable. Thanks, this scenario comes from our customers. > Using `realpath` instead of `readlink` will change results on systems which > use symbolic

Re: RFR: JDK-8273194: Document the two possible cases when Lookup::ensureInitialized returns

2021-09-02 Thread Alan Bateman
On Wed, 1 Sep 2021 20:56:59 GMT, Mandy Chung wrote: > Improve the specification to document the cases when > `Lookup::ensureInitialized` returns as specified JVMS 5.5 and matches the > implementation. > > Please also review CSR: https://bugs.openjdk.java.net/browse/JDK-8273253

Re: RFR: 8273111: Default timezone should return zone ID if /etc/localtime is valid but not canonicalization on linux

2021-09-02 Thread Wu Yan
On Wed, 1 Sep 2021 12:51:15 GMT, Florian Weimer wrote: >> Hi, >> Please help me review the change to enhance getting time zone ID from >> /etc/localtime on linux. >> >> We use `realpath` instead of `readlink` to obtain the link name of >> /etc/localtime, because `readlink` can only read the

Re: RFR: 8272600: (test) Use native "sleep" in Basic.java [v3]

2021-09-02 Thread Roger Riggs
On Sat, 28 Aug 2021 02:34:48 GMT, Roger Riggs wrote: >> The intermittent test in java/lang/ProcessBuilder/Basic.java has identified >> unexpected messages from a child Java VM >> as the cause of the test failure. Attempts to control the output of the >> child VM have failed, the VM is

Re: RFR: 8273261: Replace 'while' cycles with iterator with enhanced-for in java.base

2021-09-02 Thread Roger Riggs
On Wed, 1 Sep 2021 07:37:53 GMT, Andrey Turbanov wrote: > There are few places in code where manual while loop is used with Iterator to > iterate over Collection. > Instead of manual while cycles it's preferred to use enhanced-for cycle > instead: it's less verbose, makes code easier to read

Re: RFR: 6957241: ClassLoader.getResources() returns only 1 instance when using jar indexing

2021-09-02 Thread Alan Bateman
On Tue, 31 Aug 2021 12:11:46 GMT, wxiang wrote: > Using jarIndex for Hibench, there is an unexpected behavior with the > exception "Exception in thread "main" > org.apache.hadoop.fs.UnsupportedFileSystemException: No FileSystem for scheme > "hdfs"". > > After investigating it, it is related

Re: RFR: 8273000: Remove WeakReference-based class initialisation barrier implementation [v2]

2021-09-02 Thread Vladimir Ivanov
On Thu, 2 Sep 2021 05:08:38 GMT, David Holmes wrote: >> src/java.base/share/classes/jdk/internal/misc/Unsafe.java line 1152: >> >>> 1150: * The call returns when either class {@code c} is fully >>> initialized or >>> 1151: * class {@code c} is being initialized and the call is

Re: RFR: 8273000: Remove WeakReference-based class initialisation barrier implementation [v3]

2021-09-02 Thread Vladimir Ivanov
> Get rid of WeakReference-based logic in > DirectMethodHandle::checkInitialized() and reimplement it with > `Unsafe::ensureClassInitialized()`/`shouldBeInitialized()`. > > The key observation is that `Unsafe::ensureClassInitialized()` does not block > the initializing thread. > > Also,

Re: RFR: 8078641: MethodHandle.asTypeCache can retain classes from unloading [v2]

2021-09-02 Thread Vladimir Ivanov
On Wed, 1 Sep 2021 17:28:37 GMT, Mandy Chung wrote: >> Vladimir Ivanov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Address review comments > > src/java.base/share/classes/java/lang/invoke/MethodHandle.java line 926: > >> 924:

Re: RFR: 8078641: MethodHandle.asTypeCache can retain classes from unloading [v3]

2021-09-02 Thread Vladimir Ivanov
> `MethodHandle.asTypeCache` keeps a strong reference to adapted `MethodHandle` > and it can introduce a class loader leak through its `MethodType`. > > Proposed fix introduces a 2-level cache (1 element each) where 1st level can > only contain `MethodHandle`s which are guaranteed to not

Integrated: JDK-8273229: Update OS detection code to recognize Windows Server 2022

2021-09-02 Thread Matthias Baesken
On Thu, 2 Sep 2021 06:43:16 GMT, Matthias Baesken wrote: > Hello, please review this small change. > The OS detection code of the JDK/JVM should recognize the new Windows server > 2022 : > > https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 >

Re: RFR: 8273261: Replace 'while' cycles with iterator with enhanced-for in java.base

2021-09-02 Thread Daniel Fuchs
On Wed, 1 Sep 2021 07:37:53 GMT, Andrey Turbanov wrote: > There are few places in code where manual while loop is used with Iterator to > iterate over Collection. > Instead of manual while cycles it's preferred to use enhanced-for cycle > instead: it's less verbose, makes code easier to read

Re: RFR: 8247980: Exclusive execution of java/util/stream tests slows down tier1

2021-09-02 Thread Aleksey Shipilev
On Tue, 24 Aug 2021 13:18:21 GMT, Christoph Langer wrote: > I have added this to our internal testing, let's see how it goes. Notifying > @ArnoZeller about this. Any good or bad results? - PR: https://git.openjdk.java.net/jdk/pull/5189

Re: RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022 [v2]

2021-09-02 Thread David Holmes
On Thu, 2 Sep 2021 08:16:52 GMT, Matthias Baesken wrote: >> Hello, please review this small change. >> The OS detection code of the JDK/JVM should recognize the new Windows server >> 2022 : >> >> https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 >>

RFR: 8273101: Eliminate the usage of threadgroup sandboxing in the java.util.logging

2021-09-02 Thread Sergey Bylokhov
The "java.util.logging.LogManager" class uses the "threadgroup sandboxing" via an AppContext to support "applet logging isolation". The AppContext class became useless since the plugin and webstart are no longer supported and removed in jdk11. This is the request to delete the usage of

Re: RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022 [v2]

2021-09-02 Thread Matthias Baesken
On Thu, 2 Sep 2021 07:49:55 GMT, David Holmes wrote: >> Matthias Baesken has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Adjust comments > > src/hotspot/os/windows/os_windows.cpp line 1871: > >> 1869: // distinguish Windows

Re: RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022 [v2]

2021-09-02 Thread Matthias Baesken
> Hello, please review this small change. > The OS detection code of the JDK/JVM should recognize the new Windows server > 2022 : > > https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 > https://docs.microsoft.com/en-us/windows-server/get-started/windows-server-release-info

Integrated: 8273140: Replace usages of Enum.class.getEnumConstants() with Enum.values() where possible

2021-09-02 Thread Сергей Цыпанов
On Mon, 30 Aug 2021 14:26:56 GMT, Сергей Цыпанов wrote: > Just a very tiny clean-up. > > There are some places in JDK code base where we call > `Enum.class.getEnumConstants()` to get all the values of the referenced > `enum`. This is excessive, less-readable and slower than just calling >

Re: RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022

2021-09-02 Thread David Holmes
On Thu, 2 Sep 2021 06:43:16 GMT, Matthias Baesken wrote: > Hello, please review this small change. > The OS detection code of the JDK/JVM should recognize the new Windows server > 2022 : > > https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 >

Re: RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022

2021-09-02 Thread Alan Bateman
On Thu, 2 Sep 2021 06:43:16 GMT, Matthias Baesken wrote: > Hello, please review this small change. > The OS detection code of the JDK/JVM should recognize the new Windows server > 2022 : > > https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 >

Re: RFR: 8273261: Replace 'while' cycles with iterator with enhanced-for in java.base

2021-09-02 Thread Andrey Turbanov
On Wed, 1 Sep 2021 07:37:53 GMT, Andrey Turbanov wrote: > There are few places in code where manual while loop is used with Iterator to > iterate over Collection. > Instead of manual while cycles it's preferred to use enhanced-for cycle > instead: it's less verbose, makes code easier to read

RFR: 8273261: Replace 'while' cycles with iterator with enhanced-for in java.base

2021-09-02 Thread Andrey Turbanov
There are few places in code where manual while loop is used with Iterator to iterate over Collection. Instead of manual while cycles it's preferred to use enhanced-for cycle instead: it's less verbose, makes code easier to read and it's less error-prone. It doesn't have any performance impact:

RFR: JDK-8273229: Update OS detection code to recognize Windows Server 2022

2021-09-02 Thread Matthias Baesken
Hello, please review this small change. The OS detection code of the JDK/JVM should recognize the new Windows server 2022 : https://docs.microsoft.com/en-us/lifecycle/products/windows-server-2022 https://docs.microsoft.com/en-us/windows-server/get-started/windows-server-release-info The build