On Mon, 18 Mar 2024 02:21:40 GMT, David Holmes <dhol...@openjdk.org> wrote:
>> src/hotspot/share/runtime/javaThread.cpp line 596: >> >>> 594: // Checks and clears the interrupt status for platform or virtual >>> thread. >>> 595: // Used by the JVMTI RawMonitorWait only. >>> 596: bool JavaThread::is_interrupted() { >> >> Reading code that uses JavaThread::is_interrupted() won't be clear that it >> resets the interrupt status. Can this be something that >> get_and_clear_interrupted or something that makes it clearer? > > Maybe `is_interrupted_with_reset`? (though that would seem like an alias for > `is_interrupted(true)`. Thanks, Alan and David. Will consider your suggestions. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/18093#discussion_r1528336441