This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix regression of cleanup-*.[cC] tests on MIPS


On Sun, Apr 12, 2009 at 5:36 PM, Adam Nemet <anemet@caviumnetworks.com> wrote:
> The analysis is at:
>
> ?http://gcc.gnu.org/ml/gcc/2009-04/msg00371.html
>
> The patch below looks at each insn in a SEQUENCE to decide whether the
> SEQUENCE may throw.
>
> Bootstrapped and regtested on mips64octeon-linux-gnu. ?It fixes the cleanup
> test failures.
>
> OK to install?

Ok.

Thanks,
Richard.

> Adam
>
>
> ? ? ? ?* except.c (can_throw_external): Look at each insn in a SEQUENCE
> ? ? ? ?when deciding whether the whole SEQUENCE can throw.
>
> Index: except.c
> ===================================================================
> --- except.c ? ?(revision 145873)
> +++ except.c ? ?(working copy)
> @@ -2892,7 +2892,16 @@ can_throw_external (const_rtx insn)
>
> ? if (NONJUMP_INSN_P (insn)
> ? ? ? && GET_CODE (PATTERN (insn)) == SEQUENCE)
> - ? ?insn = XVECEXP (PATTERN (insn), 0, 0);
> + ? ?{
> + ? ? ?rtx seq = PATTERN (insn);
> + ? ? ?int i, n = XVECLEN (seq, 0);
> +
> + ? ? ?for (i = 0; i < n; i++)
> + ? ? ? if (can_throw_external (XVECEXP (seq, 0, i)))
> + ? ? ? ? return true;
> +
> + ? ? ?return false;
> + ? ?}
>
> ? note = find_reg_note (insn, REG_EH_REGION, NULL_RTX);
> ? if (!note)
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]