src/hotspot/share/opto/superword.cpp
changeset 50588 1ab701eb7de4
parent 49905 a09af8ef8e5c
child 51017 dd7ce84016a5
--- a/src/hotspot/share/opto/superword.cpp	Fri Jun 15 16:44:41 2018 +0200
+++ b/src/hotspot/share/opto/superword.cpp	Fri Jun 15 08:28:08 2018 -0700
@@ -887,7 +887,9 @@
   if (init_nd->is_Con() && p.invar() == NULL) {
     int init = init_nd->bottom_type()->is_int()->get_con();
     int init_offset = init * p.scale_in_bytes() + offset;
-    assert(init_offset >= 0, "positive offset from object start");
+    if (init_offset < 0) { // negative offset from object start?
+      return false;        // may happen in dead loop
+    }
     if (vw % span == 0) {
       // If vm is a multiple of span, we use formula (1).
       if (span > 0) {