diff options
author | wilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4> | 1996-06-27 22:48:57 +0000 |
---|---|---|
committer | wilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4> | 1996-06-27 22:48:57 +0000 |
commit | 8f306682e6f467684fa80ad681f8bde7f49eb997 (patch) | |
tree | 262c8eaaa5b7af2cbe3f352509870fc5b5c79b14 /gcc/expmed.c | |
parent | f898212fae7a25b946a760331bce9e3d17cc0bea (diff) | |
download | gcc-8f306682e6f467684fa80ad681f8bde7f49eb997.tar.gz |
(extract_bit_field): Check TRULY_NOOP_TRUNCATION before
making a SUBREG of a REG.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@12338 138bc75d-0d04-0410-961f-82ee72b054a4
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 be27f855ae8..a5939423034 100644 --- a/gcc/expmed.c +++ b/gcc/expmed.c @@ -928,7 +928,9 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp, So too extracting a subword value in the least significant part of the register. */ - if ((GET_CODE (op0) == REG + if (((GET_CODE (op0) == REG + && TRULY_NOOP_TRUNCATION (GET_MODE_BITSIZE (mode), + GET_MODE_BITSIZE (GET_MODE (op0)))) || (GET_CODE (op0) == MEM && (! SLOW_UNALIGNED_ACCESS || (offset * BITS_PER_UNIT % bitsize == 0 |