RFR: 8320652: ThreadInfo.isInNative needs to be updated to say what executing native code means [v2]
Alan Bateman
alanb at openjdk.org
Tue Nov 28 06:19:04 UTC 2023
On Tue, 28 Nov 2023 06:06:58 GMT, David Holmes <dholmes at openjdk.org> wrote:
> Note that there is no answer for the "syscall" case mentioned as it depends on the code that makes the syscall: if from a native method then yes; if from the VM then no.
Right, if the thread invokes a Java native method then it may or may not invoke a system call, it doesn't matter, the ThreadInfo::isInNative method is just reporting a bit of thread state to say that it is in a native method. Same thing when calling a native function with the FFM API, the native function may be a syscall, or the native code may invoke a syscall, it doesn't matter to ThreadInfo::isInNative as it just returns a bit of thread state.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16791#discussion_r1407275856
More information about the serviceability-dev
mailing list