8078866: compiler/eliminateAutobox/6934604/TestIntBoxing.java assert(p_f->Opcode() == Op_IfFalse) failed
authorroland
Thu, 04 Jun 2015 16:19:22 +0200
changeset 31131 d92082b3ef93
parent 31130 569635143654
child 31132 328ac96a30d6
8078866: compiler/eliminateAutobox/6934604/TestIntBoxing.java assert(p_f->Opcode() == Op_IfFalse) failed Summary: Bail out from range check elimination if pre loop is not found Reviewed-by: kvn
hotspot/src/share/vm/opto/loopTransform.cpp
--- a/hotspot/src/share/vm/opto/loopTransform.cpp	Thu Jun 04 19:24:47 2015 -0700
+++ b/hotspot/src/share/vm/opto/loopTransform.cpp	Thu Jun 04 16:19:22 2015 +0200
@@ -1914,7 +1914,10 @@
   // Find the pre-loop limit; we will expand it's iterations to
   // not ever trip low tests.
   Node *p_f = iffm->in(0);
-  assert(p_f->Opcode() == Op_IfFalse, "");
+  // pre loop may have been optimized out
+  if (p_f->Opcode() != Op_IfFalse) {
+    return;
+  }
   CountedLoopEndNode *pre_end = p_f->in(0)->as_CountedLoopEnd();
   assert(pre_end->loopnode()->is_pre_loop(), "");
   Node *pre_opaq1 = pre_end->limit();