comparison src/share/vm/opto/coalesce.cpp @ 12075:4b2838704fd5

8021898: Broken JIT compiler optimization for loop unswitching Summary: fix method clone_projs() to clone all related MachProj nodes. Reviewed-by: roland, adlertz
author kvn
date Fri, 16 Aug 2013 14:11:40 -0700
parents adb9a7d94cb5
children 650868c062a9
comparison
equal deleted inserted replaced
12074:d18b10b1fd09 12075:4b2838704fd5
320 if(m->is_Mach() && m->as_Mach()->is_Con() && 320 if(m->is_Mach() && m->as_Mach()->is_Con() &&
321 m->as_Mach()->rematerialize()) { 321 m->as_Mach()->rematerialize()) {
322 copy = m->clone(); 322 copy = m->clone();
323 // Insert the copy in the basic block, just before us 323 // Insert the copy in the basic block, just before us
324 b->_nodes.insert(l++, copy); 324 b->_nodes.insert(l++, copy);
325 if(_phc.clone_projs(b, l, m, copy, _phc._lrg_map)) { 325 l += _phc.clone_projs(b, l, m, copy, _phc._lrg_map);
326 l++;
327 }
328 } else { 326 } else {
329 const RegMask *rm = C->matcher()->idealreg2spillmask[m->ideal_reg()]; 327 const RegMask *rm = C->matcher()->idealreg2spillmask[m->ideal_reg()];
330 copy = new (C) MachSpillCopyNode(m, *rm, *rm); 328 copy = new (C) MachSpillCopyNode(m, *rm, *rm);
331 // Insert the copy in the basic block, just before us 329 // Insert the copy in the basic block, just before us
332 b->_nodes.insert(l++, copy); 330 b->_nodes.insert(l++, copy);