aboutsummaryrefslogtreecommitdiff
path: root/gcc/reorg.c
diff options
context:
space:
mode:
authorAdam Nemet <anemet@caviumnetworks.com>2009-09-15 22:18:34 +0000
committerAdam Nemet <nemet@gcc.gnu.org>2009-09-15 22:18:34 +0000
commite484d1f0a465b55028791a06f68a6c6d94fa7ef2 (patch)
tree0befb5f9dc236afbc37fa0753d23a2b5c9ee9a08 /gcc/reorg.c
parentd7a9e7c50c8b2e897a1dfd828f4387d28481bd31 (diff)
downloadgcc-e484d1f0a465b55028791a06f68a6c6d94fa7ef2.zip
gcc-e484d1f0a465b55028791a06f68a6c6d94fa7ef2.tar.gz
gcc-e484d1f0a465b55028791a06f68a6c6d94fa7ef2.tar.bz2
re PR bootstrap/41349 (bootstrap comparison failure on sparc-linux)
PR bootstrap/41349 * reorg.c (redundant_insn): Don't count notes or DEBUG_INSNs when trying to limit the extent of searches in the insn stream. From-SVN: r151731
Diffstat (limited to 'gcc/reorg.c')
-rw-r--r--gcc/reorg.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/gcc/reorg.c b/gcc/reorg.c
index 4453cca..4871b0e 100644
--- a/gcc/reorg.c
+++ b/gcc/reorg.c
@@ -1630,13 +1630,14 @@ redundant_insn (rtx insn, rtx target, rtx delay_list)
for (trial = PREV_INSN (target),
insns_to_search = MAX_DELAY_SLOT_INSN_SEARCH;
trial && insns_to_search > 0;
- trial = PREV_INSN (trial), --insns_to_search)
+ trial = PREV_INSN (trial))
{
if (LABEL_P (trial))
return 0;
- if (! INSN_P (trial))
+ if (!NONDEBUG_INSN_P (trial))
continue;
+ --insns_to_search;
pat = PATTERN (trial);
if (GET_CODE (pat) == USE || GET_CODE (pat) == CLOBBER)
@@ -1735,10 +1736,11 @@ redundant_insn (rtx insn, rtx target, rtx delay_list)
for (trial = PREV_INSN (target),
insns_to_search = MAX_DELAY_SLOT_INSN_SEARCH;
trial && !LABEL_P (trial) && insns_to_search > 0;
- trial = PREV_INSN (trial), --insns_to_search)
+ trial = PREV_INSN (trial))
{
- if (!INSN_P (trial))
+ if (!NONDEBUG_INSN_P (trial))
continue;
+ --insns_to_search;
pat = PATTERN (trial);
if (GET_CODE (pat) == USE || GET_CODE (pat) == CLOBBER)