This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: avoid cfg rebuild after combine
- To: Jan Hubicka <jh at suse dot cz>
- Subject: Re: avoid cfg rebuild after combine
- From: Richard Henderson <rth at redhat dot com>
- Date: Sun, 22 Jul 2001 23:40:06 -0700
- Cc: gcc-patches at gcc dot gnu dot org, patches at x86-64 dot org
- References: <20010715220548.B5914@atrey.karlin.mff.cuni.cz>
On Sun, Jul 15, 2001 at 10:05:48PM +0200, Jan Hubicka wrote:
> * basic-block.h (purge_all_dead_edges, purge_dead_edges): New functions.
> * toplev.c (rest_of_compilation): Conditionally call purge_all_dead_edges
> after combine.
> * gcse.c (cprop_cc0_jump, cprop_insn): New argument "basic_block".
> (cprop_jump): Likewise; call purge_dead_edges if substitution suceeded.
Ok.
> + /* Assume that the preceeding pass has possibly eliminated jump instructions
> + or converted the unconditional jumps. Eliminate the edges from CFG. */
"or converted conditional jumps to unconditional jumps."
> + /* In case we see other insn, we are not sure if the edges are not just
> + edges created by the insn we see. See whether we do have normal edges
> + created by jump insn. */
/* If we don't see a jump insn, we don't know exactly why the block would
have been broken at this point. Look for a simple, non-fallthru edge,
as these are only created by conditional branches. If we find such an
edge we know that there used to be a jump here and can then safely
remove all non-fallthru edges. */
r~