RFR: 8329491: GetThreadListStackTraces function should use JvmtiHandshake

Patricio Chilano Mateo pchilanomate at openjdk.org
Tue Apr 2 22:24:08 UTC 2024


On Tue, 2 Apr 2024 08:13:20 GMT, Serguei Spitsyn <sspitsyn at openjdk.org> wrote:

> The internal JVM TI `JvmtiHandshake` and `JvmtiUnitedHandshakeClosure` classes were introduced in the JDK 22 to unify/simplify the JVM TI functions supporting implementation of the virtual threads. This enhancement is to refactor the JVM TI function `GetThreadListStackTraces` on the base of `JvmtiHandshake` and `JvmtiUnitedHandshakeClosure` classes.
> 
> Testing:
>  - Ran mach5 tiers 1-6

Looks good to me.

src/hotspot/share/prims/jvmtiEnvBase.cpp line 1986:

> 1984:   jvmtiError err = JvmtiEnvBase::get_threadOop_and_JavaThread(tlh.list(), target, &java_thread, &thread_obj);
> 1985:   if (err != JVMTI_ERROR_NONE) {
> 1986:     printf("DBG: JvmtiHandshake::execute: err: %d\n", (int)err); fflush(0);

Any reason why not use UL instead with jvmti tag?

-------------

Marked as reviewed by pchilanomate (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/18574#pullrequestreview-1975169550
PR Review Comment: https://git.openjdk.org/jdk/pull/18574#discussion_r1548686478


More information about the serviceability-dev mailing list