diff options
author | Jakub Jelinek <jakub@redhat.com> | 2018-01-20 10:54:06 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2018-01-20 10:54:06 +0100 |
commit | 09cbbded0d197f2da4f01be6f90c8535474b8200 (patch) | |
tree | 4d6b788cd8b16520ee399d6ae4558099799e7a26 /gcc/simplify-rtx.c | |
parent | f18fee823bb765b1efab04025d28fcf9315fb80b (diff) | |
download | gcc-09cbbded0d197f2da4f01be6f90c8535474b8200.zip gcc-09cbbded0d197f2da4f01be6f90c8535474b8200.tar.gz gcc-09cbbded0d197f2da4f01be6f90c8535474b8200.tar.bz2 |
re PR target/83930 (ICE: RTL check: expected code 'const_int', have 'mem' in simplify_binary_operation_1, at simplify-rtx.c:3302)
PR target/83930
* simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
UINTVAL (trueop1) instead of INTVAL (op1).
* gcc.dg/pr83930.c: New test.
From-SVN: r256915
Diffstat (limited to 'gcc/simplify-rtx.c')
-rw-r--r-- | gcc/simplify-rtx.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/simplify-rtx.c b/gcc/simplify-rtx.c index b0a0178..2e7aa5c 100644 --- a/gcc/simplify-rtx.c +++ b/gcc/simplify-rtx.c @@ -3411,7 +3411,8 @@ simplify_binary_operation_1 (enum rtx_code code, machine_mode mode, if (CONST_INT_P (trueop1) && exact_log2 (UINTVAL (trueop1)) > 0) return simplify_gen_binary (AND, mode, op0, - gen_int_mode (INTVAL (op1) - 1, mode)); + gen_int_mode (UINTVAL (trueop1) - 1, + mode)); break; case MOD: |