From: Aaron Sawdey Date: Tue, 2 Jan 2018 16:46:29 +0000 (-0600) Subject: rtlanal.c (canonicalize_condition): Return 0 if final rtx does not have a conditional... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6aff9af1cb863f698ca8c23ba6dd548500f5f7e2;p=gcc.git rtlanal.c (canonicalize_condition): Return 0 if final rtx does not have a conditional at the top. * rtlanal.c (canonicalize_condition): Return 0 if final rtx does not have a conditional at the top. From-SVN: r256079 --- diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c index 6d50781a32c..e75ff103fcb 100644 --- a/gcc/rtlanal.c +++ b/gcc/rtlanal.c @@ -5693,7 +5693,11 @@ canonicalize_condition (rtx_insn *insn, rtx cond, int reverse, if (CC0_P (op0)) return 0; - return gen_rtx_fmt_ee (code, VOIDmode, op0, op1); + /* We promised to return a comparison. */ + rtx ret = gen_rtx_fmt_ee (code, VOIDmode, op0, op1); + if (COMPARISON_P (ret)) + return ret; + return 0; } /* Given a jump insn JUMP, return the condition that will cause it to branch