JDK-8338638 : LightweightSynchronizer::exit asserts, missing lock
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 24
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • OS: linux
  • CPU: riscv
  • Submitted: 2024-08-20
  • Updated: 2024-08-20
Description
#  Internal Error (/home/rehn/source/jdk/open/src/hotspot/share/runtime/lightweightSynchronizer.cpp:746), pid=208978, tid=209001
#  assert(current->lock_stack().contains(object)) failed: current must have object on its lock stack

V  [libjvm.so+0xea58d4]  LightweightSynchronizer::exit(oop, JavaThread*)+0x560  (lightweightSynchronizer.cpp:746)
V  [libjvm.so+0x1208db0]  SharedRuntime::monitor_exit_helper(oopDesc*, BasicLock*, JavaThread*)+0x160  (synchronizer.inline.hpp:75)
V  [libjvm.so+0x1208e82]  SharedRuntime::complete_monitor_unlocking_C(oopDesc*, BasicLock*, JavaThread*)+0x50  (sharedRuntime.cpp:1974)

Test running was UseObjectMonitorTableTest.java#ExtremeDeflation

(gdb) p UseObjectMonitorTable
$1 = true

Test machine was heavily loaded (oom killer took down a linker).
Which means there may have been failed C-heap allocation.
And/or maybe specific to RV.

Tip was: 6460b300487071bcf98f5ac70d9c0a6fd6b94083