From 16b702cd43c726a88897f6b153456e72fa990389 Mon Sep 17 00:00:00 2001 From: Mark Mitchell Date: Thu, 21 Oct 1999 03:37:33 +0000 Subject: [PATCH] cse.c (cse_end_of_basic_block): Don't return the end of a basic block reached by a branch if... * cse.c (cse_end_of_basic_block): Don't return the end of a basic block reached by a branch if we're not going to actually process this block From-SVN: r30109 --- gcc/ChangeLog | 6 ++++++ gcc/cse.c | 9 +++++++++ 2 files changed, 15 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 998c467..5bfc271 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +Wed Oct 20 20:41:46 1999 Mark Mitchell + + * cse.c (cse_end_of_basic_block): Don't return the end of a basic + block reached by a branch if we're not going to actually process + this block. + Wed Oct 20 15:18:42 1999 Jim Wilson * integrate.c (integrate_decl_tree): Set DECL_CONTEXT to 0 if this is diff --git a/gcc/cse.c b/gcc/cse.c index edb4678..a304bc6 100644 --- a/gcc/cse.c +++ b/gcc/cse.c @@ -8442,6 +8442,15 @@ cse_end_of_basic_block (insn, data, follow_jumps, after_loop, skip_blocks) path_size--; } + /* If the first instruction is marked with QImode, that means we've + already processed this block. Our caller will look at DATA->LAST + to figure out where to go next. We want to return the next block + in the instruction stream, not some branched-to block somewhere + else. We accomplish this by pretending our called forbid us to + follow jumps, or skip blocks. */ + if (GET_MODE (insn) == QImode) + follow_jumps = skip_blocks = 0; + /* Scan to end of this basic block. */ while (p && GET_CODE (p) != CODE_LABEL) { -- 2.7.4