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 RFA] Avoid another invalid RTL sharing


On Sun, 12 Nov 2006, Kaz Kojima wrote:
> 2006-11-11  Kaz Kojima  <kkojima@gcc.gnu.org>
>
> 	* genemit.c (gen_insn): Call gen_exp with a non-null used
> 	when handling multiple insns.
> 	(gen_expand): Likewise.
> 	* reorg.c (emit_delay_sequence): Copy the delay slot insn.
> 	* config/sh/sh.md (ashrsi2_31+1): Copy operands[0].
> 	(movsi_const_16bit+1): Copy operands[1].
> 	(call_pcrel): Copy the call_site pattern.
> 	(call_value_pcrel, sibcall_pcrel, GOTaddr2picreg): Likewise.

This is OK for mainline, with some trivial changes.

> +      char *used = XCNEWVEC (char, operands);
> ...
> +      free (used);

and

> +  used = XCNEWVEC (char, operands);
> ...
> +  free (used);


If we're going to use libiberty's XCNEWVEC allocator abstraction, it
makes sense to use the corresponding XDELETEVEC macro for consistency.

Ok for mainline with those changes.

Thanks,

Roger
--


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