src/share/vm/opto/gcm.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 6714694 Cdiff src/share/vm/opto/gcm.cpp

src/share/vm/opto/gcm.cpp

Print this page

        

*** 305,331 **** Block* mid = worklist.pop(); if (mid == early) continue; // stop searching here // Test and set the visited bit. if (mid->raise_LCA_visited() == mark) continue; // already visited - mid->set_raise_LCA_visited(mark); // Don't process the current LCA, otherwise the search may terminate early if (mid != LCA && mid->raise_LCA_mark() == mark) { // Raise the LCA. LCA = mid->dom_lca(LCA); if (LCA == early) break; // stop searching everywhere assert(early->dominates(LCA), "early is high enough"); // Resume searching at that point, skipping intermediate levels. worklist.push(LCA); } else { // Keep searching through this block's predecessors. for (uint j = 1, jmax = mid->num_preds(); j < jmax; j++) { Block* mid_parent = bbs[ mid->pred(j)->_idx ]; worklist.push(mid_parent); } } } return LCA; } //--------------------------memory_early_block-------------------------------- --- 305,333 ---- Block* mid = worklist.pop(); if (mid == early) continue; // stop searching here // Test and set the visited bit. if (mid->raise_LCA_visited() == mark) continue; // already visited // Don't process the current LCA, otherwise the search may terminate early if (mid != LCA && mid->raise_LCA_mark() == mark) { // Raise the LCA. LCA = mid->dom_lca(LCA); if (LCA == early) break; // stop searching everywhere assert(early->dominates(LCA), "early is high enough"); // Resume searching at that point, skipping intermediate levels. worklist.push(LCA); + if (LCA == mid) + continue; // Don't mark as visited to avoid early termination. } else { // Keep searching through this block's predecessors. for (uint j = 1, jmax = mid->num_preds(); j < jmax; j++) { Block* mid_parent = bbs[ mid->pred(j)->_idx ]; worklist.push(mid_parent); } } + mid->set_raise_LCA_visited(mark); } return LCA; } //--------------------------memory_early_block--------------------------------
src/share/vm/opto/gcm.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File