On Thu, 12 Sep 2024 13:00:49 GMT, Coleen Phillimore <cole...@openjdk.org> wrote:
> If we have NSME on the stack and do a GC and the arguments aren't collected > but not used (but consumed because we clear the expression stack (?)) could > this cause a problem? Clearing the expression stack in the callee (NSME) doesn't remove the incoming arguments, because they are in the locals. Clearing the expression stack in the caller would mean the callee frame is already gone, I assume. > For PopFrame, I don't know how to PopFrame from Unsafe::NSME method. The JVMTI agent just needs to get control, I believe. It doesn't even need to be at a breakpoint of event handler -- I think suspending the thread, which would happen at a safepoint, is enough. Then it can request the frame to be popped. ------------- PR Comment: https://git.openjdk.org/jdk/pull/20874#issuecomment-2347688840