diff options
author | Bernd Schmidt <bernd.schmidt@analog.com> | 2009-04-24 11:05:59 +0000 |
---|---|---|
committer | Bernd Schmidt <bernds@gcc.gnu.org> | 2009-04-24 11:05:59 +0000 |
commit | ce72fe6cf0447b114c9cb60fd9c21bedfaad3fbe (patch) | |
tree | a4c8b6b2eb7f1563805ebb8e5a2e22ecef78b9a2 /gcc/loop-iv.c | |
parent | f63426afd8ce57a1148d5c6cfbe369be2a870e8b (diff) | |
download | gcc-ce72fe6cf0447b114c9cb60fd9c21bedfaad3fbe.zip gcc-ce72fe6cf0447b114c9cb60fd9c21bedfaad3fbe.tar.gz gcc-ce72fe6cf0447b114c9cb60fd9c21bedfaad3fbe.tar.bz2 |
loop-iv.c (simple_rhs_p): Allow expressions that are function_invariant_p.
* loop-iv.c (simple_rhs_p): Allow expressions that are
function_invariant_p.
From-SVN: r146701
Diffstat (limited to 'gcc/loop-iv.c')
-rw-r--r-- | gcc/loop-iv.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/loop-iv.c b/gcc/loop-iv.c index 23ece7e..be7fda8 100644 --- a/gcc/loop-iv.c +++ b/gcc/loop-iv.c @@ -1341,10 +1341,10 @@ simple_rhs_p (rtx rhs) op1 = XEXP (rhs, 1); /* Allow reg OP const and reg OP reg. */ if (!(REG_P (op0) && !HARD_REGISTER_P (op0)) - && !CONSTANT_P (op0)) + && !function_invariant_p (op0)) return false; if (!(REG_P (op1) && !HARD_REGISTER_P (op1)) - && !CONSTANT_P (op1)) + && !function_invariant_p (op1)) return false; return true; @@ -1358,7 +1358,7 @@ simple_rhs_p (rtx rhs) /* Allow reg OP const. */ if (!(REG_P (op0) && !HARD_REGISTER_P (op0))) return false; - if (!CONSTANT_P (op1)) + if (!function_invariant_p (op1)) return false; return true; |