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

C1 compilation fails with assert(stack_end >= -Bytecodes::depth(code)) failed: must have non-empty expression stack at if bytecode

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P3 P3
    • 13
    • 11, 12, 13
    • hotspot

      # Internal Error (/oracle/jdk_jdk/open/src/hotspot/share/c1/c1_LinearScan.cpp:2382), pid=28024, tid=28049
      # assert(stack_end >= -Bytecodes::depth(code)) failed: must have non-empty expression stack at if bytecode

      Current CompileTask:
      C1: 530 29 b 1 compiler.c1.TestGotoIf::test (19 bytes)

      Stack: [0x00007fa6fab21000,0x00007fa6fac22000], sp=0x00007fa6fac1fce0, free space=1019k
      Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
      V [libjvm.so+0x845366] check_stack_depth(CodeEmitInfo*, int)+0x216
      V [libjvm.so+0x85d676] LinearScan::compute_debug_info(CodeEmitInfo*, int)+0x46
      V [libjvm.so+0x85e45f] LinearScan::assign_reg_num(GrowableArray<LIR_Op*>*, IntervalWalker*)+0x58f
      V [libjvm.so+0x85e6e3] LinearScan::assign_reg_num()+0xa3
      V [libjvm.so+0x86b31d] LinearScan::do_linear_scan()+0x1dd
      V [libjvm.so+0x78b994] Compilation::emit_lir()+0x1024
      V [libjvm.so+0x78ccc6] Compilation::compile_java_method()+0x6e6
      V [libjvm.so+0x78dad9] Compilation::compile_method()+0x2d9
      V [libjvm.so+0x78e8d4] Compilation::Compilation(AbstractCompiler*, ciEnv*, ciMethod*, int, BufferBlob*, DirectiveSet*)+0x4f4
      V [libjvm.so+0x790aab] Compiler::compile_method(ciEnv*, ciMethod*, int, DirectiveSet*)+0x18b
      V [libjvm.so+0xa9a0d0] CompileBroker::invoke_compiler_on_method(CompileTask*)+0x3c0
      V [libjvm.so+0xa9aedf] CompileBroker::compiler_thread_loop()+0x3bf
      V [libjvm.so+0x182817f] JavaThread::thread_main_inner()+0x21f
      V [libjvm.so+0x182e2d0] Thread::call_run()+0x100
      V [libjvm.so+0x146e67d] thread_native_entry(Thread*)+0xfd

      The bytecodes are:
               0: aload_0
               1: getfield #36
               4: aload_0
               5: getfield #22
               8: iconst_1
               9: isub
              10: if_icmpgt 15
              13: iconst_1
              14: ireturn
              15: iconst_0
              16: goto 14

            thartmann Tobias Hartmann
            thartmann Tobias Hartmann
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: