summaryrefslogtreecommitdiff
path: root/gcc/config/cris
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@axis.com>2020-01-31 08:24:43 +0100
committerHans-Peter Nilsson <hp@axis.com>2020-05-09 04:08:47 +0200
commit61c964c7fd2ad96cec262a2bcd1fc13bd2e2eff8 (patch)
tree500522c95ec87da0da005cfbf71cdc2a0938f2ad /gcc/config/cris
parent3c7016b08f7a1f62e13a0805d1b5eb1685d3c475 (diff)
downloadgcc-61c964c7fd2ad96cec262a2bcd1fc13bd2e2eff8.tar.gz
cris: Enable extend operations to SImode to set condition codes.
Enable dropping of compares with zero of the result, through the three CCmode substitutions and the cmpelim pass. gcc: * config/cris/cris.md ("<acc><anz><anzvc>extend<mode>si2<setcc><setnz><setnzvc>"): Rename from "extend<mode>si2". ("<acc><anz><anzvc>zero_extend<mode>si2<setcc><setnz><setnzvc>"): Similar, from "zero_extend<mode>si2".
Diffstat (limited to 'gcc/config/cris')
-rw-r--r--gcc/config/cris/cris.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/config/cris/cris.md b/gcc/config/cris/cris.md
index 5f77bc9e0fd..2f3f328f5c5 100644
--- a/gcc/config/cris/cris.md
+++ b/gcc/config/cris/cris.md
@@ -856,7 +856,7 @@
""
"movs<m> %1,%M0\;smi %H0\;neg.d %H0,%H0")
-(define_insn "extend<mode>si2"
+(define_insn "<acc><anz><anzvc>extend<mode>si2<setcc><setnz><setnzvc>"
[(set (match_operand:SI 0 "register_operand" "=r,r,r")
(sign_extend:SI (match_operand:BW 1 "general_operand" "r,Q>,g")))
(clobber (reg:CC CRIS_CC0_REGNUM))]
@@ -879,7 +879,7 @@
;; Zero-extend. The DImode ones are synthesized by gcc, so we don't
;; specify them here.
-(define_insn "zero_extend<mode>si2"
+(define_insn "<acc><anz><anzvc>zero_extend<mode>si2<setcc><setnz><setnzvc>"
[(set (match_operand:SI 0 "register_operand" "=r,r,r")
(zero_extend:SI
(match_operand:BW 1 "nonimmediate_operand" "r,Q>,m")))