Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread Leonid Mesnik
On Fri, 24 Mar 2023 06:31:14 GMT, Leonid Mesnik wrote: >> The TestScaffold incorrectly parse options, it should insert wrapper class >> between VM options and applications classame. > > Leonid Mesnik has updated the pull request incrementally with one additional > commit since the last

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread David Holmes
On Fri, 24 Mar 2023 06:31:14 GMT, Leonid Mesnik wrote: >> The TestScaffold incorrectly parse options, it should insert wrapper class >> between VM options and applications classame. > > Leonid Mesnik has updated the pull request incrementally with one additional > commit since the last

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread Leonid Mesnik
On Tue, 28 Mar 2023 04:27:40 GMT, David Holmes wrote: >> the @run line contains only the test name and additional command-line >> options if needed, the target app class 'Frames2Targ' is not included. I >> have copy-pasted this example from >>

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread David Holmes
On Mon, 27 Mar 2023 18:25:52 GMT, Leonid Mesnik wrote: > > Isn't the `-Xss4M` supposed to be passed as `-J-Xss4M`? That is what the > > original logic is expecting. > > I haven't seen that -J-.. is used here in the args, all tests just use vm > flags directly. I am not sure if updating tests

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread David Holmes
On Mon, 27 Mar 2023 18:02:05 GMT, Leonid Mesnik wrote: >> In that case did you mean: >> >> '@run driver Frames2Test -Xss4M Frames2Targ' >> >> ? > > the @run line contains only the test name and additional command-line options > if needed, the target app class 'Frames2Targ' is not included. I

Re: RFR: 8304725: AsyncGetCallTrace can cause SIGBUS on M1 [v4]

2023-03-27 Thread David Holmes
On Fri, 24 Mar 2023 10:35:36 GMT, Johannes Bechberger wrote: >> Fixes the issue by transitioning the thread into the WXWrite mode while >> walking the stack in AsyncGetCallTrace. >> >> Tested on my M1 mac. > > Johannes Bechberger has updated the pull request incrementally with two >

Integrated: 8304543: Modernize debugging jvm args in test/hotspot/jtreg/vmTestbase/nsk/jdi/Argument/value/value004.java

2023-03-27 Thread Eirik Bjorsnos
On Mon, 20 Mar 2023 19:47:10 GMT, Eirik Bjorsnos wrote: > Please review this PR which replaces the use of outdated JVM flags for > setting up debugging in the test value004.java > > This is part of an ongoing effort to remove use of the outdated flag > '-Djava.compiler" such that the option

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Dean Long
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Gregg Wonderly
On Mar 27, 2023, at 11:30 AM, Andrew Dinn wrote: > If this is pushed in jdk21 then anyone currently developing or upgrading an > app to target jdk21 will only have been able to test on jdk17-jdk20 where > they will not encounter the issue. So, his nly leaves them a small window to > detect

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Dean Long
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread David Holmes
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8301995: Move invokedynamic resolution information out of ConstantPoolCacheEntry [v14]

2023-03-27 Thread Fei Yang
On Mon, 27 Mar 2023 14:43:04 GMT, Matias Saavedra Silva wrote: >> The current structure used to store the resolution information for >> invokedynamic, ConstantPoolCacheEntry, is difficult to interpret due to its >> ambigious fields f1 and f2. This structure can hold information for fields,

Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v5]

2023-03-27 Thread Serguei Spitsyn
On Fri, 24 Mar 2023 02:00:57 GMT, Serguei Spitsyn wrote: >> src/hotspot/share/prims/jvmtiEnvBase.cpp line 1581: >> >>> 1579: return false; >>> 1580: } >>> 1581: if (JvmtiVTMSTransitionDisabler::VTMS_notify_jvmti_events()) { >> >> shouldn't be >> if

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread David Holmes
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Dean Long
On Fri, 24 Mar 2023 06:15:31 GMT, David Holmes wrote: >> Roman Kennke has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge remote-tracking branch 'origin/JDK-8291555-v2' into JDK-8291555-v2 >> - Set condition flags correctly after

Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v5]

2023-03-27 Thread Serguei Spitsyn
On Fri, 24 Mar 2023 19:13:39 GMT, Chris Plummer wrote: >> It is needed to balance enabling/disabling notifyJvmti mode with the >> ThreadStart/VirtualThreadStart events. >> Otherwise, many mode switches can be observed without any events which is >> not interesting. >> We need to allow virtual

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Dean Long
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8297286: runtime/vthread tests crashing after JDK-8296324 [v5]

2023-03-27 Thread Serguei Spitsyn
On Fri, 24 Mar 2023 19:09:57 GMT, Chris Plummer wrote: >> It is for yielding. Do you think we need this with a bigger frequency? > > I guess the question then is why the need to yield. It just seems a bit odd > that I thought the main point of this loop was to keep busy calling >

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Dean Long
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Dean Long
On Mon, 27 Mar 2023 20:24:14 GMT, Roman Kennke wrote: >> This change adds a fast-locking scheme as an alternative to the current >> stack-locking implementation. It retains the advantages of stack-locking >> (namely fast locking in uncontended code-paths), while avoiding the overload >> of

