This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Call delete_trivially_dead_insns after gcse
- From: Jan Hubicka <jh at suse dot cz>
- To: law at redhat dot com, rth at cygnus dot com
- Cc: Jan Hubicka <jh at suse dot cz>, John David Anglin <dave at hiauly1 dot hia dot nrc dot ca>, gcc-bugs at gcc dot gnu dot org, rth at redhat dot com
- Date: Thu, 10 Jan 2002 16:30:27 +0100
- Subject: Call delete_trivially_dead_insns after gcse
- References: <20020110092535.GB14428@atrey.karlin.mff.cuni.cz> <27266.1010673759@porcupine.cygnus.com>
Hi,
I've just bootstrapped/regtested the attached change. It is good
idea to clean the delete the dead insns after gcse independently
on the noop jump issue, as cprop create many dead moves that can confuse
subsequent cse pass.
I am going to install this to the branch, OK for mainline?
Honza
Thu Jan 10 17:32:35 CET 2002 Jan Hubicka <jh@suse.cz>
* toplev.c (rest_of_compilation): Call delte_trivially_dead_insn
after combine.
Index: toplev.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/toplev.c,v
retrieving revision 1.567
diff -c -3 -p -r1.567 toplev.c
*** toplev.c 2002/01/08 06:13:34 1.567
--- toplev.c 2002/01/10 15:27:51
*************** rest_of_compilation (decl)
*** 2812,2817 ****
--- 2812,2819 ----
save_cfj = flag_cse_follow_jumps;
flag_cse_skip_blocks = flag_cse_follow_jumps = 0;
+ delete_trivially_dead_insns (insns, max_reg_num (), 0);
+
/* CFG is no longer maintained up-to-date. */
free_bb_for_insn ();
/* If -fexpensive-optimizations, re-run CSE to clean up things done