From: Karl Meakin Date: Thu, 16 Oct 2025 15:56:42 +0000 (+0000) Subject: aarch64: Remove redundant checks X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e73b0e7d803af92fbc59874a971297a3687ff408;p=thirdparty%2Fgcc.git aarch64: Remove redundant checks The checks for `code == UNEQ || code == LTGT` are unecessary, because they are already excluded by `aarch64_comparison_operator` gcc/ChangeLog: * config/aarch64/aarch64.md (mov): Delete redundant check. (movcc): Likewise. (cc): Likewise. --- diff --git a/gcc/config/aarch64/aarch64.md b/gcc/config/aarch64/aarch64.md index 2ef79f448fd..1e14b1dc4f2 100644 --- a/gcc/config/aarch64/aarch64.md +++ b/gcc/config/aarch64/aarch64.md @@ -4805,11 +4805,9 @@ "" { enum rtx_code code = GET_CODE (operands[1]); - if (code == UNEQ || code == LTGT) - FAIL; - rtx ccreg = XEXP (operands[1], 0); enum machine_mode ccmode = GET_MODE (ccreg); + if (GET_MODE_CLASS (ccmode) == MODE_CC) gcc_assert (XEXP (operands[1], 1) == const0_rtx); else if (ccmode == QImode || ccmode == HImode) @@ -4830,8 +4828,6 @@ "" { enum rtx_code code = GET_CODE (operands[1]); - if (code == UNEQ || code == LTGT) - FAIL; rtx ccreg = XEXP (operands[1], 0); enum machine_mode ccmode = GET_MODE (ccreg); @@ -4855,8 +4851,6 @@ "" { enum rtx_code code = GET_CODE (operands[1]); - if (code == UNEQ || code == LTGT) - FAIL; rtx ccreg = XEXP (operands[1], 0); enum machine_mode ccmode = GET_MODE (ccreg);