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: Fix sharing of clobbers


On Mon, Mar 11, 2013 at 07:06:13PM +0100, Jan Hubicka wrote:
> *** emit-rtl.c	(revision 196596)
> --- emit-rtl.c	(working copy)
> *************** verify_rtx_sharing (rtx orig, rtx insn)
> *** 2583,2589 ****
>         return;
>         /* SCRATCH must be shared because they represent distinct values.  */
>       case CLOBBER:
> !       if (REG_P (XEXP (x, 0)) && REGNO (XEXP (x, 0)) < FIRST_PSEUDO_REGISTER)
>   	return;
>         break;
>   
> --- 2583,2593 ----
>         return;
>         /* SCRATCH must be shared because they represent distinct values.  */

Beyond what Jeff asked you to change, please also move the above comment
about SCRATCH back above the return; line (got accidentally moved during
your 2004 change).  Thanks.

>       case CLOBBER:
> !       /* Share clobbers of hard registers (like cc0), but do not share pseudo reg
> !          clobbers or clobbers of hard registers that originated as pseudos.
> !          This is needed to allow safe register renaming.  */
> !       if (REG_P (XEXP (x, 0)) && REGNO (XEXP (x, 0)) < FIRST_PSEUDO_REGISTER
> ! 	  && ORIGINAL_REGNO (XEXP (x, 0)) == REGNO (XEXP (x, 0)))
>   	return;
>         break;

	Jakub


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