aboutsummaryrefslogtreecommitdiff
path: root/gcc/combine.c
diff options
context:
space:
mode:
authorKazu Hirata <kazu@hxi.com>2002-01-10 18:30:00 +0000
committerKazu Hirata <kazu@gcc.gnu.org>2002-01-10 18:30:00 +0000
commit47073a382432479b397a1654da5a24354e3f368a (patch)
tree93122b4b40461c9713c371f3ca33eb3d53843985 /gcc/combine.c
parentd288e53d0c83a81e8001d3661b4bfc455c1ebb18 (diff)
downloadgcc-47073a382432479b397a1654da5a24354e3f368a.zip
gcc-47073a382432479b397a1654da5a24354e3f368a.tar.gz
gcc-47073a382432479b397a1654da5a24354e3f368a.tar.bz2
* combine.c (expand_field_assignment): Use subreg_lsb().
From-SVN: r48742
Diffstat (limited to 'gcc/combine.c')
-rw-r--r--gcc/combine.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/gcc/combine.c b/gcc/combine.c
index 1215a65..7421a33 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -5685,11 +5685,9 @@ expand_field_assignment (x)
if (GET_CODE (SET_DEST (x)) == STRICT_LOW_PART
&& GET_CODE (XEXP (SET_DEST (x), 0)) == SUBREG)
{
- int byte_offset = SUBREG_BYTE (XEXP (SET_DEST (x), 0));
-
inner = SUBREG_REG (XEXP (SET_DEST (x), 0));
len = GET_MODE_BITSIZE (GET_MODE (XEXP (SET_DEST (x), 0)));
- pos = GEN_INT (BITS_PER_WORD * (byte_offset / UNITS_PER_WORD));
+ pos = GEN_INT (subreg_lsb (XEXP (SET_DEST (x), 0)));
}
else if (GET_CODE (SET_DEST (x)) == ZERO_EXTRACT
&& GET_CODE (XEXP (SET_DEST (x), 1)) == CONST_INT)