mbox series

[v2,0/3] Add support for SVE2 faminmax

Message ID 20241001120933.1269122-1-saurabh.jha@arm.com
Headers show
Series Add support for SVE2 faminmax | expand

Message

Saurabh Jha Oct. 1, 2024, 12:09 p.m. UTC
From: Saurabh Jha <saurabh.jha@arm.com>

This patch series a revised version of an earlier patch series:
https://gcc.gnu.org/pipermail/gcc-patches/2024-September/662951.html.

The main change in this patch series is the introduction of the two
unspecs, UNSPEC_COND_SMAX and UNSPEC_COND_SMIN, and using them for
existing minmax instructions and for the code generation of faminmax
instructions.

Other changes in this patch series are to address review comments:
1. [PATCH 1] Removing stray gcc/testsuite/gcc.target/aarch64/aminmax.h.
2. [PATCH 1] Fixing formatting in new iterators in iterators.md.
3. [PATCH 1] Using pragma "+sve+faminmax" in test cases. Remove options
   directive.
4. [PATCH 2] Move instruction pattern to aarch64-sve2.md.
5. [PATCH 2] Fix use of operand 2.
6. [PATCH 2] Fix use of assemble directive.
7. [PATCH 2] Using pragma "+sve+faminmax" and remove them from options.
8. [PATCH 2] New test cases to make sure we are not operator combine
   while using intrinsics.

Another minor change was in aarch64-sve-builtins-base.cc where we
fixed the formatting.

Saurabh Jha (3):
  aarch64: Add SVE2 faminmax intrinsics
  aarch64: Introduce new unspecs for smax/smin
  aarch64: Add codegen support for SVE2 faminmax

 .../aarch64/aarch64-sve-builtins-base.cc      |   4 +
 .../aarch64/aarch64-sve-builtins-base.def     |   5 +
 .../aarch64/aarch64-sve-builtins-base.h       |   2 +
 gcc/config/aarch64/aarch64-sve.md             |  33 ----
 gcc/config/aarch64/aarch64-sve2.md            |  31 ++++
 gcc/config/aarch64/aarch64.h                  |   1 +
 gcc/config/aarch64/iterators.md               |  97 +++++++----
 .../gcc.target/aarch64/sve/faminmax_1.c       |  85 ++++++++++
 .../gcc.target/aarch64/sve/faminmax_2.c       | 154 ++++++++++++++++++
 .../aarch64/sve2/acle/asm/amax_f16.c          | 142 ++++++++++++++++
 .../aarch64/sve2/acle/asm/amax_f32.c          | 142 ++++++++++++++++
 .../aarch64/sve2/acle/asm/amax_f64.c          | 142 ++++++++++++++++
 .../aarch64/sve2/acle/asm/amin_f16.c          | 142 ++++++++++++++++
 .../aarch64/sve2/acle/asm/amin_f32.c          | 142 ++++++++++++++++
 .../aarch64/sve2/acle/asm/amin_f64.c          | 142 ++++++++++++++++
 15 files changed, 1202 insertions(+), 62 deletions(-)
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve/faminmax_1.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve/faminmax_2.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amax_f16.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amax_f32.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amax_f64.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amin_f16.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amin_f32.c
 create mode 100644 gcc/testsuite/gcc.target/aarch64/sve2/acle/asm/amin_f64.c