summaryrefslogtreecommitdiff
path: root/gcc/combine.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>1999-11-28 09:08:02 +0100
committerJeff Law <law@gcc.gnu.org>1999-11-28 01:08:02 -0700
commitc285f57a299b0bb73d929bd68c0a083deaebd5d8 (patch)
tree318e3e4a5abeae8e4c30c10c28ada0ede68f002b /gcc/combine.c
parent3fad8d4ad6bdd045e2429eed20e80483c1a1c5e5 (diff)
downloadgcc-c285f57a299b0bb73d929bd68c0a083deaebd5d8.tar.gz
combine.c (setup_incoming_promotions): Pass an outgoing regno to FUNCTION_ARG_REGNO_P which it expects.
* combine.c (setup_incoming_promotions): Pass an outgoing regno to FUNCTION_ARG_REGNO_P which it expects. From-SVN: r30685
Diffstat (limited to 'gcc/combine.c')
-rw-r--r--gcc/combine.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/combine.c b/gcc/combine.c
index d028a93f9dc..8f14d7df927 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -768,8 +768,14 @@ setup_incoming_promotions ()
int unsignedp;
rtx first = get_insns ();
+#ifndef OUTGOING_REGNO
+#define OUTGOING_REGNO(N) N
+#endif
for (regno = 0; regno < FIRST_PSEUDO_REGISTER; regno++)
- if (FUNCTION_ARG_REGNO_P (regno)
+ /* Check whether this register can hold an incoming pointer
+ argument. FUNCTION_ARG_REGNO_P tests outgoing register
+ numbers, so translate if necessary due to register windows. */
+ if (FUNCTION_ARG_REGNO_P (OUTGOING_REGNO (regno))
&& (reg = promoted_input_arg (regno, &mode, &unsignedp)) != 0)
{
record_value_for_reg