This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Add missed adjustment to label_nuses in reload.



Approved after you fix some minor fomatting nits. Your code has:

Thank you.


I committed the attached nit adjusted patch.

/Marcus
diff --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]);

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]