jshell needs to drop its usage of Thread.stop so that this method can be degraded to throw UOE unconditionally. The usage in jshell seems to be there to deal with looping threads and dealing with the user pressing "control-C". Alternatives to Thread.stop should be explored, maybe it is possible to start a new debuggee VM, maybe the compiler could generate code that checks a flag or interrupt status at back branches, maybe it could use an agent that injects a check. A short term fix may be be to use JDI ThreadReference::stop as this method will continue to work for debuggers.