Re: RFR: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 14:49:58 GMT, Leonid Mesnik wrote: > Could you please review following trivial fix which correct jvm options order > in TestScaffold. > TestScaffold combines test optionos and jtreg vm options. Before > [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed tes

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Wed, 12 Apr 2023 23:35:02 GMT, Jiangli Zhou wrote: > Rename 'jmm_' to 'jmm__management_ext' > in libmanagement_ext to resolve related linker errors when statically linking > with both libmanagement and libmanagement_ext. One small request but otherwise okay. In wonder if @magicus or @erikj

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Fri, 14 Apr 2023 05:17:28 GMT, David Holmes wrote: >> Rename 'jmm_' to 'jmm__management_ext' >> in libmanagement_ext to resolve related linker errors when statically >> linking with both libmanagement and libmanagement_ext. > > src/jdk.management/share/native/libmanagement_ext/management_ext

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Fri, 14 Apr 2023 02:09:47 GMT, Jiangli Zhou wrote: >>> If we were to do this then we should have a naming convention of some kind >>> e.g. `_` but it strikes me as wrong as the code >>> shouldn't need to know what library it is part of. In this case we do >>> something as a simple point-fix

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread Jiangli Zhou
On Fri, 14 Apr 2023 00:54:22 GMT, Jiangli Zhou wrote: >>> I'm not familiar with the details of symbol scoping and linkage with >>> libraries, but I would have hoped there was a way to have symbols like this >>> shareable throughout the code that comprises the library without exposing >>> them

Re: RFR: 8305085: Suppress removal warning for finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 11:31:05 GMT, Afshin Zafari wrote: >> The whole test is removed. > > Afshin Zafari has updated the pull request incrementally with one additional > commit since the last revision: > > 8305085: Remove finalize() from > test/hotspot/jtreg/serviceability/jvmti/RedefineClass

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread Jiangli Zhou
On Fri, 14 Apr 2023 00:34:14 GMT, Jiangli Zhou wrote: >>> The direct renaming in this case seems to be more strait forward. >> >> If we were to do this then we should have a naming convention of some kind >> e.g. `_` but it strikes me as wrong as the code >> shouldn't need to know what library

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread Jiangli Zhou
On Thu, 13 Apr 2023 23:07:23 GMT, David Holmes wrote: >> I'm not familiar with the details of symbol scoping and linkage with >> libraries, but I would have hoped there was a way to have symbols like this >> shareable throughout the code that comprises the library without exposing >> them to u

Integrated: 8305936: JavaThread::create_system_thread_object has unused is_visible argument

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 05:41:31 GMT, David Holmes wrote: > Please review this simple cleanup of an unused parameter in > `create_system_thread_object`. Details are in JBS. > > Testing: tiers 1-3 > > Thanks. This pull request has now been integrated. Changeset: 8a1639d4 Author:David Holmes

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 20:47:39 GMT, Jiangli Zhou wrote: >>> Is there not a way to stop these from being exported from the library, as I >>> assume they are not actually intended for external use. ?? >> >> Good question. >> >> We could make those as weak symbols as long as there is no concern abo

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 23:05:02 GMT, David Holmes wrote: >> Forgot to mention that using 'static' effectively resolves the symbol issue >> when feasible, like the 'jvm' variable case. That doesn't work for the >> 'jmm_interface' and 'jmm_version' ... > > I'm not familiar with the details of symbol

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread Jiangli Zhou
On Thu, 13 Apr 2023 20:04:15 GMT, Jiangli Zhou wrote: >> src/jdk.management/share/native/libmanagement_ext/management_ext.c line 36: >> >>> 34: const JmmInterface* jmm_interface_management_ext = NULL; >>> 35: static JavaVM* jvm = NULL; >>> 36: jint jmm_version_management_ext = 0; >> >> Is there

Re: RFR: 8305083: Remove finalize() from test/hotspot/jtreg/vmTestbase/nsk/share/ and /jpda that are used in serviceability/dcmd/framework tests

2023-04-13 Thread Coleen Phillimore
On Tue, 11 Apr 2023 08:16:29 GMT, Afshin Zafari wrote: > The `finalize()` method is removed from base classes/interfaces and are > replaced by a Cleaner callback.. Another change that has turned into something much bigger. This cleanup is worth doing. Possible steps are (not in order and not

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread Jiangli Zhou
On Thu, 13 Apr 2023 06:56:46 GMT, David Holmes wrote: > Is there not a way to stop these from being exported from the library, as I > assume they are not actually intended for external use. ?? Good question. We could make those as weak symbols as long as there is no concern about portability.

Re: RFR: 8305085: Suppress removal warning for finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread Chris Plummer
On Thu, 13 Apr 2023 11:31:05 GMT, Afshin Zafari wrote: >> The whole test is removed. > > Afshin Zafari has updated the pull request incrementally with one additional > commit since the last revision: > > 8305085: Remove finalize() from > test/hotspot/jtreg/serviceability/jvmti/RedefineClass

Re: RFR: 8305085: Suppress removal warning for finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread Chris Plummer
On Thu, 13 Apr 2023 11:31:05 GMT, Afshin Zafari wrote: >> The whole test is removed. > > Afshin Zafari has updated the pull request incrementally with one additional > commit since the last revision: > > 8305085: Remove finalize() from > test/hotspot/jtreg/serviceability/jvmti/RedefineClass

Re: RFR: 8298048: Combine CDS archive heap into a single block [v5]

2023-04-13 Thread Matias Saavedra Silva
On Wed, 12 Apr 2023 17:59:23 GMT, Ioi Lam wrote: >> This PR combines the "open" and "closed" regions of the CDS archive heap >> into a single region. This significantly simplifies the implementation, >> making it more compatible with non-G1 collectors. There's a net removal of >> ~1000 lines i

Re: RFR: 8305085: Suppress removal warning for finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread Afshin Zafari
On Thu, 13 Apr 2023 15:32:19 GMT, Chris Plummer wrote: > The CR synopsis needs to be updated. The titles updated. - PR Comment: https://git.openjdk.org/jdk/pull/13422#issuecomment-1507357976

Integrated: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread Leonid Mesnik
On Thu, 13 Apr 2023 14:49:58 GMT, Leonid Mesnik wrote: > Could you please review following trivial fix which correct jvm options order > in TestScaffold. > TestScaffold combines test optionos and jtreg vm options. Before > [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed tes

Integrated: 8305966: ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64

2023-04-13 Thread Daniel D . Daugherty
On Thu, 13 Apr 2023 15:41:28 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64. This pull request has now been integrated. Changeset: 1385c3d2 Author:Daniel D. Daugherty URL: https://git.openjdk.org/jdk/commit/1385c3d2f1

Re: RFR: 8305966: ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64

2023-04-13 Thread Daniel D . Daugherty
On Thu, 13 Apr 2023 15:44:46 GMT, Alan Bateman wrote: >> A trivial fix to ProblemList com/sun/jdi/JdbLastErrorTest.java on >> windows-x64. > > Marked as reviewed by alanb (Reviewer). @AlanBateman - Thanks for the fast review! - PR Comment: https://git.openjdk.org/jdk/pull/13465#is

Re: RFR: 8305966: ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64

2023-04-13 Thread Alan Bateman
On Thu, 13 Apr 2023 15:41:28 GMT, Daniel D. Daugherty wrote: > A trivial fix to ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64. Marked as reviewed by alanb (Reviewer). - PR Review: https://git.openjdk.org/jdk/pull/13465#pullrequestreview-1383725934

RFR: 8305966: ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64

2023-04-13 Thread Daniel D . Daugherty
A trivial fix to ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64. - Commit messages: - 8305966: ProblemList com/sun/jdi/JdbLastErrorTest.java on windows-x64 Changes: https://git.openjdk.org/jdk/pull/13465/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13465&ran

Re: RFR: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread Daniel D . Daugherty
On Thu, 13 Apr 2023 14:49:58 GMT, Leonid Mesnik wrote: > Could you please review following trivial fix which correct jvm options order > in TestScaffold. > TestScaffold combines test optionos and jtreg vm options. Before > [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed tes

Re: RFR: 8305085: Remove finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread Chris Plummer
On Thu, 13 Apr 2023 11:31:05 GMT, Afshin Zafari wrote: >> The whole test is removed. > > Afshin Zafari has updated the pull request incrementally with one additional > commit since the last revision: > > 8305085: Remove finalize() from > test/hotspot/jtreg/serviceability/jvmti/RedefineClass

RFR: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread Leonid Mesnik
Could you please review following trivial fix which correct jvm options order in TestScaffold. TestScaffold combines test optionos and jtreg vm options. Before [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed test jvm args as part of targetAppCommandLine. So the test VM args

Withdrawn: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread Leonid Mesnik
On Thu, 13 Apr 2023 14:41:42 GMT, Leonid Mesnik wrote: > TestScaffold combines test optionos and jtreg vm options. Before > [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed test jvm > args as part of targetAppCommandLine. So the test VM args are added to the > jtreg vm opti

RFR: 8305937: com/sun/jdi/SetLocalWhileThreadInNative.java fails with -XX:+TieredCompilation

2023-04-13 Thread Leonid Mesnik
TestScaffold combines test optionos and jtreg vm options. Before [JDK-8304834](https://bugs.openjdk.org/browse/JDK-8304834) it passed test jvm args as part of targetAppCommandLine. So the test VM args are added to the jtreg vm options. But after JDK-8304834 it parse then into targetVMArgs. So t

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Markus Grönlund
On Thu, 13 Apr 2023 10:24:55 GMT, Serguei Spitsyn wrote: >> Markus Grönlund has updated the pull request incrementally with one >> additional commit since the last revision: >> >> renames > > src/hotspot/share/prims/jvmtiAgentList.cpp line 72: > >> 70: // there exist an order requirement to

Re: RFR: 8257967: JFR: Events for loaded agents [v17]

2023-04-13 Thread Markus Grönlund
> Greetings, > > We are adding support to let JFR report on Agents. > > Design > > An Agent is a library that uses any instrumentation or profiling APIs. Most > agents are started and initialized on the command line, but agents can also > be loaded dynamically during runtime. Because comm

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Markus Grönlund
On Thu, 13 Apr 2023 10:15:02 GMT, Serguei Spitsyn wrote: > Your fix introduced a hidden dependency of this new structure on the > JPLISEnvironment structure and some Java agents implementation details: > > ``` > 202 struct JPLISEnvironmentMirror { > 203 jvmtiEnv* mJVMTIEnv; // the JVMTI envir

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Markus Grönlund
On Thu, 13 Apr 2023 10:07:50 GMT, Serguei Spitsyn wrote: > What was the reason to clone the classes below ?: > `JvmtiJavaThreadEventTransition` => `AgentJavaThreadEventTransition` > `JvmtiThreadEventMark` => `AgentThreadEventMark` `JvmtiEventMark` => > `AgentEventMark` The reason is they are

Re: RFR: 8305085: Remove finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java [v2]

2023-04-13 Thread Afshin Zafari
> The whole test is removed. Afshin Zafari has updated the pull request incrementally with one additional commit since the last revision: 8305085: Remove finalize() from test/hotspot/jtreg/serviceability/jvmti/RedefineClasses/RedefineFinalizer.java - Changes: - all: https://g

Re: RFR: 8305936: JavaThread::create_system_thread_object has unused is_visible argument

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 08:48:20 GMT, Kim Barrett wrote: >> Please review this simple cleanup of an unused parameter in >> `create_system_thread_object`. Details are in JBS. >> >> Testing: tiers 1-3 >> >> Thanks. > > Looks good. Thanks for the review @kimbarrett! - PR Comment: http

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Serguei Spitsyn
On Tue, 4 Apr 2023 14:39:19 GMT, Markus Grönlund wrote: >> Greetings, >> >> We are adding support to let JFR report on Agents. >> >> Design >> >> An Agent is a library that uses any instrumentation or profiling APIs. Most >> agents are started and initialized on the command line, but age

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Serguei Spitsyn
On Tue, 4 Apr 2023 14:39:19 GMT, Markus Grönlund wrote: >> Greetings, >> >> We are adding support to let JFR report on Agents. >> >> Design >> >> An Agent is a library that uses any instrumentation or profiling APIs. Most >> agents are started and initialized on the command line, but age

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Serguei Spitsyn
On Tue, 4 Apr 2023 14:39:19 GMT, Markus Grönlund wrote: >> Greetings, >> >> We are adding support to let JFR report on Agents. >> >> Design >> >> An Agent is a library that uses any instrumentation or profiling APIs. Most >> agents are started and initialized on the command line, but age

Re: RFR: 8257967: JFR: Events for loaded agents [v16]

2023-04-13 Thread Serguei Spitsyn
On Wed, 12 Apr 2023 10:43:31 GMT, Markus Grönlund wrote: >> src/hotspot/share/prims/jvmtiAgent.cpp line 323: >> >>> 321: assert(agent != nullptr, "invariant"); >>> 322: if (!agent->is_loaded()) { >>> 323: if (!load_agent_from_executable(agent, on_load_symbols, >>> num_symbol_entries)) {

Re: RFR: 8299414: JVMTI FollowReferences should support references from VirtualThread stack [v7]

2023-04-13 Thread Alan Bateman
On Wed, 12 Apr 2023 14:55:59 GMT, Alan Bateman wrote: >> Alex Menkov has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed indent in collect_vthread_stack_roots > > In the spec for FollowReferences, it says that the heap roots include >

Re: RFR: 8305936: JavaThread::create_system_thread_object has unused is_visible argument

2023-04-13 Thread Kim Barrett
On Thu, 13 Apr 2023 05:41:31 GMT, David Holmes wrote: > Please review this simple cleanup of an unused parameter in > `create_system_thread_object`. Details are in JBS. > > Testing: tiers 1-3 > > Thanks. Looks good. - Marked as reviewed by kbarrett (Reviewer). PR Review: https

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

2023-04-13 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 Li

Re: RFR: 8299414: JVMTI FollowReferences should support references from VirtualThread stack [v7]

2023-04-13 Thread David Holmes
On Wed, 12 Apr 2023 01:12:49 GMT, Alex Menkov wrote: >> The fix updates JVMTI FollowReferences implementation to report references >> from virtual threads: >> - unmounted vthreads are detected and reported as >> JVMTI_HEAP_REFERENCE_THREAD; >> - stack references for unmounted VT are reported as

Re: RFR: 8299414: JVMTI FollowReferences should support references from VirtualThread stack [v7]

2023-04-13 Thread Chris Plummer
On Wed, 12 Apr 2023 14:55:59 GMT, Alan Bateman wrote: >> Alex Menkov has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Fixed indent in collect_vthread_stack_roots > > In the spec for FollowReferences, it says that the heap roots include >

Re: RFR: 8305936: JavaThread::create_system_thread_object has unused is_visible argument

2023-04-13 Thread David Holmes
On Thu, 13 Apr 2023 06:17:00 GMT, Alan Bateman wrote: >> Please review this simple cleanup of an unused parameter in >> `create_system_thread_object`. Details are in JBS. >> >> Testing: tiers 1-3 >> >> Thanks. > > Marked as reviewed by alanb (Reviewer). Thanks for the review @AlanBateman !

Re: RFR: 8305935: Resolve multiple definition of 'jmm_' when statically linking with JDK native libraries

2023-04-13 Thread David Holmes
On Wed, 12 Apr 2023 23:35:02 GMT, Jiangli Zhou wrote: > Rename 'jmm_' to 'jmm__management_ext' > in libmanagement_ext to resolve related linker errors when statically linking > with both libmanagement and libmanagement_ext. src/jdk.management/share/native/libmanagement_ext/management_ext.c lin