diff options
author | Jeff Law <law@gcc.gnu.org> | 1997-09-07 16:10:34 -0600 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 1997-09-07 16:10:34 -0600 |
commit | db7cafb0ad510fe38d0e2ad0ccc5149acaaad65c (patch) | |
tree | 25672ec82aee28c93d020853108c2a4fb25566e1 /gcc/expmed.c | |
parent | a051ad3aea8f7e346d9ff7a0c921686ed9ae5c33 (diff) | |
download | gcc-db7cafb0ad510fe38d0e2ad0ccc5149acaaad65c.zip gcc-db7cafb0ad510fe38d0e2ad0ccc5149acaaad65c.tar.gz gcc-db7cafb0ad510fe38d0e2ad0ccc5149acaaad65c.tar.bz2 |
version.c: Bump for snapshot.
* version.c: Bump for snapshot.
* expmed.c (expand_divmod): Make op1_is_pow2 depend on unsignedp
for negative constants. Promote EXACT_DIV_EXPR to TRUNC_DIV_EXPR
when op1_is_pow2.
* final.c (shorten_branches): During first pass, assume worst
possible alignment for ADDR_VEC and ADDR_VEC_DIFF insns.
* Makefile.in (distclean): Remove various things left around
by running the testsuite.
From-SVN: r15136
Diffstat (limited to 'gcc/expmed.c')
-rw-r--r-- | gcc/expmed.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/expmed.c b/gcc/expmed.c index 291e8d4..fa3cc49 100644 --- a/gcc/expmed.c +++ b/gcc/expmed.c @@ -2718,7 +2718,7 @@ expand_divmod (rem_flag, code, mode, op0, op1, target, unsignedp) op1_is_constant = GET_CODE (op1) == CONST_INT; op1_is_pow2 = (op1_is_constant && ((EXACT_POWER_OF_2_OR_ZERO_P (INTVAL (op1)) - || EXACT_POWER_OF_2_OR_ZERO_P (-INTVAL (op1))))); + || (! unsignedp && EXACT_POWER_OF_2_OR_ZERO_P (-INTVAL (op1)))))); /* This is the structure of expand_divmod: @@ -2854,6 +2854,8 @@ expand_divmod (rem_flag, code, mode, op0, op1, target, unsignedp) code = TRUNC_DIV_EXPR; if (code == FLOOR_MOD_EXPR) code = TRUNC_MOD_EXPR; + if (code == EXACT_DIV_EXPR && op1_is_pow2) + code = TRUNC_DIV_EXPR; } if (op1 != const0_rtx) |