aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Sandiford <rsandifo@redhat.com>2001-07-11 09:29:42 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2001-07-11 09:29:42 +0000
commitb87c8c8cf4656f91b7d65cb78d658155721ee39e (patch)
tree800730210b76a2bcf3ff7c6d5d38f779cc1b76ea
parent517c3b80599a3124852717bfb6611813b8f5738b (diff)
downloadgcc-b87c8c8cf4656f91b7d65cb78d658155721ee39e.zip
gcc-b87c8c8cf4656f91b7d65cb78d658155721ee39e.tar.gz
gcc-b87c8c8cf4656f91b7d65cb78d658155721ee39e.tar.bz2
mips.md (call_internal1): Use CONSTANT_ADDRESS_P to check for constant addresses.
* mips.md (call_internal1): Use CONSTANT_ADDRESS_P to check for constant addresses. (call_internal2): Likewise. (call_value_internal1): Likewise. (call_value_internal2): Likewise. (call_value_multiple_internal1): Likewise. (call_value_multiple_internal2): Likewise. Co-Authored-By: H.J. Lu <hjl@gnu.org> From-SVN: r43930
-rw-r--r--gcc/ChangeLog11
-rw-r--r--gcc/config/mips/mips.md36
2 files changed, 29 insertions, 18 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index b13c256..80d975c 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,14 @@
+2001-07-11 Richard Sandiford <rsandifo@redhat.com>
+ H.J. Lu <hjl@gnu.org>
+
+ * mips.md (call_internal1): Use CONSTANT_ADDRESS_P to check for
+ constant addresses.
+ (call_internal2): Likewise.
+ (call_value_internal1): Likewise.
+ (call_value_internal2): Likewise.
+ (call_value_multiple_internal1): Likewise.
+ (call_value_multiple_internal2): Likewise.
+
2001-07-10 Kazu Hirata <kazu@hxi.com>
* calls.c (emit_library_call_value_1): Fix a comment typo.
diff --git a/gcc/config/mips/mips.md b/gcc/config/mips/mips.md
index e77c295..d464910 100644
--- a/gcc/config/mips/mips.md
+++ b/gcc/config/mips/mips.md
@@ -9684,10 +9684,10 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[0];
- if (GET_CODE (target) == SYMBOL_REF)
- return \"%*jal\\t%0\";
- else if (GET_CODE (target) == CONST_INT)
+ if (GET_CODE (target) == CONST_INT)
return \"%[li\\t%@,%0\\n\\t%*jal\\t%2,%@%]\";
+ else if (CONSTANT_ADDRESS_P (target))
+ return \"%*jal\\t%0\";
else
return \"%*jal\\t%2,%0\";
}"
@@ -9703,15 +9703,15 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[0];
- if (GET_CODE (target) == SYMBOL_REF)
+ if (GET_CODE (target) == CONST_INT)
+ return \"li\\t%^,%0\\n\\tjal\\t%2,%^\";
+ else if (CONSTANT_ADDRESS_P (target))
{
if (GET_MODE (target) == SImode)
return \"la\\t%^,%0\\n\\tjal\\t%2,%^\";
else
return \"dla\\t%^,%0\\n\\tjal\\t%2,%^\";
}
- else if (GET_CODE (target) == CONST_INT)
- return \"li\\t%^,%0\\n\\tjal\\t%2,%^\";
else if (REGNO (target) != PIC_FUNCTION_ADDR_REGNUM)
return \"move\\t%^,%0\\n\\tjal\\t%2,%^\";
else
@@ -9891,10 +9891,10 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[1];
- if (GET_CODE (target) == SYMBOL_REF)
- return \"%*jal\\t%1\";
- else if (GET_CODE (target) == CONST_INT)
+ if (GET_CODE (target) == CONST_INT)
return \"%[li\\t%@,%1\\n\\t%*jal\\t%3,%@%]\";
+ else if (CONSTANT_ADDRESS_P (target))
+ return \"%*jal\\t%1\";
else
return \"%*jal\\t%3,%1\";
}"
@@ -9911,15 +9911,15 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[1];
- if (GET_CODE (target) == SYMBOL_REF)
+ if (GET_CODE (target) == CONST_INT)
+ return \"li\\t%^,%1\\n\\tjal\\t%3,%^\";
+ else if (CONSTANT_ADDRESS_P (target))
{
if (GET_MODE (target) == SImode)
return \"la\\t%^,%1\\n\\tjal\\t%3,%^\";
else
return \"dla\\t%^,%1\\n\\tjal\\t%3,%^\";
}
- else if (GET_CODE (target) == CONST_INT)
- return \"li\\t%^,%1\\n\\tjal\\t%3,%^\";
else if (REGNO (target) != PIC_FUNCTION_ADDR_REGNUM)
return \"move\\t%^,%1\\n\\tjal\\t%3,%^\";
else
@@ -10023,10 +10023,10 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[1];
- if (GET_CODE (target) == SYMBOL_REF)
- return \"%*jal\\t%1\";
- else if (GET_CODE (target) == CONST_INT)
+ if (GET_CODE (target) == CONST_INT)
return \"%[li\\t%@,%1\\n\\t%*jal\\t%4,%@%]\";
+ else if (CONSTANT_ADDRESS_P (target))
+ return \"%*jal\\t%1\";
else
return \"%*jal\\t%4,%1\";
}"
@@ -10046,15 +10046,15 @@ ld\\t%2,%1-%S1(%2)\;daddu\\t%2,%2,$31\;j\\t%2"
{
register rtx target = operands[1];
- if (GET_CODE (target) == SYMBOL_REF)
+ if (GET_CODE (target) == CONST_INT)
+ return \"li\\t%^,%1\\n\\tjal\\t%4,%^\";
+ else if (CONSTANT_ADDRESS_P (target))
{
if (GET_MODE (target) == SImode)
return \"la\\t%^,%1\\n\\tjal\\t%4,%^\";
else
return \"la\\t%^,%1\\n\\tjal\\t%4,%^\";
}
- else if (GET_CODE (target) == CONST_INT)
- return \"li\\t%^,%1\\n\\tjal\\t%4,%^\";
else if (REGNO (target) != PIC_FUNCTION_ADDR_REGNUM)
return \"move\\t%^,%1\\n\\tjal\\t%4,%^\";
else