aboutsummaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1996-10-23 17:15:58 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1996-10-23 17:15:58 -0400
commita80586cc2a2c1f718c38dbe38e38b18b5b5469bf (patch)
tree72348e8eb35ee35e879bd9fbecb3a58b7c24344a /gcc/emit-rtl.c
parent059c3d849e4cabccbe6d36710f903986c55bd1fb (diff)
downloadgcc-a80586cc2a2c1f718c38dbe38e38b18b5b5469bf.zip
gcc-a80586cc2a2c1f718c38dbe38e38b18b5b5469bf.tar.gz
gcc-a80586cc2a2c1f718c38dbe38e38b18b5b5469bf.tar.bz2
(gen_lowpart_common): When converting a floating point value into an
integer, use WORD as (first) word. From-SVN: r13011
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index 522b95f..337e973 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -811,7 +811,7 @@ gen_lowpart_common (mode, x)
&& GET_CODE (x) == CONST_DOUBLE
&& GET_MODE_CLASS (GET_MODE (x)) == MODE_FLOAT
&& GET_MODE_BITSIZE (mode) == BITS_PER_WORD)
- return operand_subword (x, 0, 0, GET_MODE (x));
+ return operand_subword (x, word, 0, GET_MODE (x));
/* Similarly, if this is converting a floating-point value into a
two-word integer, we can do this one word at a time and make an
@@ -827,8 +827,10 @@ gen_lowpart_common (mode, x)
&& GET_MODE_CLASS (GET_MODE (x)) == MODE_FLOAT
&& GET_MODE_BITSIZE (mode) == 2 * BITS_PER_WORD)
{
- rtx lowpart = operand_subword (x, WORDS_BIG_ENDIAN, 0, GET_MODE (x));
- rtx highpart = operand_subword (x, ! WORDS_BIG_ENDIAN, 0, GET_MODE (x));
+ rtx lowpart
+ = operand_subword (x, word + WORDS_BIG_ENDIAN, 0, GET_MODE (x));
+ rtx highpart
+ = operand_subword (x, word + ! WORDS_BIG_ENDIAN, 0, GET_MODE (x));
if (lowpart && GET_CODE (lowpart) == CONST_INT
&& highpart && GET_CODE (highpart) == CONST_INT)