aboutsummaryrefslogtreecommitdiff
path: root/gcc/optabs.c
diff options
context:
space:
mode:
authorAndy Hutchinson <hutchinsonandy@gcc.gnu.org>2009-10-17 22:42:17 +0000
committerAndy Hutchinson <hutchinsonandy@gcc.gnu.org>2009-10-17 22:42:17 +0000
commitdb826daef1ba627ef3b578a1ad577d864c290e71 (patch)
treefbe8728e5cecc3fc8b67fc5034710a9e700dd1d2 /gcc/optabs.c
parentd79c2936cbfadddc0928df9df1353613b708febf (diff)
downloadgcc-db826daef1ba627ef3b578a1ad577d864c290e71.zip
gcc-db826daef1ba627ef3b578a1ad577d864c290e71.tar.gz
gcc-db826daef1ba627ef3b578a1ad577d864c290e71.tar.bz2
re PR middle-end/41738 (optabs expands rotate using wrong mode)
2009-10-17 Andy Hutchinson <hutchinsonandy@gcc.gnu.org> PR middle-end/41738 * optabs.c (expand_binop): Make mode of shift count expression mode of shift count not target. Remove indent nit. From-SVN: r152961
Diffstat (limited to 'gcc/optabs.c')
-rw-r--r--gcc/optabs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/optabs.c b/gcc/optabs.c
index 1c13623..39257f5 100644
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -1595,11 +1595,11 @@ expand_binop (enum machine_mode mode, optab binoptab, rtx op0, rtx op1,
unsigned int bits = GET_MODE_BITSIZE (mode);
if (CONST_INT_P (op1))
- newop1 = GEN_INT (bits - INTVAL (op1));
+ newop1 = GEN_INT (bits - INTVAL (op1));
else if (targetm.shift_truncation_mask (mode) == bits - 1)
- newop1 = negate_rtx (mode, op1);
+ newop1 = negate_rtx (GET_MODE (op1), op1);
else
- newop1 = expand_binop (mode, sub_optab,
+ newop1 = expand_binop (GET_MODE (op1), sub_optab,
GEN_INT (bits), op1,
NULL_RTX, unsignedp, OPTAB_DIRECT);