RFR: Update nmethod caching and clean up unused/duplicate methods [v9]
Vladimir Kozlov
kvn at openjdk.org
Mon Jun 16 18:49:50 UTC 2025
On Mon, 16 Jun 2025 13:28:11 GMT, Ashutosh Mehra <asmehra at openjdk.org> wrote:
>> This PR updates nmethod caching to be based on caching of CodeBlob. It also cleans up some dead code and duplicate methods.
>
> Ashutosh Mehra has updated the pull request incrementally with one additional commit since the last revision:
>
> Address ADinn's review comment
>
> Signed-off-by: Ashutosh Mehra <asmehra at redhat.com>
An other crash happened in aotCode/AOTCodeFlags.java on linux-amd64 in `find_entry()` which looks like during end of test run:
Event: 0.085 Thread 0x00007fc79002f0d0 Before exit entered
# SIGSEGV (0xb) at pc=0x00007fc79680ead8, pid=3219122, tid=3219333
#
# JRE version: Java(TM) SE Runtime Environment (25.0) (fastdebug build 25-internal-LTS-2025-06-16-1707161.vladimir.kozlov.leyden)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 25-internal-LTS-2025-06-16-1707161.vladimir.kozlov.leyden, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V [libjvm.so+0x69cad8] AOTCodeCache::find_entry(AOTCodeEntry::Kind, unsigned int, unsigned int, unsigned int)+0x158
Command Line: -XX:AOTCache=hello.aot -Xlog:aot -Xlog:aot+codecache* Hello
Host: AMD EPYC 7J13 64-Core Processor, 12 cores, 23G, Oracle Linux Server release 8.10
Time: Mon Jun 16 17:40:14 2025 UTC elapsed time: 0.094271 seconds (0d 0h 0m 0s)
--------------- T H R E A D ---------------
Current thread (0x00007fc790249570): JavaThread "Training replay thread" daemon [_thread_in_vm, id=3219333, stack(0x00007fc7701e6000,0x00007fc7702e6000) (1024K)]
Stack: [0x00007fc7701e6000,0x00007fc7702e6000], sp=0x00007fc7702e3440, free space=1013k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V [libjvm.so+0x69cad8] AOTCodeCache::find_entry(AOTCodeEntry::Kind, unsigned int, unsigned int, unsigned int)+0x158 (aotCodeCache.cpp:1001)
V [libjvm.so+0x69e09f] AOTCodeCache::find_code_entry(methodHandle const&, unsigned int)+0x22f (aotCodeCache.cpp:955)
V [libjvm.so+0xb8cfc3] CompileBroker::compile_method_base(methodHandle const&, int, int, int, CompileTask::CompileReason, bool, bool, Thread*)+0x103 (compileBroker.cpp:1428)
V [libjvm.so+0xb8dd68] CompileBroker::compile_method(methodHandle const&, int, int, int, bool, CompileTask::CompileReason, DirectiveSet*, JavaThread*)+0x4b8 (compileBroker.cpp:1729)
V [libjvm.so+0xb8e40c] CompileBroker::compile_method(methodHandle const&, int, int, int, bool, CompileTask::CompileReason, JavaThread*)+0xbc (compileBroker.cpp:1614)
V [libjvm.so+0xb4d29c] CompilationPolicy::maybe_compile_early(methodHandle const&, JavaThread*) [clone .part.0]+0x19c (compilationPolicy.cpp:120)
V [libjvm.so+0xb4d78d] CompilationPolicy::replay_training_at_init_impl(InstanceKlass*, JavaThread*)+0x3ad (compilationPolicy.cpp:176)
V [libjvm.so+0xb5244a] CompilationPolicy::replay_training_at_init_loop(JavaThread*)+0x24a (compilationPolicy.cpp:214)
V [libjvm.so+0x110180b] JavaThread::thread_main_inner()+0x13b (javaThread.cpp:774)
V [libjvm.so+0x1b946d6] Thread::call_run()+0xb6 (thread.cpp:254)
V [libjvm.so+0x180de89] thread_native_entry(Thread*)+0x1a9 (os_linux.cpp:868)
-------------
PR Comment: https://git.openjdk.org/leyden/pull/71#issuecomment-2977702830
More information about the leyden-dev
mailing list