Re: RFR: 8304436: com/sun/jdi/ThreadMemoryLeakTest.java fails with "OutOfMemoryError: Java heap space" with ZGC [v2]

2023-03-27 Thread Leonid Mesnik
On Tue, 21 Mar 2023 22:38:18 GMT, Chris Plummer wrote: >> There are two GC related issues with this test that are being addressed. The >> test was limiting the heap size to 6m so if there is still a leak, it will >> be detected quickly. This proved to be too small of a size when using ZGC. >>

Re: RFR: 8291555: Implement alternative fast-locking scheme [v30]

2023-03-27 Thread Roman Kennke
> This change adds a fast-locking scheme as an alternative to the current > stack-locking implementation. It retains the advantages of stack-locking > (namely fast locking in uncontended code-paths), while avoiding the overload > of the mark word. That overloading causes massive problems with

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Erik Österlund
On Mon, 27 Mar 2023 18:47:31 GMT, Roman Kennke wrote: > > > > > > @rkennke Question about ZGC and LockStack::contains(): how does > > > > > > this work with colored pointers? Don't we have to mask the color > > > > > > bits out somehow when comparing? E.g. using `ZAddress::offset()` ? > > > >

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Roman Kennke
On Mon, 27 Mar 2023 17:30:03 GMT, Roman Kennke wrote: >>> @rkennke Question about ZGC and LockStack::contains(): how does this work >>> with colored pointers? Don't we have to mask the color bits out somehow >>> when comparing? E.g. using `ZAddress::offset()` ? >> >> That would be a question

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread Leonid Mesnik
On Mon, 27 Mar 2023 05:55:52 GMT, David Holmes wrote: > Isn't the `-Xss4M` supposed to be passed as `-J-Xss4M`? That is what the > original logic is expecting. I haven't seen that -J-.. is used here in the args, all tests just use vm flags directly. I am not sure if updating tests is the

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Roman Kennke
On Fri, 24 Mar 2023 06:39:18 GMT, David Holmes wrote: >> Roman Kennke has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge remote-tracking branch 'origin/JDK-8291555-v2' into JDK-8291555-v2 >> - Set condition flags correctly after

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Erik Österlund
On Mon, 27 Mar 2023 17:30:03 GMT, Roman Kennke wrote: > > > > @rkennke Question about ZGC and LockStack::contains(): how does this > > > > work with colored pointers? Don't we have to mask the color bits out > > > > somehow when comparing? E.g. using `ZAddress::offset()` ? > > > > > > > >

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread Leonid Mesnik
On Mon, 27 Mar 2023 05:51:11 GMT, David Holmes wrote: >> Frames2Test is the name of test that uses additional command-line options. >> It is an example. > > In that case did you mean: > > '@run driver Frames2Test -Xss4M Frames2Targ' > > ? the @run line contains only the test name and

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Roman Kennke
On Fri, 24 Mar 2023 06:16:14 GMT, David Holmes wrote: >> Roman Kennke has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge remote-tracking branch 'origin/JDK-8291555-v2' into JDK-8291555-v2 >> - Set condition flags correctly after

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Erik Österlund
On Mon, 27 Mar 2023 15:53:47 GMT, Roman Kennke wrote: > > @rkennke Question about ZGC and LockStack::contains(): how does this work > > with colored pointers? Don't we have to mask the color bits out somehow > > when comparing? E.g. using `ZAddress::offset()` ? > > > > That would be a

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Roman Kennke
On Mon, 27 Mar 2023 15:53:47 GMT, Roman Kennke wrote: >> Is anybody familiar with the academic literature on this topic? I am sure I >> am not the first person which has come up with this form of locking. Maybe >> we could use a name that refers to some academic paper? > >> @rkennke Question

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Andrew Dinn
Hi Ron, Thanks for the reply, I believe we have established a lot of common ground here. I'll try to clarify a couple of the things you found difficult to follow. On 27/03/2023 11:32, Ron Pressler wrote: - A second, related concern is that flipping the default for this configuration in

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Andrew Dinn
Sorry, let me correct some of my mangled grammar On 27/03/2023 17:06, Andrew Dinn wrote: On 27/03/2023 13:37, Volker Simonis wrote: The JEP itself is rather ambitious because I noticed that most of the strong encapsulation JEPs lacked a substantial motivation section (largely because they had

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Andrew Dinn
On 27/03/2023 13:37, Volker Simonis wrote: The JEP itself is rather ambitious because I noticed that most of the strong encapsulation JEPs lacked a substantial motivation section (largely because they had been written before that became the norm) and so strong encapsulation has not been

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Roman Kennke
On Thu, 23 Mar 2023 16:32:57 GMT, Roman Kennke wrote: >> Roman Kennke has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge remote-tracking branch 'origin/JDK-8291555-v2' into JDK-8291555-v2 >> - Set condition flags correctly after

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Thomas Stuefe
On Thu, 23 Mar 2023 16:32:57 GMT, Roman Kennke wrote: >> Roman Kennke has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Merge remote-tracking branch 'origin/JDK-8291555-v2' into JDK-8291555-v2 >> - Set condition flags correctly after

Re: RFR: 8301995: Move invokedynamic resolution information out of ConstantPoolCacheEntry [v14]

2023-03-27 Thread Matias Saavedra Silva
> The current structure used to store the resolution information for > invokedynamic, ConstantPoolCacheEntry, is difficult to interpret due to its > ambigious fields f1 and f2. This structure can hold information for fields, > methods, and invokedynamics and each of its fields can hold

Integrated: 8304547: Remove checking of -Djava.compiler in src/jdk.jdi/share/classes/com/sun/tools/jdi/SunCommandLineLauncher.java

2023-03-27 Thread Eirik Bjorsnos
On Mon, 20 Mar 2023 20:53:41 GMT, Eirik Bjorsnos wrote: > Please review this PR which removes the following outdated guard/check from > SunCommandLineLauncher: > > > if ((options.indexOf("-Djava.compiler=") != -1) && > (options.toLowerCase().indexOf("-djava.compiler=none") == -1)) { >

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Volker Simonis
On Mon, Mar 27, 2023 at 12:32 PM Ron Pressler wrote: > > Hi Andrew! > > > On 24 Mar 2023, at 17:21, Andrew Dinn wrote: > > > > Hi Ron, > > > > Thank you for providing a heads up on the proposed JEP. The Red Hat Java > > team have been discussing this proposal. We have reviewed the original > >

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Ron Pressler
> On 25 Mar 2023, at 19:56, Gregg G Wonderly wrote: > > I understand you may have personal experiences with how you use Java. In my > experience and others, Java has constantly had fundamental breakage in > various details due to lack of understanding, on the platform development > team(s)

Re: [External] : Re: Disallowing the dynamic loading of agents by default

2023-03-27 Thread Ron Pressler
Hi Andrew! > On 24 Mar 2023, at 17:21, Andrew Dinn wrote: > > Hi Ron, > > Thank you for providing a heads up on the proposed JEP. The Red Hat Java team > have been discussing this proposal. We have reviewed the original discussion > and also the surrounding debate which established

Re: RFR: 8301995: Move invokedynamic resolution information out of ConstantPoolCacheEntry [v13]

2023-03-27 Thread Gui Cao
On Sat, 25 Mar 2023 05:11:16 GMT, Fei Yang wrote: >> Matias Saavedra Silva has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Improved interpreter comments aarch64 > > Changes requested by fyang (Reviewer). More changes for RISC-V which

Re: RFR: 8304547: Remove checking of -Djava.compiler in src/jdk.jdi/share/classes/com/sun/tools/jdi/SunCommandLineLauncher.java

2023-03-27 Thread Eirik Bjorsnos
On Mon, 20 Mar 2023 20:53:41 GMT, Eirik Bjorsnos wrote: > Please review this PR which removes the following outdated guard/check from > SunCommandLineLauncher: > > > if ((options.indexOf("-Djava.compiler=") != -1) && > (options.toLowerCase().indexOf("-djava.compiler=none") == -1)) { >

Re: RFR: 8304543: Modernize debugging jvm args in test/hotspot/jtreg/vmTestbase/nsk/jdi/Argument/value/value004.java

2023-03-27 Thread Eirik Bjorsnos
On Mon, 20 Mar 2023 19:47:10 GMT, Eirik Bjorsnos wrote: > Please review this PR which replaces the use of outdated JVM flags for > setting up debugging in the test value004.java > > This is part of an ongoing effort to remove use of the outdated flag > '-Djava.compiler" such that the option

Re: RFR: 8291555: Implement alternative fast-locking scheme [v29]

2023-03-27 Thread Thomas Stuefe
On Mon, 27 Mar 2023 02:46:31 GMT, David Holmes wrote: > > AFAIU, these places now could get outdated information from the contains > > function: either getting a false positive or a false negative when asking > > for a given object. But if I understand correctly, this had been the case > >

Re: RFR: 8304834: Fix wrapper insertion in TestScaffold.parseArgs(String args[]) [v2]

2023-03-27 Thread David Holmes
On Mon, 27 Mar 2023 05:42:12 GMT, Leonid Mesnik wrote: >> test/jdk/com/sun/jdi/TestScaffold.java line 469: >> >>> 467: // the first argument not-starting with '-' is treated as a >>> classname >>> 468: // the other arguments are split to targetVMArgs >>> targetAppCommandLine