RFR: Loom support for RedefineClasses [v3]

Ron Pressler rpressler at openjdk.java.net
Tue May 4 23:03:55 UTC 2021


On Tue, 4 May 2021 19:26:51 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> src/hotspot/share/oops/instanceStackChunkKlass.inline.hpp line 794:
>> 
>>> 792: void InstanceStackChunkKlass::run_nmethod_entry_barrier_if_needed(const StackChunkFrameStream<mixed>& f) {
>>> 793:   CodeBlob* cb = f.cb();
>>> 794:   if ((mixed && cb == nullptr) || !cb->is_nmethod()) {
>> 
>> If `mixed` is false, then there are no interpreted frames. The condition should be `if (f.is_interpreted())` (which short-circuits to false if `mixed` is false).
>
> Ok that's much better.  Thanks.  If (!f.is_interpreted) then cb will always be an nmethod? Or do I need to check for that in the else case?

There's one other possibility: a safepoint stub (in the case of forced preemption). But `StackChunkFrameStream` also has `is_compiled` and `is_stub`. Exactly one of those three would be true for each frame. If `is_compiled`, then you have an nmethod.

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

PR: https://git.openjdk.java.net/loom/pull/38


More information about the loom-dev mailing list