cse.c (cse_insn): Set "cse_jumps_altered" when collapsing a switch statement into an...

* cse.c (cse_insn): Set "cse_jumps_altered" when collapsing
        a switch statement into an unconditional jump.
        * toplev.c (rest_of_compilation): Rerun jump_optimize
        before the second CSE pass.

From-SVN: r6305
This commit is contained in:
Jeff Law 1993-12-24 12:36:04 -07:00
parent 18bd1bd9bb
commit 4433322379
2 changed files with 5 additions and 0 deletions

View File

@ -6447,6 +6447,7 @@ cse_insn (insn, in_libcall_block)
trial = gen_rtx (LABEL_REF, Pmode, get_label_after (trial));
SET_SRC (sets[i].rtl) = trial;
cse_jumps_altered = 1;
break;
}

View File

@ -2559,7 +2559,11 @@ rest_of_compilation (decl)
if (optimize > 0 && flag_rerun_cse_after_loop)
{
/* Running another jump optimization pass before the second
cse pass sometimes simplifies the RTL enough to allow
the second CSE pass to do a better job. */
TIMEVAR (cse2_time, reg_scan (insns, max_reg_num (), 0));
TIMEVAR (jump_time, jump_optimize (insns, 0, 0, 1));
TIMEVAR (cse2_time, tem = cse_main (insns, max_reg_num (),
1, cse2_dump_file));