]> gcc.gnu.org Git - gcc.git/commit
RISC-V: Add testcases for scalar unsigned SAT_SUB form 6
authorPan Li <pan2.li@intel.com>
Thu, 13 Jun 2024 15:05:00 +0000 (23:05 +0800)
committerPan Li <pan2.li@intel.com>
Fri, 14 Jun 2024 14:07:16 +0000 (22:07 +0800)
commitb781fb4fe19f00aef886b21acf57b96d52545a0c
treed4f9f9d58fb14a3149b4631e06dd9079d1f0b1d5
parentbfe92c70821bc21df5befae3a39fe6ab31d2cbb4
RISC-V: Add testcases for scalar unsigned SAT_SUB form 6

After the middle-end support the form 6 of unsigned SAT_SUB and
the RISC-V backend implement the scalar .SAT_SUB, add more test
case to cover the form 6 of unsigned .SAT_SUB.

Form 6:
  #define SAT_SUB_U_6(T) \
  T sat_sub_u_6_##T (T x, T y) \
  { \
    return x <= y ? 0 : x - y; \
  }

gcc/testsuite/ChangeLog:

* gcc.target/riscv/sat_arith.h: Add helper macro for test.
* gcc.target/riscv/sat_u_sub-21.c: New test.
* gcc.target/riscv/sat_u_sub-22.c: New test.
* gcc.target/riscv/sat_u_sub-23.c: New test.
* gcc.target/riscv/sat_u_sub-24.c: New test.
* gcc.target/riscv/sat_u_sub-run-21.c: New test.
* gcc.target/riscv/sat_u_sub-run-22.c: New test.
* gcc.target/riscv/sat_u_sub-run-23.c: New test.
* gcc.target/riscv/sat_u_sub-run-24.c: New test.

Signed-off-by: Pan Li <pan2.li@intel.com>
gcc/testsuite/gcc.target/riscv/sat_arith.h
gcc/testsuite/gcc.target/riscv/sat_u_sub-21.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-22.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-23.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-24.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-run-21.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-run-22.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-run-23.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/sat_u_sub-run-24.c [new file with mode: 0644]
This page took 1.106249 seconds and 6 git commands to generate.