This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Add missed adjustment to label_nuses in reload.
- From: Marcus Shawcroft <marcus dot shawcroft at arm dot com>
- To: Jeff Law <law at redhat dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 05 Jan 2012 09:51:42 +0000
- Subject: Re: [PATCH] Add missed adjustment to label_nuses in reload.
- References: <4F045D38.7060204@arm.com> <4F04A6D4.3050502@redhat.com>
Approved after you fix some minor fomatting nits. Your code has:
Thank you.
I committed the attached nit adjusted patch.
/Marcusdiff --git a/gcc/reload.c b/gcc/reload.c
index 53dcd2d..206fb36 100644
--- a/gcc/reload.c
+++ b/gcc/reload.c
@@ -4212,7 +4212,12 @@ find_reloads (rtx insn, int replace, int ind_levels, int live_known,
&& (!JUMP_P (insn)
|| !label_is_jump_target_p (XEXP (substitution, 0),
insn)))
- add_reg_note (insn, REG_LABEL_OPERAND, XEXP (substitution, 0));
+ {
+ add_reg_note (insn, REG_LABEL_OPERAND, XEXP (substitution, 0));
+ if (LABEL_P (XEXP (substitution, 0)))
+ ++LABEL_NUSES (XEXP (substitution, 0));
+ }
+
}
else
retval |= (substed_operand[i] != *recog_data.operand_loc[i]);