提交 4dd0d07a 编写于 作者: T thartmann

8145754: PhaseIdealLoop::is_scaled_iv_plus_offset() does not match AddI

Summary: is_scaled_iv_plus_offset() should handle AddI nodes with scaled iv as second input.
Reviewed-by: kvn
上级 d3324c9f
...@@ -1739,6 +1739,12 @@ bool PhaseIdealLoop::is_scaled_iv_plus_offset(Node* exp, Node* iv, int* p_scale, ...@@ -1739,6 +1739,12 @@ bool PhaseIdealLoop::is_scaled_iv_plus_offset(Node* exp, Node* iv, int* p_scale,
} }
return true; return true;
} }
if (is_scaled_iv(exp->in(2), iv, p_scale)) {
if (p_offset != NULL) {
*p_offset = exp->in(1);
}
return true;
}
if (exp->in(2)->is_Con()) { if (exp->in(2)->is_Con()) {
Node* offset2 = NULL; Node* offset2 = NULL;
if (depth < 2 && if (depth < 2 &&
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册