diff src/share/vm/opto/memnode.cpp @ 4064:670a74b863fc

7107042: assert(no_dead_loop) failed: dead loop detected Summary: Use dead nodes elimination code in PhaseIdealLoop before executing EA. Reviewed-by: never, twisti
author kvn
date Wed, 09 Nov 2011 07:25:51 -0800
parents a92cdbac8b9e
children 1bd45abaa507
line wrap: on
line diff
--- a/src/share/vm/opto/memnode.cpp	Wed Nov 09 06:14:32 2011 -0800
+++ b/src/share/vm/opto/memnode.cpp	Wed Nov 09 07:25:51 2011 -0800
@@ -1421,6 +1421,12 @@
     const TypeOopPtr *t_oop = addr_t->isa_oopptr();
     if (can_reshape && opt_mem->is_Phi() &&
         (t_oop != NULL) && t_oop->is_known_instance_field()) {
+      PhaseIterGVN *igvn = phase->is_IterGVN();
+      if (igvn != NULL && igvn->_worklist.member(opt_mem)) {
+        // Delay this transformation until memory Phi is processed.
+        phase->is_IterGVN()->_worklist.push(this);
+        return NULL;
+      }
       // Split instance field load through Phi.
       Node* result = split_through_phi(phase);
       if (result != NULL) return result;