8213779: Loop opts anti dependent store detection should ignore uncommon trap calls

Reviewed-by: kvn
This commit is contained in:
Roland Westrelin 2018-11-13 09:59:50 +01:00
parent 63b433923c
commit b146cbfc10
2 changed files with 2 additions and 2 deletions

View File

@ -1551,7 +1551,6 @@ Node* IfNode::search_identical(int dist) {
// Search up the dominator tree for an If with an identical test
while (dom->Opcode() != op || // Not same opcode?
dom->in(1) != in(1) || // Not same input 1?
(req() == 3 && dom->in(2) != in(2)) || // Not same input 2?
prev_dom->in(0) != dom) { // One path of test does not dominate?
if (dist < 0) return NULL;

View File

@ -3910,7 +3910,8 @@ Node *PhaseIdealLoop::get_late_ctrl( Node *n, Node *early ) {
}
while(worklist.size() != 0 && LCA != early) {
Node* s = worklist.pop();
if (s->is_Load() || s->Opcode() == Op_SafePoint) {
if (s->is_Load() || s->Opcode() == Op_SafePoint ||
(s->is_CallStaticJava() && s->as_CallStaticJava()->uncommon_trap_request() != 0)) {
continue;
} else if (s->is_MergeMem()) {
for (DUIterator_Fast imax, i = s->fast_outs(imax); i < imax; i++) {