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

Shenandoah/C2: TestVerifyLoopOptimizations test failure

XMLWordPrintable

    • b03
    • generic
    • generic

      Running the following test:

      make run-test TEST=compiler/loopopts/TestVerifyLoopOptimizations.java TEST_VM_OPTS="-XX:+UseShenandoahGC"

      fails with:

      # Internal Error (/home/admin/src/openjdk/jdk/src/hotspot/share/opto/loopnode.hpp:470), pid=2362836, tid=2362881
      # assert(cle != nullptr) failed: loopexit is null

      Current CompileTask:
      C2:18095 3693 b 4 java.lang.invoke.LambdaMetafactory::metafactory (71 bytes)

      Stack: [0x0000fffee79e6000,0x0000fffee7be4000], sp=0x0000fffee7bde510, free space=2017k
      Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
      V [libjvm.so+0x11e7a94] IdealLoopTree::verify_tree(IdealLoopTree*) const+0x6d4 (loopnode.hpp:470)
      V [libjvm.so+0x11e78a8] IdealLoopTree::verify_tree(IdealLoopTree*) const+0x4e8 (loopnode.cpp:5149)
      V [libjvm.so+0x11ea728] PhaseIdealLoop::verify() const+0x2d8 (loopnode.cpp:4926)
      V [libjvm.so+0x11eb30c] PhaseIdealLoop::build_and_optimize()+0xa4c (loopnode.cpp:4725)
      V [libjvm.so+0x930094] PhaseIdealLoop::optimize(PhaseIterGVN&, LoopOptsMode)+0x304 (loopnode.hpp:1115)
      V [libjvm.so+0x929b5c] Compile::optimize_loops(PhaseIterGVN&, LoopOptsMode)+0x68 (compile.cpp:2189)
      V [libjvm.so+0x1653c94] ShenandoahBarrierC2Support::expand(Compile*, PhaseIterGVN&)+0xd0 (shenandoahSupport.cpp:58)
      V [libjvm.so+0x1582554] ShenandoahBarrierSetC2::expand_barriers(Compile*, PhaseIterGVN&) const+0x14 (shenandoahBarrierSetC2.cpp:750)
      V [libjvm.so+0x92ba7c] Compile::Optimize()+0xcdc (compile.cpp:2465)
      V [libjvm.so+0x92e75c] Compile::Compile(ciEnv*, ciMethod*, int, Options, DirectiveSet*)+0x15a8 (compile.cpp:861)
      V [libjvm.so+0x77a838] C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x174 (c2compiler.cpp:142)
      V [libjvm.so+0x93b364] CompileBroker::invoke_compiler_on_method(CompileTask*)+0xab0 (compileBroker.cpp:2305)
      V [libjvm.so+0x93bf74] CompileBroker::compiler_thread_loop()+0x634 (compileBroker.cpp:1964)
      V [libjvm.so+0xdf3f70] JavaThread::thread_main_inner()+0xec (javaThread.cpp:721)
      V [libjvm.so+0x179d104] Thread::call_run()+0xb0 (thread.cpp:221)
      V [libjvm.so+0x13debb8] thread_native_entry(Thread*)+0x138 (os_linux.cpp:864)

      It only seems to happen with Shenandoah, not with other GCs. Also, I can easily reproduce the problem on linux-x86_64 and linux-aarch64, but not on macosx-aarch64.

      The assert seems to have started occuring with JDK-8309622, but I don't think this is the root cause of the problem.

        1. hs_err_pid2371025.log
          689 kB
          Roman Kennke
        2. replay_pid2371025.log
          201 kB
          Roman Kennke
        3. shen.xml
          4.92 MB
          Joshua Cao

            roland Roland Westrelin
            rkennke Roman Kennke
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: