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]

Re: Patch to cleanup noop move handling (version 2)


On Sat, 10 Mar 2001, John Wehle wrote:

> [ This version cleans up a few more places. ]
>
> This eliminates some code duplication.  This patch passes make
> bootstrap and check on i386-unknown-freebsd4.2.  It also passes
> make check for powerpc-eabisim.
>
> ChangeLog:
>
> Sat Mar 10 00:43:36 EST 2001  John Wehle  (john@feith.com)
>
> 	* rtl.h (set_noop_p): Declare.
> 	* flow.c (set_noop_p): Move from here ...
> 	* rtlanal.c (set_noop_p): ... to here and enhance.
> 	* cse.c (delete_trivially_dead_insns): Use it.
> 	* gcse.c (hash_scan_set): Likewise.
> 	* jump.c (delete_noop_moves): Likewise.
> 	* recog.c (split_all_insns): Likewise.

Ok.

> +   if (side_effects_p (set))
> +     return 0;

Depending on terminology you could say that each SET rtx has a side effect.
side_effects_p doesn't care, but it might be slightly clearer to use

  if (side_effects_p (src) || side_effects_p (dst))


Bernd


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