diff options
author | James E Wilson <wilson@specifixinc.com> | 2003-12-08 22:39:51 +0000 |
---|---|---|
committer | Jim Wilson <wilson@gcc.gnu.org> | 2003-12-08 14:39:51 -0800 |
commit | 367d6d0bd7ed19555dde48d89b347cd91458cc23 (patch) | |
tree | 87fb22ff5577142cb874737eef2278cf374a2ac5 /gcc | |
parent | 8bb1e63ec78e08832a0f3a2a87496479df182140 (diff) | |
download | gcc-367d6d0bd7ed19555dde48d89b347cd91458cc23.zip gcc-367d6d0bd7ed19555dde48d89b347cd91458cc23.tar.gz gcc-367d6d0bd7ed19555dde48d89b347cd91458cc23.tar.bz2 |
Fix IA-64 glibc ICE PR target/13132
Fix IA-64 glibc ICE
PR target/13132
* expmed.c (extract_bit_field): Only call mode_for_size for scalar
integer modes.
From-SVN: r74443
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/expmed.c | 13 |
2 files changed, 15 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index ee25029..4e39db5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2003-12-08 James E Wilson <wilson@specifixinc.com> + + PR target/13132 + * expmed.c (extract_bit_field): Only call mode_for_size for scalar + integer modes. + 2003-12-08 Nathanael Nerode <neroden@gcc.gnu.org> * doc/install.texi: Revert change of Dec 7; gcc is still a 2.13 diff --git a/gcc/expmed.c b/gcc/expmed.c index d93be93..98a26a1 100644 --- a/gcc/expmed.c +++ b/gcc/expmed.c @@ -1079,13 +1079,18 @@ extract_bit_field (rtx str_rtx, unsigned HOST_WIDE_INT bitsize, If that's wrong, the solution is to test for it and set TARGET to 0 if needed. */ - mode1 = (VECTOR_MODE_P (tmode) - ? mode - : mode_for_size (bitsize, GET_MODE_CLASS (tmode), 0)); + /* Only scalar integer modes can be converted via subregs. There is an + additional problem for FP modes here in that they can have a precision + which is different from the size. mode_for_size uses precision, but + we want a mode based on the size, so we must avoid calling it for FP + modes. */ + mode1 = (SCALAR_INT_MODE_P (tmode) + ? mode_for_size (bitsize, GET_MODE_CLASS (tmode), 0) + : mode); if (((bitsize >= BITS_PER_WORD && bitsize == GET_MODE_BITSIZE (mode) && bitpos % BITS_PER_WORD == 0) - || (mode_for_size (bitsize, GET_MODE_CLASS (tmode), 0) != BLKmode + || (mode1 != BLKmode /* ??? The big endian test here is wrong. This is correct if the value is in a register, and if mode_for_size is not the same mode as op0. This causes us to get unnecessarily |