Re: RFR: 8308000: add PopFrame support for virtual threads [v7]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: RFR: 8304074: [JMX] Add an approximation of total bytes allocated on the Java heap by the JVM [v21]

2023-05-17 Thread Paul Hohensee
> Please review this addition to com.sun.management.ThreadMXBean that returns > the total number of bytes allocated on the Java heap since JVM launch by both > terminated and live threads. > > Because this PR adds a new interface method, I've updated the JMM_VERSION to > 4, but would be happy t

Re: RFR: 8304074: [JMX] Add an approximation of total bytes allocated on the Java heap by the JVM [v20]

2023-05-17 Thread Paul Hohensee
> Please review this addition to com.sun.management.ThreadMXBean that returns > the total number of bytes allocated on the Java heap since JVM launch by both > terminated and live threads. > > Because this PR adds a new interface method, I've updated the JMM_VERSION to > 4, but would be happy t

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Ron Pressler
> On 17 May 2023, at 23:01, Gregg Wonderly wrote: > > Again, the supposition here, is that somehow anyone who once built an > application into a jar file that is in use today, can somehow cause a release > of a new version of the JDK that appears in a user’s environment, to > correlate with

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Gregg Wonderly
> On May 17, 2023, at 4:33 PM, Ron Pressler wrote: > > But keep in mind that since Java has shifted away from the JRE model, > self-contained Java applications are encouraged to use jlink to embed their > own runtime and pick their arbitrary command-line options rather than rely on > execut

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Ron Pressler
> On 17 May 2023, at 20:34, Gregg Wonderly wrote: > > The first thrust of Java deployment was Applets which used no “command line” > and automatically deployed and “secured” the Java environment. Next was the > automatic recognition of .jar files on the Windows environment (file type > mapp

Re: RFR: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled [v5]

2023-05-17 Thread Serguei Spitsyn
On Wed, 17 May 2023 15:31:17 GMT, Patricio Chilano Mateo wrote: >> The following patch fixes a bug introduced while refactoring the >> VirtualThreadStart/End events. Specifically, the code to delete the >> JvmtiThreadState of a terminating vthread was moved before we start the VTMS >> transit

Re: RFR: 8308237: add JDWP and JDI virtual thread support for ThreadReference.PopFrames [v2]

2023-05-17 Thread Chris Plummer
On Wed, 17 May 2023 08:31:20 GMT, Alan Bateman wrote: >> Chris Plummer has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Change "The specified thread" to "This thread" > > src/jdk.jdi/share/classes/com/sun/jdi/ThreadReference.java line 380

Re: RFR: 8308237: add JDWP and JDI virtual thread support for ThreadReference.PopFrames [v2]

2023-05-17 Thread Chris Plummer
> This is a follow-on to > [JDK-8264699](https://bugs.openjdk.org/browse/JDK-8264699) which adds JVMTI > PopFrames support for virtual thread. For JDWP and JDI this is mostly a spec > update, although JDI needs minor changes to properly throw the correct > exception. Note this PR needs JDK-8264

Integrated: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled

2023-05-17 Thread Patricio Chilano Mateo
On Fri, 12 May 2023 02:14:00 GMT, Patricio Chilano Mateo wrote: > The following patch fixes a bug introduced while refactoring the > VirtualThreadStart/End events. Specifically, the code to delete the > JvmtiThreadState of a terminating vthread was moved before we start the VTMS > transition.

Re: RFR: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled [v3]

2023-05-17 Thread Patricio Chilano Mateo
On Tue, 16 May 2023 23:17:04 GMT, Serguei Spitsyn wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with one >> additional commit since the last revision: >> >> added new test > > I'd suggest to name new test as `ThreadStateTest`, `JvmtiThreadStateTest` or > `Thread

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 19:06:24 GMT, Chris Plummer wrote: > The following problem listed JDI tests are all passing now. However, I don't > think there are any negative tests for OPAQUE_FRAME and THREAD_NOT_SUSPENDED. > If I can't find any I'll need to write them. Okay. Thank you for sharing this.

Re: RFR: 8308000: add PopFrame support for virtual threads [v6]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Gregg Wonderly
> On May 16, 2023, at 12:22 PM, Ron Pressler wrote: > > At the core of your arguments is the claim — that we’ve heard told > second-hand but rarely if ever reported first-hand — that the inability to > control the command line is common. This claim is very important because its > implicatio

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Gregg Wonderly
> On May 15, 2023, at 8:56 AM, Ron Pressler wrote: > >> >> The issue is that release-specific code may need to use deep reflection to >> fix bugs or compensate for limitations in a specific set of JDK releases. > > But mucking about with JDK internals requires the application’s approval as

Integrated: 8308292: Problemlist vmTestbase/nsk/jvmti/AttachOnDemand/attach020/TestDescription.java

2023-05-17 Thread Leonid Mesnik
On Wed, 17 May 2023 15:50:09 GMT, Leonid Mesnik wrote: > Trivial problemlisting of failing test. This pull request has now been integrated. Changeset: 8bedf2ef Author:Leonid Mesnik URL: https://git.openjdk.org/jdk/commit/8bedf2efd7671834b3f7ff42bc33008821545d9f Stats: 1 line in

Re: RFR: 8308292: Problemlist vmTestbase/nsk/jvmti/AttachOnDemand/attach020/TestDescription.java

2023-05-17 Thread Serguei Spitsyn
On Wed, 17 May 2023 15:50:09 GMT, Leonid Mesnik wrote: > Trivial problemlisting of failing test. Looks good and trivial. Thanks, Serguei - Marked as reviewed by sspitsyn (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/14035#pullrequestreview-1431200014

Re: RFR: 8308000: add PopFrame support for virtual threads [v5]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Brice Dutheil
> > For white-box testing of code in user modules, build tools and testing frameworks should automatically emit --add-exports, --add-opens, and --patch-module for the module under test, as appropriate (for example, patching the module under test with the contents of the test module allows the testi

RFR: 8308292: Problemlist vmTestbase/nsk/jvmti/AttachOnDemand/attach020/TestDescription.java

2023-05-17 Thread Leonid Mesnik
Trivial problemlisting of failing test. - Commit messages: - 8308292: Problemlist vmTestbase/nsk/jvmti/AttachOnDemand/attach020/TestDescription.java Changes: https://git.openjdk.org/jdk/pull/14035/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=14035&range=00 Issue: https

Re: RFR: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled [v3]

2023-05-17 Thread Leonid Mesnik
On Tue, 16 May 2023 23:42:46 GMT, Patricio Chilano Mateo wrote: >> I'd suggest to name new test as `ThreadStateTest`, `JvmtiThreadStateTest` or >> `ThreadStateSanityTest`. >> One more quick suggestion is to replace JVMTI state in the comments to >> `JvmtiThreadState`. > >> I'd suggest to name

Re: RFR: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled [v5]

2023-05-17 Thread Patricio Chilano Mateo
> The following patch fixes a bug introduced while refactoring the > VirtualThreadStart/End events. Specifically, the code to delete the > JvmtiThreadState of a terminating vthread was moved before we start the VTMS > transition. That allowed said code to run concurrently with > recompute_enabl

Re: RFR: 8307365: JvmtiStressModule hit SIGSEGV in JvmtiEventControllerPrivate::recompute_thread_enabled [v4]

2023-05-17 Thread Patricio Chilano Mateo
On Wed, 17 May 2023 02:22:01 GMT, Leonid Mesnik wrote: >> Patricio Chilano Mateo has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Serguei test comments > > test/hotspot/jtreg/serviceability/jvmti/vthread/ThreadStateTest/ThreadStateTest.ja

Integrated: 8307326: Package jdk.internal.classfile.java.lang.constant become obsolete

2023-05-17 Thread Adam Sotona
On Mon, 15 May 2023 08:38:54 GMT, Adam Sotona wrote: > Package `jdk.internal.classfile.java.lang.constant` containing `ModuleDesc` > and `PackageDesc` become obsolete after > [JDK-8306729](https://bugs.openjdk.org/browse/JDK-8306729). > All references to `jdk.internal.classfile.java.lang.const

RFR: 8308286 Fix clang warnings in linux code

2023-05-17 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. - Commit messages: - 8308286 Fix clang warnings in linux code Changes: https://git.openjdk.org/jdk/pull/14033/files Webrev: https://webrevs.ope

Re: [External] : Re: New candidate JEP: 451: Prepare to Disallow the Dynamic Loading of Agents

2023-05-17 Thread Ron Pressler
> On 15 May 2023, at 23:24, Brice Dutheil wrote: > > Hi, > > I do share some concerns of the community, however many have voiced it with a > better english that I could ever do. But I'd like to mention two things: > > 1. There is another usage that I think will be visibly impacted : in tests

Re: RFR: 8308000: add PopFrame support for virtual threads [v4]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: RFR: 8308000: add PopFrame support for virtual threads [v3]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: RFR: 8308000: add PopFrame support for virtual threads [v2]

2023-05-17 Thread Serguei Spitsyn
> This enhancement adds `PopFrame` support for virtual threads. The spec > defines minimal support that the JVMTI `PopFrame` can be used for a virtual > thread suspended an an event. > Actually, the `PopFrame` can supports suspended and mounted virtual threads. > > CSR (approved): https://bugs

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 18:59:38 GMT, Chris Plummer wrote: > serviceability/jvmti/vthread/BoundVThreadTest/BoundVThreadTest.java and > serviceability/jvmti/vthread/VThreadUnsupportedTest/VThreadUnsupportedTest.java > are failing with: > > `PopFrame failed: expected JVMTI_ERROR_OPAQUE_FRAME instead

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 18:59:38 GMT, Chris Plummer wrote: > VThreadUnsupportedTest - PR Comment: https://git.openjdk.org/jdk/pull/14002#issuecomment-1551136595

Re: RFR: JDK-8306441: Segmented heap dump [v6]

2023-05-17 Thread Yi Yang
> Hi, heap dump brings about pauses for application's execution(STW), this is a > well-known pain. JDK-8252842 have added parallel support to heapdump in an > attempt to alleviate this issue. However, all concurrent threads > competitively write heap data to the same file, and more memory is req

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Wed, 17 May 2023 09:08:32 GMT, Serguei Spitsyn wrote: >> src/hotspot/share/prims/jvmtiEnv.cpp line 1896: >> >>> 1894: } >>> 1895: } else { >>> 1896: if (java_thread != current_thread && !java_thread->is_suspended() >>> && >> >> This branch checks the state when the thread is platf

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:57:45 GMT, Leonid Mesnik wrote: > It is also unclear how popFrame works if the the underlying frame is > jdk.internal.vm.Continuation.enterSpecial(). Would it just return some error? Good question. Let me check it. - PR Comment: https://git.openjdk.org/jdk/p

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:42:16 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: JDK-8306441: Segmented heap dump [v5]

2023-05-17 Thread Yi Yang
On Mon, 15 May 2023 02:16:43 GMT, Yi Yang wrote: >> Yi Yang has updated the pull request incrementally with one additional >> commit since the last revision: >> >> execute VM_HeapDumper directly > > Hi, can I have a review for this patch? > @y1yang0 Sorry no one has been able to review this

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 22:18:17 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 22:04:26 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308237: add JDWP and JDI virtual thread support for ThreadReference.PopFrames

2023-05-17 Thread Alan Bateman
On Tue, 16 May 2023 22:02:45 GMT, Chris Plummer wrote: > This is a follow-on to > [JDK-8264699](https://bugs.openjdk.org/browse/JDK-8264699) which adds JVMTI > PopFrames support for virtual thread. For JDWP and JDI this is mostly a spec > update, although JDI needs minor changes to properly th

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Wed, 17 May 2023 00:22:08 GMT, Chris Plummer wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:42:52 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:35:09 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Wed, 17 May 2023 01:03:52 GMT, David Holmes wrote: >> test/hotspot/jtreg/serviceability/jvmti/vthread/PopFrameTest/PopFrameTest.java >> line 62: >> >>> 60: static final int FAILED = 2; >>> 61: >>> 62: static void log(String str) { System.out.println(str); } >> >> Better to flush sy

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:36:57 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 23:15:36 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an

Re: RFR: 8308000: add PopFrame support for virtual threads

2023-05-17 Thread Serguei Spitsyn
On Tue, 16 May 2023 22:52:41 GMT, Leonid Mesnik wrote: >> This enhancement adds `PopFrame` support for virtual threads. The spec >> defines minimal support that the JVMTI `PopFrame` can be used for a virtual >> thread suspended an an event. >> Actually, the `PopFrame` can supports suspended an