Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8255717

JFR crash in WriteObjectSampleStacktrace with uninitialized klass

XMLWordPrintable

    • jfr
    • b04
    • generic
    • generic

        Reproduce with SPECjvm2008 command. Frequency is much higher (above 50%) with fastdebug and slowdebug build.

        java -XX:StartFlightRecording=dumponexit,settings=profile,filename=xxx.jfr,maxsize=1m -jar SPECjvm2008.jar compiler.compiler compiler.sunflow compress crypto.aes crypto.rsa crypto.signverify derby mpegaudio scimark.fft.large scimark.lu.large scimark.sor.large scimark.sparse.large scimark.fft.small scimark.lu.small scimark.sor.small scimark.sparse.small scimark.monte_carlo serial sunflow xml.transform xml.validation -ikv -ict -wt 30s -it 60s

        part hs_err file
        #
        # A fatal error has been detected by the Java Runtime Environment:
        #
        # SIGSEGV (0xb) at pc=0x00007f050cc792ec, pid=1077, tid=0x00007f04e4fd5700
        #
        # JRE version: OpenJDK Runtime Environment (8.0) (build 1.8.0-debug-shihui_2020_11_01_20_20-b00)
        # Java VM: OpenJDK 64-Bit Server VM (25.71-b00-debug mixed mode linux-amd64 compressed oops)
        # Problematic frame:
        # V [libjvm.so+0x3c62ec] set_bits(signed char, signed char*)+0x40
        #
        # Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
        #
        # If you would like to submit a bug report, please visit:
        # http://bugreport.java.com/bugreport/crash.jsp
        #

        --------------- T H R E A D ---------------

        Current thread (0x00007f050be86800): JavaThread "JFR Recorder Thread" daemon [_thread_in_vm, id=1092, stack(0x00007f04e4ed5000,0x00007f04e4fd6000)]

        Stack: [0x00007f04e4ed5000,0x00007f04e4fd6000], sp=0x00007f04e4fd30e0, free space=1016k
        Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
        V [libjvm.so+0x3c62ec] set_bits(signed char, signed char*)+0x40
        V [libjvm.so+0x3c6357] set_leakp_traceid_bits(signed char, unsigned long*)+0x27
        V [libjvm.so+0x3c6ddb] unsigned long set_used_and_get<Klass>(Klass const*, bool)+0x64
        V [libjvm.so+0x3c6880] unsigned long set_used_and_get_shifted<Klass>(Klass const*, bool)+0x4e
        V [libjvm.so+0x3c6408] JfrTraceId::use(Klass const*, bool)+0x4e
        V [libjvm.so+0xb85dd0] StackTraceWrite::sample_do(ObjectSample*)+0x78
        V [libjvm.so+0xb8543a] void do_samples<StackTraceWrite>(ObjectSample*, ObjectSample const*, StackTraceWrite&)+0x54
        V [libjvm.so+0xb85154] WriteObjectSampleStacktrace::process()+0x16e
        V [libjvm.so+0x8d6953] write_object_sample_stacktrace(ObjectSampler*, JfrStackTraceRepository&)+0x33
        V [libjvm.so+0x8d6b04] JfrRecorderService::pre_safepoint_write()+0x114
        V [libjvm.so+0x8d6891] JfrRecorderService::write()+0x39
        V [libjvm.so+0x8d681d] JfrRecorderService::finalize_current_chunk()+0x53
        V [libjvm.so+0x8d67b6] JfrRecorderService::chunk_rotation()+0x18
        V [libjvm.so+0x8d64af] JfrRecorderService::rotate(int)+0xc3
        V [libjvm.so+0x8d8989] recorderthread_entry(JavaThread*, Thread*)+0x169
        V [libjvm.so+0xd1f543] JavaThread::thread_main_inner()+0x127
        V [libjvm.so+0xd1f413] JavaThread::run()+0x1a7
        V [libjvm.so+0xb9cddd] java_start(Thread*)+0x1bb
        C [libpthread.so.0+0x7e25] start_thread+0xc5

              hshi Hui Shi
              hshi Hui Shi
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: