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] PR opt/12280: Avoid RTL sharing in noce_emit_cmove


On Sun, Nov 09, 2003 at 04:24:11PM +0100, Jan Hubicka wrote:
> +     case MEM:
> +       /* A MEM is allowed to be shared if its address is constant.  */
> +       if (CONSTANT_ADDRESS_P (XEXP (x, 0))
> + 	  || reload_completed || reload_in_progress)
> + 	return;

This is now wrong; it changed recently.  Which brings the point
that there should be exactly one place this logic is maintained.
I suggest splitting out a predicate that this and copy_rtx and
so forth can use.

> *** 1260,1266 ****
>         if (is_mem)
>   	{
>             tmp = gen_reg_rtx (GET_MODE (b));
> ! 	  tmp = emit_insn (gen_rtx_SET (VOIDmode, tmp, b));
>   	}
>         else if (! insn_b)
>   	goto end_seq_and_fail;
> --- 1280,1288 ----
>         if (is_mem)
>   	{
>             tmp = gen_reg_rtx (GET_MODE (b));
> ! 	  tmp = emit_insn (gen_rtx_SET (VOIDmode,
> ! 				  	tmp,
> ! 					b));
>   	}

There seem to be a lot of spurrious changes in ifcvt.c.


r~


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