src/hotspot/share/opto/superword.cpp
changeset 48145 f913f6dba2d3
parent 48136 c035fbb1beb4
child 48309 1a0499fd252e
--- a/src/hotspot/share/opto/superword.cpp	Tue Nov 28 21:04:42 2017 +0530
+++ b/src/hotspot/share/opto/superword.cpp	Tue Nov 28 11:59:16 2017 +0100
@@ -1353,6 +1353,7 @@
     for (DUIterator_Fast jmax, j = s2->fast_outs(jmax); j < jmax; j++) {
       Node* t2 = s2->fast_out(j);
       if (!in_bb(t2)) continue;
+      if (t2->Opcode() == Op_AddI && t2 == _lp->as_CountedLoop()->incr()) continue; // don't mess with the iv
       if (!opnd_positions_match(s1, t1, s2, t2))
         continue;
       if (stmts_can_pack(t1, t2, align)) {
@@ -3313,7 +3314,7 @@
     return NULL;
   }
 
-  Node* p_f = cl->in(LoopNode::EntryControl)->in(0)->in(0);
+  Node* p_f = cl->skip_strip_mined()->in(LoopNode::EntryControl)->in(0)->in(0);
   if (!p_f->is_IfFalse()) return NULL;
   if (!p_f->in(0)->is_CountedLoopEnd()) return NULL;
   CountedLoopEndNode* pre_end = p_f->in(0)->as_CountedLoopEnd();