Mercurial > hg > graal-compiler
comparison src/share/vm/opto/macro.cpp @ 1621:6027dddc26c6
6677629: PhaseIterGVN::subsume_node() should call hash_delete() and add_users_to_worklist()
Summary: Use replace_node() method instead of subsume_node().
Reviewed-by: jrose, never
author | kvn |
---|---|
date | Mon, 28 Jun 2010 14:54:39 -0700 |
parents | 4311f23817fd |
children | e5dfb3ccb88b |
comparison
equal
deleted
inserted
replaced
1620:d678e3277048 | 1621:6027dddc26c6 |
---|---|
133 copy_predefined_input_for_runtime_call(slow_path, oldcall, call ); | 133 copy_predefined_input_for_runtime_call(slow_path, oldcall, call ); |
134 if (parm0 != NULL) call->init_req(TypeFunc::Parms+0, parm0); | 134 if (parm0 != NULL) call->init_req(TypeFunc::Parms+0, parm0); |
135 if (parm1 != NULL) call->init_req(TypeFunc::Parms+1, parm1); | 135 if (parm1 != NULL) call->init_req(TypeFunc::Parms+1, parm1); |
136 copy_call_debug_info(oldcall, call); | 136 copy_call_debug_info(oldcall, call); |
137 call->set_cnt(PROB_UNLIKELY_MAG(4)); // Same effect as RC_UNCOMMON. | 137 call->set_cnt(PROB_UNLIKELY_MAG(4)); // Same effect as RC_UNCOMMON. |
138 _igvn.hash_delete(oldcall); | 138 _igvn.replace_node(oldcall, call); |
139 _igvn.subsume_node(oldcall, call); | |
140 transform_later(call); | 139 transform_later(call); |
141 | 140 |
142 return call; | 141 return call; |
143 } | 142 } |
144 | 143 |
521 return phi; | 520 return phi; |
522 } else { | 521 } else { |
523 // Kill all new Phis | 522 // Kill all new Phis |
524 while(value_phis.is_nonempty()) { | 523 while(value_phis.is_nonempty()) { |
525 Node* n = value_phis.node(); | 524 Node* n = value_phis.node(); |
526 _igvn.hash_delete(n); | 525 _igvn.replace_node(n, C->top()); |
527 _igvn.subsume_node(n, C->top()); | |
528 value_phis.pop(); | 526 value_phis.pop(); |
529 } | 527 } |
530 } | 528 } |
531 } | 529 } |
532 } | 530 } |
1309 // allocate node with the call | 1307 // allocate node with the call |
1310 copy_call_debug_info((CallNode *) alloc, call); | 1308 copy_call_debug_info((CallNode *) alloc, call); |
1311 if (!always_slow) { | 1309 if (!always_slow) { |
1312 call->set_cnt(PROB_UNLIKELY_MAG(4)); // Same effect as RC_UNCOMMON. | 1310 call->set_cnt(PROB_UNLIKELY_MAG(4)); // Same effect as RC_UNCOMMON. |
1313 } | 1311 } |
1314 _igvn.hash_delete(alloc); | 1312 _igvn.replace_node(alloc, call); |
1315 _igvn.subsume_node(alloc, call); | |
1316 transform_later(call); | 1313 transform_later(call); |
1317 | 1314 |
1318 // Identify the output projections from the allocate node and | 1315 // Identify the output projections from the allocate node and |
1319 // adjust any references to them. | 1316 // adjust any references to them. |
1320 // The control and io projections look like: | 1317 // The control and io projections look like: |