This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] PR rtl-optimization/61712
- From: Richard Earnshaw <rearnsha at arm dot com>
- To: lin zuojian <manjian2006 at gmail dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 04 Jul 2014 10:48:50 +0100
- Subject: Re: [PATCH] PR rtl-optimization/61712
- Authentication-results: sourceware.org; auth=none
- References: <20140704045915 dot GA1654 at ubuntu>
On 04/07/14 05:59, lin zuojian wrote:
> Hi,
> This crash is due to fail to consider the exception situation that
> the insn variable may not be a insn at all.
>
> arm.c (thumb1_reorg): if the
> selected insn is not a insn, continue to next bb.
>
> ---
> gcc/config/arm/arm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
> index 89684bb..50ae64b 100644
> --- a/gcc/config/arm/arm.c
> +++ b/gcc/config/arm/arm.c
> @@ -16720,7 +16720,7 @@ thumb1_reorg (void)
> insn = PREV_INSN (insn);
>
> /* Find the last cbranchsi4_insn in basic block BB. */
> - if (INSN_CODE (insn) != CODE_FOR_cbranchsi4_insn)
> + if (!INSN_P (insn) || (INSN_CODE (insn) != CODE_FOR_cbranchsi4_insn))
> continue;
>
> /* Get the register with which we are comparing. */
>
This should be fixed the same way as it was on trunk. Bin's taking care
of that.
R.