aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXianmiao Qu <cooper.qu@linux.alibaba.com>2022-09-06 15:10:36 +0800
committerXianmiao Qu <cooper.qu@linux.alibaba.com>2022-09-06 15:13:21 +0800
commit33b182f61280d991bd0bda33003b5ee2a16024e2 (patch)
tree338f973a0f0f268ab17a471ff0c2a17ed5211f0c
parent2a2fb3e30c2f80b978d83e01346665f139ffeebb (diff)
downloadgcc-33b182f61280d991bd0bda33003b5ee2a16024e2.zip
gcc-33b182f61280d991bd0bda33003b5ee2a16024e2.tar.gz
gcc-33b182f61280d991bd0bda33003b5ee2a16024e2.tar.bz2
C-SKY: Fix missing operand when do spilt for cskyv2_addcc and cskyv2_addcc_invert.
It will cause ICE when compiling the case: gcc/testsuite/gcc.dg/params/blocksort-part.c gcc/ * config/csky/csky.md (cskyv2_addcc): Fix missing operand. (cskyv2_addcc_invert): Likewise.
-rw-r--r--gcc/config/csky/csky.md6
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/config/csky/csky.md b/gcc/config/csky/csky.md
index 6b05930..6a65929 100644
--- a/gcc/config/csky/csky.md
+++ b/gcc/config/csky/csky.md
@@ -1279,7 +1279,8 @@
"reload_completed && !rtx_equal_p (operands[0], operands[1])"
[(set (match_dup 0)
(if_then_else:SI (ne (reg:CC CSKY_CC_REGNUM) (const_int 0))
- (plus:SI (match_dup 0) (match_dup 2))))]
+ (plus:SI (match_dup 0) (match_dup 2))
+ (match_dup 0)))]
{
emit_insn (gen_movf (copy_rtx (operands[0]),
copy_rtx (operands[1]),
@@ -1305,7 +1306,8 @@
"reload_completed && !rtx_equal_p (operands[0], operands[1])"
[(set (match_dup 0)
(if_then_else:SI (eq (reg:CC CSKY_CC_REGNUM) (const_int 0))
- (plus:SI (match_dup 0) (match_dup 2))))]
+ (plus:SI (match_dup 0) (match_dup 2))
+ (match_dup 0)))]
{
emit_insn (gen_movt (copy_rtx (operands[0]),
copy_rtx (operands[1]),