aboutsummaryrefslogtreecommitdiff
path: root/gcc/expmed.c
diff options
context:
space:
mode:
authorJeff Law <law@gcc.gnu.org>1998-04-04 06:32:39 -0700
committerJeff Law <law@gcc.gnu.org>1998-04-04 06:32:39 -0700
commite5e809f4194e578b5fbd48fc5a1df2377f28d197 (patch)
tree6743f11e58bd7a933b08900d973d89026cd11c43 /gcc/expmed.c
parent31031eddacda46a500b2390f52cd4474bcaf84ca (diff)
downloadgcc-e5e809f4194e578b5fbd48fc5a1df2377f28d197.zip
gcc-e5e809f4194e578b5fbd48fc5a1df2377f28d197.tar.gz
gcc-e5e809f4194e578b5fbd48fc5a1df2377f28d197.tar.bz2
* Check in merge from gcc2. See ChangeLog.11 and ChangeLog.12
for details. * haifa-sched.c: Mirror recent changes from gcc2. From-SVN: r18984
Diffstat (limited to 'gcc/expmed.c')
-rw-r--r--gcc/expmed.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/gcc/expmed.c b/gcc/expmed.c
index 7ac64c6..8f0ba07 100644
--- a/gcc/expmed.c
+++ b/gcc/expmed.c
@@ -1,6 +1,6 @@
/* Medium-level subroutines: convert bit-field store and extract
and shifts, multiplies and divides to rtl instructions.
- Copyright (C) 1987, 88, 89, 92-6, 1997 Free Software Foundation, Inc.
+ Copyright (C) 1987, 88, 89, 92-97, 1998 Free Software Foundation, Inc.
This file is part of GNU CC.
@@ -907,6 +907,8 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp,
offset += SUBREG_WORD (op0);
+ inner_size = MIN (inner_size, BITS_PER_WORD);
+
if (BYTES_BIG_ENDIAN && (outer_size < inner_size))
{
bitpos += inner_size - outer_size;
@@ -1076,7 +1078,7 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp,
{
int xbitpos = bitpos, xoffset = offset;
rtx bitsize_rtx, bitpos_rtx;
- rtx last = get_last_insn();
+ rtx last = get_last_insn ();
rtx xop0 = op0;
rtx xtarget = target;
rtx xspec_target = spec_target;
@@ -1140,7 +1142,7 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp,
/* If op0 is a register, we need it in MAXMODE (which is usually
SImode). to make it acceptable to the format of extzv. */
if (GET_CODE (xop0) == SUBREG && GET_MODE (xop0) != maxmode)
- abort ();
+ goto extzv_loses;
if (GET_CODE (xop0) == REG && GET_MODE (xop0) != maxmode)
xop0 = gen_rtx_SUBREG (maxmode, xop0, 0);
@@ -1216,7 +1218,7 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp,
{
int xbitpos = bitpos, xoffset = offset;
rtx bitsize_rtx, bitpos_rtx;
- rtx last = get_last_insn();
+ rtx last = get_last_insn ();
rtx xop0 = op0, xtarget = target;
rtx xspec_target = spec_target;
rtx xspec_target_subreg = spec_target_subreg;
@@ -1274,7 +1276,7 @@ extract_bit_field (str_rtx, bitsize, bitnum, unsignedp,
/* If op0 is a register, we need it in MAXMODE (which is usually
SImode) to make it acceptable to the format of extv. */
if (GET_CODE (xop0) == SUBREG && GET_MODE (xop0) != maxmode)
- abort ();
+ goto extv_loses;
if (GET_CODE (xop0) == REG && GET_MODE (xop0) != maxmode)
xop0 = gen_rtx_SUBREG (maxmode, xop0, 0);