Re: [jdk21] RFR: 8309032: jpackage does not work for module projects unless --module-path is specified

2023-08-31 Thread airsquared
On Thu, 20 Jul 2023 02:34:05 GMT, airsquared wrote: > 8309032: jpackage does not work for module projects unless --module-path is > specified Created openjdk/jdk21u#120. - PR Comment: https://git.openjdk.org/jdk21/pull/140#issuecomment-1702096153

[jdk21] Withdrawn: 8309032: jpackage does not work for module projects unless --module-path is specified

2023-08-31 Thread airsquared
On Thu, 20 Jul 2023 02:34:05 GMT, airsquared wrote: > 8309032: jpackage does not work for module projects unless --module-path is > specified This pull request has been closed without being integrated. - PR: https://git.openjdk.org/jdk21/pull/140

Crash during optimizing exploded image with my patch

2023-08-31 Thread -
Hello, I am trying to create a patch [1] that optimizes forEach for immutable factory collections (from List/Set.of) to see how it compares with constant-folded random access. However, this patch somehow tampers with exploded image optimization and modules during build, and I cannot build this

Integrated: 8314925: ChoiceFormat does not specify IllegalArgumentExceptions

2023-08-31 Thread Justin Lu
On Tue, 29 Aug 2023 16:53:29 GMT, Justin Lu wrote: > Please review this PR and [CSR](https://bugs.openjdk.org/browse/JDK-8315148) > which is a conformance change to specify exceptions in java.text.ChoiceFormat. > > Makes `IllegalArgumentException` apparent for `applyPattern` and >

RFR: 8277954: Replace use of monitors with explicit locks in the JDK LDAP provider implementation

2023-08-31 Thread Aleksei Efimov
The change proposed in this PR improves the behavior of the JDK JNDI/LDAP provider when running in a virtual thread. Currently, when an LDAP operation is performed from a virtual thread context a pinned carrier thread is detected: Thread[#29,ForkJoinPool-1-worker-1,5,CarrierThreads]

Integrated: 6333341: [BI] Doc: java.text.BreakIterator class specification is unclear

2023-08-31 Thread Justin Lu
On Thu, 24 Aug 2023 21:39:39 GMT, Justin Lu wrote: > Please review this PR and [CSR > ](https://bugs.openjdk.org/browse/JDK-8314974)which clarifies behavior for > BreakIterator instances when text has not been set. > > For example, calling `BreakIterator.getWordInstance().next();` has an >

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v33]

2023-08-31 Thread Srinivas Vamsi Parasa
> The goal is to develop faster sort routines for x86_64 CPUs by taking > advantage of AVX512 instructions. This enhancement provides an order of > magnitude speedup for Arrays.sort() using int, long, float and double arrays. > > This PR shows upto ~7x improvement for 32-bit datatypes (int,

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v30]

2023-08-31 Thread Srinivas Vamsi Parasa
On Mon, 28 Aug 2023 23:29:43 GMT, Erik Joelsson wrote: >> Srinivas Vamsi Parasa has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Clean up parameters passed to arrayPartition; update the check to load >> library > >

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v32]

2023-08-31 Thread Srinivas Vamsi Parasa
> The goal is to develop faster sort routines for x86_64 CPUs by taking > advantage of AVX512 instructions. This enhancement provides an order of > magnitude speedup for Arrays.sort() using int, long, float and double arrays. > > This PR shows upto ~7x improvement for 32-bit datatypes (int,

Integrated: 8312521: Unused field LocaleProviderAdapter#defaultLocaleProviderAdapter could be removed

2023-08-31 Thread Andrey Turbanov
On Tue, 22 Aug 2023 12:22:54 GMT, Andrey Turbanov wrote: > After [JDK-8245241](https://bugs.openjdk.org/browse/JDK-8245241), the field > `sun.util.locale.provider.LocaleProviderAdapter#defaultLocaleProviderAdapter` > is only written in `` and then is not used after. > We can remove it. This

Re: RFR: 8310929: Optimization for Integer.toString [v13]

2023-08-31 Thread Claes Redestad
On Tue, 18 Jul 2023 01:49:17 GMT, 温绍锦 wrote: >> Optimization for: >> Integer.toString >> Long.toString >> StringBuilder#append(int) >> >> # Benchmark Result >> >> >> sh make/devkit/createJMHBundle.sh >> bash configure --with-jmh=build/jmh/jars >> make test

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v31]

2023-08-31 Thread Erik Joelsson
On Thu, 31 Aug 2023 18:45:39 GMT, Srinivas Vamsi Parasa wrote: >> The goal is to develop faster sort routines for x86_64 CPUs by taking >> advantage of AVX512 instructions. This enhancement provides an order of >> magnitude speedup for Arrays.sort() using int, long, float and double arrays.

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Alan Bateman
On Thu, 31 Aug 2023 17:31:34 GMT, Patricio Chilano Mateo wrote: >> src/hotspot/share/jfr/periodic/sampling/jfrThreadSampler.cpp line 415: >> >>> 413: } else { >>> 414: assert(NATIVE_SAMPLE == type, "invariant"); >>> 415: if (thread_state_in_native(thread) && >>>

Re: RFR: 5066247: Refine the spec of equals() and hashCode() for j.text.Format classes

2023-08-31 Thread Joe Darcy
On Mon, 28 Aug 2023 21:24:18 GMT, Justin Lu wrote: > Please review this PR which refines the spec of `equals()` and `hashCode()` > in `java.text.Format` related classes. > > The current spec for most of these methods is either "_Overrides > _" or are incomplete/wrong (i.e. see

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v31]

2023-08-31 Thread Srinivas Vamsi Parasa
> The goal is to develop faster sort routines for x86_64 CPUs by taking > advantage of AVX512 instructions. This enhancement provides an order of > magnitude speedup for Arrays.sort() using int, long, float and double arrays. > > This PR shows upto ~7x improvement for 32-bit datatypes (int,

Re: RFR: 8309130: x86_64 AVX512 intrinsics for Arrays.sort methods (int, long, float and double arrays) [v30]

2023-08-31 Thread Srinivas Vamsi Parasa
On Tue, 29 Aug 2023 17:00:33 GMT, Srinivas Vamsi Parasa wrote: >> make/modules/java.base/Lib.gmk line 240: >> >>> 238: >>> 239: ifeq ($(call isTargetOs, linux)+$(call isTargetCpu, >>> x86_64)+$(INCLUDE_COMPILER2), true+true+true) >>> 240: $(eval $(call SetupJdkLibrary, BUILD_LIB_X86_64, \

Re: RFR: 8314085: Fixing scope from benchmark to thread for JMH tests having shared state

2023-08-31 Thread Sandhya Viswanathan
On Thu, 10 Aug 2023 15:30:19 GMT, Swati Sharma wrote: > In addition to the issue > [JDK-8311178](https://bugs.openjdk.org/browse/JDK-8311178), logically fixing > the scope from benchmark to thread for below benchmark files having shared > state, also which fixes few of the benchmarks

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Patricio Chilano Mateo
On Thu, 31 Aug 2023 10:37:26 GMT, Markus Grönlund wrote: >> In the virtual thread implementation, thread identity switches to the >> carrier before freezing and switches back to the virtual thread after >> thawing. This was a forced move due to issues getting JVMTI to work with >> virtual

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Patricio Chilano Mateo
On Wed, 30 Aug 2023 13:56:42 GMT, Alan Bateman wrote: > In the virtual thread implementation, thread identity switches to the carrier > before freezing and switches back to the virtual thread after thawing. This > was a forced move due to issues getting JVMTI to work with virtual threads. >

Re: RFR: 8268829: Provide an optimized way to walk the stack with Class object only [v9]

2023-08-31 Thread Mandy Chung
> 8268829: Provide an optimized way to walk the stack with Class object only > > `StackWalker::walk` creates one `StackFrame` per frame and the current > implementation > allocates one `StackFrameInfo` and one `MemberName` objects per frame. Some > frameworks > like logging may only interest in

Re: RFR: 8313718: make container at requires command configurable [v2]

2023-08-31 Thread Mikhailo Seledtsov
On Wed, 30 Aug 2023 03:25:54 GMT, Mikhailo Seledtsov wrote: >> Container ecosystem is growing. It would be beneficial to define custom >> command to figure out whether a specific test host or environment allows for >> container testing. This enhancement seeks to make the command used by jtreg

Re: RFR: 8313983: jmod create --target-platform should replace existing ModuleTarget attribute

2023-08-31 Thread Mandy Chung
On Thu, 31 Aug 2023 12:13:40 GMT, Adam Sotona wrote: > ModuleTarget and ModuleResolution attributes were flagged as 'allow multiple' > in the Classfile API. > This patch removed the flags and allows at most one instance of each > attribute. > > Please review. > > Thanks, > Adam Would you

Re: RFR: 8313983: jmod create --target-platform should replace existing ModuleTarget attribute

2023-08-31 Thread Mandy Chung
On Thu, 31 Aug 2023 12:13:40 GMT, Adam Sotona wrote: > ModuleTarget and ModuleResolution attributes were flagged as 'allow multiple' > in the Classfile API. > This patch removed the flags and allows at most one instance of each > attribute. > > Please review. > > Thanks, > Adam Marked as

Re: RFR: 8310929: Optimization for Integer.toString [v13]

2023-08-31 Thread Andriy Plokhotnyuk
On Thu, 31 Aug 2023 02:36:09 GMT, 温绍锦 wrote: >> 温绍锦 has updated the pull request incrementally with one additional commit >> since the last revision: >> >> assert bounds check > > @cl4es can you help me to review this PR? @wenshao How about of approach used in James Anhalt's algorithm:

Integrated: 8315383: jlink SystemModulesPlugin incorrectly parses the options

2023-08-31 Thread Oliver Kopp
On Wed, 30 Aug 2023 19:07:53 GMT, Oliver Kopp wrote: > Fixes https://bugs.openjdk.org/browse/JDK-8315383 This pull request has now been integrated. Changeset: ea5aa61c Author:Oliver Kopp Committer: Mandy Chung URL:

Integrated: 8315413: Remove special filtering of Continuation.yield0 in StackWalker

2023-08-31 Thread Mandy Chung
On Wed, 30 Aug 2023 20:57:43 GMT, Mandy Chung wrote: > Loom added a special filtering of Continuation.yield0 in stack walker. After > the initial implementation, JDK-8304919 marks the yielding and entering > methods with `@Hidden` and hidden frames are filtered by stack walker by > default.

Re: RFR: 8312491: Update Classfile API snippets and examples [v10]

2023-08-31 Thread Adam Sotona
On Wed, 30 Aug 2023 12:39:45 GMT, Adam Sotona wrote: >> This pull request updates Classfile API snippets and examples and adds >> missing javadoc. >> >> Please review. >> >> Thanks, >> Adam > > Adam Sotona has updated the pull request incrementally with one additional > commit since the last

Re: RFR: 8313983: jmod create --target-platform should replace existing ModuleTarget attribute

2023-08-31 Thread Alan Bateman
On Thu, 31 Aug 2023 12:13:40 GMT, Adam Sotona wrote: > ModuleTarget and ModuleResolution attributes were flagged as 'allow multiple' > in the Classfile API. > This patch removed the flags and allows at most one instance of each > attribute. > > Please review. > > Thanks, > Adam Thanks for

Re: RFR: 8314094: java/lang/ProcessHandle/InfoTest.java fails on Windows when run as user with Administrator privileges

2023-08-31 Thread Roger Riggs
On Thu, 31 Aug 2023 06:56:06 GMT, Arno Zeller wrote: >> The system environment has the domainname and the username. >> >> String username = (System.getenv("USERDOMAIN") + "/" + >> System.getenv("USERNAME")).toLowerCase(Locale.ROOT); > > The problem with the environment variables is, that jtreg

Re: RFR: 8310929: Optimization for Integer.toString [v13]

2023-08-31 Thread Andrew Haley
On Thu, 31 Aug 2023 14:32:43 GMT, Andrew Haley wrote: > > I'm wondering if a micro benchmark like this is very realistic. > > Exactly so! This is almost the canonical example of the "JMH considered > harmful" talk I gave recently. The subject is a joke! Yes, I love JMH, but be very careful

Re: RFR: 8310929: Optimization for Integer.toString [v13]

2023-08-31 Thread Andrew Haley
On Thu, 31 Aug 2023 14:15:41 GMT, John Hendrikx wrote: > I'm wondering if a micro benchmark like this is very realistic. Exactly so! This is almost the canonical example of the "JMH considered harmful" talk I gave recently. - PR Comment:

Re: RFR: JDK-8266431: Dual-Pivot Quicksort improvements (Radix sort) [v9]

2023-08-31 Thread iaroslavski
On Wed, 30 Aug 2023 10:55:48 GMT, Laurent Bourgès wrote: >> * improved mixed insertion sort (makes whole sorting faster) >> * introduced Radix which sort shows several times boost of performance and >> has linear complexity instead of n*ln(n) >> * improved merging sort for almost sorted data

Re: RFR: 8313258: RuntimeInvisibleTypeAnnotationsAttribute.annotations() API Index out of Bound error

2023-08-31 Thread Chen Liang
On Thu, 31 Aug 2023 11:09:05 GMT, Adam Sotona wrote: > Classfile API suppose to throw IllegalArgumentException in situations where > bytecode offset is out of allowed range. Such situation includes invalid > offset parsed from a TypeAnnotation as well as from other CodeAttribute > attributes.

Re: RFR: 8310929: Optimization for Integer.toString [v13]

2023-08-31 Thread John Hendrikx
On Tue, 18 Jul 2023 01:49:17 GMT, 温绍锦 wrote: >> Optimization for: >> Integer.toString >> Long.toString >> StringBuilder#append(int) >> >> # Benchmark Result >> >> >> sh make/devkit/createJMHBundle.sh >> bash configure --with-jmh=build/jmh/jars >> make test

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Markus Grönlund
On Thu, 31 Aug 2023 11:41:03 GMT, Alan Bateman wrote: >> src/hotspot/share/jfr/periodic/sampling/jfrThreadSampler.cpp line 410: >> >>> 408: } >>> 409: if (JAVA_SAMPLE == type) { >>> 410: if (thread_state_in_java(thread) && >>> !is_vthread_in_transition(thread)) { >> >> I think this

RFR: 8313983: jmod create --target-platform should replace existing ModuleTarget attribute

2023-08-31 Thread Adam Sotona
ModuleTarget and ModuleResolution attributes were flagged as 'allow multiple' in the Classfile API. This patch removed the flags and allows at most one instance of each attribute. Please review. Thanks, Adam - Commit messages: - 8313983: jmod create --target-platform should

Re: RFR: 8311220: Optimization for StringLatin UpperLower [v3]

2023-08-31 Thread Claes Redestad
On Thu, 6 Jul 2023 05:20:14 GMT, 温绍锦 wrote: >> # Benchmark Result >> >> >> sh make/devkit/createJMHBundle.sh >> bash configure --with-jmh=build/jmh/jars >> make test TEST="micro:java.lang.StringUpperLower.*" >> >> >> >> ## 1. >>

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Alan Bateman
On Thu, 31 Aug 2023 10:38:32 GMT, Markus Grönlund wrote: >> In the virtual thread implementation, thread identity switches to the >> carrier before freezing and switches back to the virtual thread after >> thawing. This was a forced move due to issues getting JVMTI to work with >> virtual

RFR: 8313258: RuntimeInvisibleTypeAnnotationsAttribute.annotations() API Index out of Bound error

2023-08-31 Thread Adam Sotona
Classfile API suppose to throw IllegalArgumentException in situations where bytecode offset is out of allowed range. Such situation includes invalid offset parsed from a TypeAnnotation as well as from other CodeAttribute attributes. This patch throws IAE for invalid bytecode offset when

Re: RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Markus Grönlund
On Wed, 30 Aug 2023 13:56:42 GMT, Alan Bateman wrote: > In the virtual thread implementation, thread identity switches to the carrier > before freezing and switches back to the virtual thread after thawing. This > was a forced move due to issues getting JVMTI to work with virtual threads. >

Re: RFR: 8315097: Rename createJavaProcessBuilder [v3]

2023-08-31 Thread Mark Sheppard
On Thu, 31 Aug 2023 05:45:27 GMT, David Holmes wrote: > > So you could create a single createJavaProcessBuilder with add an > > additional parameter boolean addTestOpts e.g. > > createJavaProcessBuilder(List command, boolean addTestOpts) { ... } > > @msheppar that is actually where we started,

Re: RFR: JDK-8314194: Reusing CyclicBarrier, it should be possible to change the barrierCommand

2023-08-31 Thread chenggwang
On Fri, 11 Aug 2023 02:33:05 GMT, chenggwang wrote: > Sorry, my description in Issue JDK-8314194(which I submitted) is ambiguous > and makes you think of Phaser. My intention is that each generation of > CyclicBarrier barrierCommand can change. Let me give you a scenario > For example, the

Re: RFR: 8233160: Add java.vendor.url.bug to list of recognized standard system properties

2023-08-31 Thread Jaikiran Pai
On Thu, 31 Aug 2023 06:53:45 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which proposes to address > https://bugs.openjdk.org/browse/JDK-8233160? > > It has been noted in https://bugs.openjdk.org/browse/JDK-8232753 that: > >> The java.vendor.url.bug property has been

Re: RFR: 8233160: Add java.vendor.url.bug to list of recognized standard system properties

2023-08-31 Thread Alan Bateman
On Thu, 31 Aug 2023 06:53:45 GMT, Jaikiran Pai wrote: > Can I please get a review of this change which proposes to address > https://bugs.openjdk.org/browse/JDK-8233160? > > It has been noted in https://bugs.openjdk.org/browse/JDK-8232753 that: > >> The java.vendor.url.bug property has been

Re: RFR: JDK-8314194: Reusing CyclicBarrier, it should be possible to change the barrierCommand

2023-08-31 Thread Viktor Klang
On Thu, 31 Aug 2023 06:59:29 GMT, David Holmes wrote: >> Sorry, my description in Issue JDK-8314194(which I submitted) is ambiguous >> and makes you think of Phaser. My intention is that each generation of >> CyclicBarrier barrierCommand can change. Let me give you a scenario >> For example,

Re: RFR: 8268829: Provide an optimized way to walk the stack with Class object only [v8]

2023-08-31 Thread Alan Bateman
On Wed, 30 Aug 2023 16:29:31 GMT, Mandy Chung wrote: > Indeed, Set.of factory methods are easy to use. I'm okay with taking it out. It would be easy to add in the future if needed, say if more options were introduced and the common case requires 2 or more options. - PR Comment:

RFR: 8315373: Change VirtualThread to unmount after freezing, re-mount before thawing

2023-08-31 Thread Alan Bateman
In the virtual thread implementation, thread identity switches to the carrier before freezing and switches back to the virtual thread after thawing. This was a forced move due to issues getting JVMTI to work with virtual threads. JVMTI can now hide events during transitions so we can invert the

Re: RFR: JDK-8314194: Reusing CyclicBarrier, it should be possible to change the barrierCommand

2023-08-31 Thread David Holmes
On Fri, 11 Aug 2023 02:33:05 GMT, chenggwang wrote: > Sorry, my description in Issue JDK-8314194(which I submitted) is ambiguous > and makes you think of Phaser. My intention is that each generation of > CyclicBarrier barrierCommand can change. Let me give you a scenario > For example, the

RFR: 8233160: Add java.vendor.url.bug to list of recognized standard system properties

2023-08-31 Thread Jaikiran Pai
Can I please get a review of this change which proposes to address https://bugs.openjdk.org/browse/JDK-8233160? It has been noted in https://bugs.openjdk.org/browse/JDK-8232753 that: > The java.vendor.url.bug property has been defined by every Sun/Oracle JDK > going all the way back to JDK 5

Re: RFR: 8314094: java/lang/ProcessHandle/InfoTest.java fails on Windows when run as user with Administrator privileges

2023-08-31 Thread Arno Zeller
On Wed, 30 Aug 2023 15:58:37 GMT, Roger Riggs wrote: >> Yes, I think using System.getProperty("user.name") is brittle as well. If >> we'd use `com.sun.security.auth.module.NTSystem`, we would introduce the >> dependency to another module - `jdk.security.auth`. Not sure, whether this >> is a

Re: RFR: 8315097: Rename createJavaProcessBuilder [v3]

2023-08-31 Thread Alan Bateman
On Wed, 30 Aug 2023 17:38:01 GMT, Stefan Karlsson wrote: > I wouldn't be opposed to a change that: > > * Keeps the `createJavaProcessBuilder` name > * Renames `createTestJvm` to `createJavaProcessBuilderPrependTestOpts` > * Renames `executeTestJvm` to `executeJavaPrependTestOpts` > * Removes

Re: RFR: 8315413: Remove special filtering of Continuation.yield0 in StackWalker

2023-08-31 Thread Alan Bateman
On Wed, 30 Aug 2023 20:57:43 GMT, Mandy Chung wrote: > Loom added a special filtering of Continuation.yield0 in stack walker. After > the initial implementation, JDK-8304919 marks the yielding and entering > methods with `@Hidden` and hidden frames are filtered by stack walker by > default.

Withdrawn: 8315351: Rid synchronization in PipedInputStream.close() in favour of benign race

2023-08-31 Thread Sergey Tsypanov
On Wed, 30 Aug 2023 09:49:39 GMT, Sergey Tsypanov wrote: > Assuming that the value written into `in` is always `-1` we can rid > synchronized block in favour of guarding `in = - 1` with writing into > volatile `closedByReader `: > > public void close() throws IOException { >