summaryrefslogtreecommitdiffstats
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authoramylaar <amylaar@138bc75d-0d04-0410-961f-82ee72b054a4>2005-07-26 14:58:43 +0000
committeramylaar <amylaar@138bc75d-0d04-0410-961f-82ee72b054a4>2005-07-26 14:58:43 +0000
commit6c799a83c8fba7edb02964d6925bef201217f8a8 (patch)
treeebac3b891d58e82daa28c21077485ff2f5c39bd2 /gcc/emit-rtl.c
parent7f0dae42e1e3b6b5d12f340842eb8477ced6887f (diff)
downloadppe42-gcc-6c799a83c8fba7edb02964d6925bef201217f8a8.tar.gz
ppe42-gcc-6c799a83c8fba7edb02964d6925bef201217f8a8.zip
* emit-rtl.c (gen_lowpart_common): Compare size of MODE in bits
(rather than units) against HOST_BITS_PER_WIDE_INT. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@102387 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index fc34f6ecb51..ba3ae57dcba 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -1118,7 +1118,8 @@ gen_lowpart_common (enum machine_mode mode, rtx x)
/* Unfortunately, this routine doesn't take a parameter for the mode of X,
so we have to make one up. Yuk. */
innermode = GET_MODE (x);
- if (GET_CODE (x) == CONST_INT && msize <= HOST_BITS_PER_WIDE_INT)
+ if (GET_CODE (x) == CONST_INT
+ && msize * BITS_PER_UNIT <= HOST_BITS_PER_WIDE_INT)
innermode = mode_for_size (HOST_BITS_PER_WIDE_INT, MODE_INT, 0);
else if (innermode == VOIDmode)
innermode = mode_for_size (HOST_BITS_PER_WIDE_INT * 2, MODE_INT, 0);
OpenPOWER on IntegriCloud