From: Eric Botcazou Date: Sun, 2 Sep 2012 10:37:49 +0000 (+0000) Subject: re PR rtl-optimization/54369 (delayed-branch pass removes too many instructions) X-Git-Tag: releases/gcc-4.6.4~389 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f87ed873c69d5c51f7004e8ac95cc4ddfbb14baa;p=thirdparty%2Fgcc.git re PR rtl-optimization/54369 (delayed-branch pass removes too many instructions) PR rtl-optimization/54369 * config/mips/mips.c (mips_reorg): Invoke cleanup_barriers before calling dbr_schedule. * config/sparc/sparc.c (sparc_reorg): Likewise. From-SVN: r190860 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index fe7a66298678..9dd505d5eff2 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2012-09-02 Eric Botcazou + + PR rtl-optimization/54369 + * config/mips/mips.c (mips_reorg): Invoke cleanup_barriers before + calling dbr_schedule. + * config/sparc/sparc.c (sparc_reorg): Likewise. + 2012-08-16 Rainer Orth * config/sol2.h (LINK_ARCH32_SPEC_BASE): Add /lib to default diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c index 8069a0bd7367..87bf18e6c8e6 100644 --- a/gcc/config/mips/mips.c +++ b/gcc/config/mips/mips.c @@ -15083,7 +15083,10 @@ mips_reorg (void) } if (optimize > 0 && flag_delayed_branch) - dbr_schedule (get_insns ()); + { + cleanup_barriers (); + dbr_schedule (get_insns ()); + } mips_reorg_process_insns (); if (!TARGET_MIPS16 && TARGET_EXPLICIT_RELOCS diff --git a/gcc/config/sparc/sparc.c b/gcc/config/sparc/sparc.c index fea4a81d34b8..9682609fecdb 100644 --- a/gcc/config/sparc/sparc.c +++ b/gcc/config/sparc/sparc.c @@ -9456,7 +9456,10 @@ sparc_reorg (void) /* We need to have the (essentially) final form of the insn stream in order to properly detect the various hazards. Run delay slot scheduling. */ if (optimize > 0 && flag_delayed_branch) - dbr_schedule (get_insns ()); + { + cleanup_barriers (); + dbr_schedule (get_insns ()); + } /* Now look for specific patterns in the insn stream. */ for (insn = get_insns (); insn; insn = next)