hotspot/src/share/vm/opto/phaseX.cpp
changeset 3682 42de755d7d6e
parent 2131 98f9cef66a34
child 4012 579b7bad9983
child 3795 6227ff014cfe
--- a/hotspot/src/share/vm/opto/phaseX.cpp	Mon Aug 17 09:48:02 2009 -0700
+++ b/hotspot/src/share/vm/opto/phaseX.cpp	Mon Aug 17 12:11:06 2009 -0700
@@ -1622,9 +1622,11 @@
   // old goes dead?
   if( old ) {
     switch (old->outcnt()) {
-    case 0:      // Kill all his inputs, and recursively kill other dead nodes.
+    case 0:
+      // Put into the worklist to kill later. We do not kill it now because the
+      // recursive kill will delete the current node (this) if dead-loop exists
       if (!old->is_top())
-        igvn->remove_dead_node( old );
+        igvn->_worklist.push( old );
       break;
     case 1:
       if( old->is_Store() || old->has_special_unique_user() )