This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[24/32] Remove global call sets: recog.c
- From: Richard Sandiford <richard dot sandiford at arm dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Wed, 11 Sep 2019 20:15:24 +0100
- Subject: [24/32] Remove global call sets: recog.c
- References: <mptimpyzmf1.fsf@arm.com>
2019-09-11 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* recog.c: Include function-abi.h.
(peep2_find_free_register): Use crtl->abi when deciding whether
a register is free for use after RA.
Index: gcc/recog.c
===================================================================
--- gcc/recog.c 2019-09-10 19:56:45.357177891 +0100
+++ gcc/recog.c 2019-09-11 19:48:48.689668843 +0100
@@ -40,6 +40,7 @@ Software Foundation; either version 3, o
#include "cfgcleanup.h"
#include "reload.h"
#include "tree-pass.h"
+#include "function-abi.h"
#ifndef STACK_POP_CODE
#if STACK_GROWS_DOWNWARD
@@ -3227,7 +3228,7 @@ peep2_find_free_register (int from, int
break;
}
/* And that we don't create an extra save/restore. */
- if (! call_used_or_fixed_reg_p (regno + j)
+ if (! crtl->abi->clobbers_full_reg_p (regno + j)
&& ! df_regs_ever_live_p (regno + j))
{
success = 0;