changeset 23014:84d55f179e24

8079343: Crash in PhaseIdealLoop with "assert(!had_error) failed: bad dominance" Summary: C2 should not try to vectorize loops with loop variant vector base address. Reviewed-by: kvn
author thartmann
date Mon, 11 May 2015 07:44:46 +0200
parents a1b5fe34c604
children 95dbbc0431d9
files src/share/vm/opto/superword.cpp
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/opto/superword.cpp	Thu Apr 02 17:16:39 2015 -0700
+++ b/src/share/vm/opto/superword.cpp	Mon May 11 07:44:46 2015 +0200
@@ -2249,6 +2249,11 @@
   }
   // Match AddP(base, AddP(ptr, k*iv [+ invariant]), constant)
   Node* base = adr->in(AddPNode::Base);
+  // The base address should be loop invariant
+  if (!invariant(base)) {
+    assert(!valid(), "base address is loop variant");
+    return;
+  }
   //unsafe reference could not be aligned appropriately without runtime checking
   if (base == NULL || base->bottom_type() == Type::TOP) {
     assert(!valid(), "unsafe access");