RFR: 8309408: Thread.sleep cleanup

2023-06-04 Thread Alan Bateman
Thread.sleep has had quite a bit of churn recently to support virtual threads, add sleep(Duration), a JFR event, and the change the underlying implementation to support sub-millis precision. I think the changes have settled down now so we can do some small cleanups that came up in PR discussions

Re: RFR: JDK-8295071: Spec Clarification : ClassFileFormatVersion: System property java.class.version | Java class format version number

2023-06-04 Thread Alan Bateman
On Mon, 5 Jun 2023 01:11:54 GMT, Joe Darcy wrote: > Document existing behavior. > > Please also review the CSR https://bugs.openjdk.org/browse/JDK-8309415 src/java.base/share/classes/java/lang/System.java line 758: > 756: * Greatest Java class file format version recognized by the >

RFR: JDK-8295071: Spec Clarification : ClassFileFormatVersion: System property java.class.version | Java class format version number

2023-06-04 Thread Joe Darcy
Document existing behavior. Please also review the CSR https://bugs.openjdk.org/browse/JDK-8309415 - Commit messages: - JDK-8309415: Spec Clarification : ClassFileFormatVersion: System property java.class.version | Java class format version number Changes: https://git.openjdk.org/

Re: RFR: 8309413: General improvements to MethodTypeDesc implementation [v4]

2023-06-04 Thread Chen Liang
On Fri, 26 May 2023 20:41:36 GMT, Mandy Chung wrote: >> Chen Liang has refreshed the contents of this pull request, and previous >> commits have been removed. Incremental views are not available. > > The microbenchmark shows the performance of using the `MethodTypeDesc` > factory methods. With

Re: RFR: 8309413: General improvements to MethodTypeDesc implementation [v5]

2023-06-04 Thread Chen Liang
> This patch aims to improve the performance of MethodTypeDesc in general, as > it is currently a performance bottleneck in the Classfile API. A previous > revision changed the parameter storage from an array to a list; this is > dropped now. Sorry for the force push. > > > Benchmark

Re: RFR: 8291065: Creating a VarHandle for a static field triggers class initialization [v8]

2023-06-04 Thread Chen Liang
On Sun, 4 Jun 2023 16:12:46 GMT, ExE Boss wrote: >> Chen Liang has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Improve subsequent VH call performance, thanks exeboss > > src/java.base/share/classes/java/lang/invoke/LazyInitializingVarHan

Integrated: 8309334: ProcessTools.main() does not properly set thread names when using the virtual thread wrapper

2023-06-04 Thread Chris Plummer
On Fri, 2 Jun 2023 21:30:46 GMT, Chris Plummer wrote: > Normally when a virtual thread wrapper is used to run a test, the main thread > is renamed to "old-m-a-i-n" and the new virtual thread that will act as the > main thread is named "main". Neither is being done by `ProcessTools.main()`. > T

Re: RFR: 8309334: ProcessTools.main() does not properly set thread names when using the virtual thread wrapper [v3]

2023-06-04 Thread Chris Plummer
On Sat, 3 Jun 2023 21:34:16 GMT, Chris Plummer wrote: >> Normally when a virtual thread wrapper is used to run a test, the main >> thread is renamed to "old-m-a-i-n" and the new virtual thread that will act >> as the main thread is named "main". Neither is being done by >> `ProcessTools.main()

Re: RFR: 8291065: Creating a VarHandle for a static field triggers class initialization [v8]

2023-06-04 Thread ExE Boss
On Sun, 4 Jun 2023 13:23:46 GMT, Chen Liang wrote: >> Also fixed the bug with NPE in `IndirectVarHandle::isAccessModeSupported`. >> >> A few implementation-detail methods in VarHandle are now documented with the >> implied constraints to avoid subtle problems in the future. Changed >> `Indirec

Re: RFR: 8291065: Creating a VarHandle for a static field triggers class initialization [v8]

2023-06-04 Thread Chen Liang
> Also fixed the bug with NPE in `IndirectVarHandle::isAccessModeSupported`. > > A few implementation-detail methods in VarHandle are now documented with the > implied constraints to avoid subtle problems in the future. Changed > `IndirectVarHandle` to call `asDirect` lazily to accomodate the la

Re: RFR: 8291065: Creating a VarHandle for a static field triggers class initialization [v7]

2023-06-04 Thread Chen Liang
On Sat, 3 Jun 2023 03:47:40 GMT, Chen Liang wrote: >> src/java.base/share/classes/java/lang/invoke/LazyInitializingVarHandle.java >> line 106: >> >>> 104: UNSAFE.ensureClassInitialized(refc); >>> 105: this.initialized = true; >>> 106: } >> >> This should probably have a fas

Re: RFR: 8309334: ProcessTools.main() does not properly set thread names when using the virtual thread wrapper [v3]

2023-06-04 Thread Alan Bateman
On Sat, 3 Jun 2023 21:34:16 GMT, Chris Plummer wrote: >> Normally when a virtual thread wrapper is used to run a test, the main >> thread is renamed to "old-m-a-i-n" and the new virtual thread that will act >> as the main thread is named "main". Neither is being done by >> `ProcessTools.main()