summaryrefslogtreecommitdiff
path: root/gcc/expmed.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/expmed.c')
-rw-r--r--gcc/expmed.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/expmed.c b/gcc/expmed.c
index 9ee5f29883d..da0db3b8347 100644
--- a/gcc/expmed.c
+++ b/gcc/expmed.c
@@ -2136,7 +2136,8 @@ expand_shift (enum tree_code code, enum machine_mode mode, rtx shifted,
op1 = GEN_INT ((unsigned HOST_WIDE_INT) INTVAL (op1)
% GET_MODE_BITSIZE (mode));
else if (GET_CODE (op1) == SUBREG
- && subreg_lowpart_p (op1))
+ && subreg_lowpart_p (op1)
+ && INTEGRAL_MODE_P (GET_MODE (SUBREG_REG (op1))))
op1 = SUBREG_REG (op1);
}