[Committed,00/14] S/390: Add support for new cpu architecture - arch13.

Message ID 1554204061-30488-1-git-send-email-krebbel@linux.ibm.com
Headers show
Series
  • S/390: Add support for new cpu architecture - arch13.
Related show

Message

Andreas Krebbel April 2, 2019, 11:20 a.m.
This adds support of new instructions to the S/390 specific parts.
    
Important features of the new instruction set are:

- New bit operation instructions on GPRs (e.g. and with complement, ...).
- New conditional register move instructions supporting THEN and ELSE values.
- New vector instructions to perform byte and vector element reversal.
    
Note: arch13 is NOT the official name of the new CPU.  It just
continues the series of archXX options supported as alternate names.
The archXX terminology refers to the edition number of the Principle
of Operations manual.  The official CPU name will be added later while
keeping support of the arch13 for backwards compatibility.

One newly introduced testcase fails:
FAIL: gcc.target/s390/arch13/sel-1.c scan-assembler-times \\tselrh\\t 1

Fixing this probably requires adjustments to the cost calculation in
ifcvt.  This is no GCC 9 material.
    
Committed to mainline.

Andreas Krebbel (14):
  S/390: arch13: Add arch13 as architecture option
  S/390: arch13: Support new bit operations
  S/390: arch13: Support new popcount instruction variant.
  S/390: arch13: Add support for new select instruction
  S/390: arch13: Support 32 bit fp-int vector converts
  S/390: arch13: Support 32 bit fp-int scalar converts
  S/390: arch13: New vector builtins - preparation
  S/390: arch13: vec_revb vector byte swap builtin
  S/390: arch13: vec_reve element order reversal builtins
  S/390: arch13: vector load/store byte reversed element for builtins
  S/390: arch13: vector load byte reversed element and replicate
  S/390: arch13: vector shift double by bit builtins
  S/390: arch13: vector string search builtins
  S/390: arch13: vector float-int conversion builtins

 gcc/common/config/s390/s390-common.c               |  21 +-
 gcc/config.gcc                                     |   2 +-
 gcc/config/s390/driver-native.c                    |   2 +-
 gcc/config/s390/s390-builtin-types.def             |  41 ++-
 gcc/config/s390/s390-builtins.def                  | 161 +++++++++-
 gcc/config/s390/s390-c.c                           |   2 +-
 gcc/config/s390/s390-opts.h                        |   1 +
 gcc/config/s390/s390.c                             | 107 ++++++-
 gcc/config/s390/s390.h                             |  19 +-
 gcc/config/s390/s390.md                            | 342 ++++++++++++++++++---
 gcc/config/s390/s390.opt                           |   3 +
 gcc/config/s390/vecintrin.h                        |  27 +-
 gcc/config/s390/vector.md                          | 142 +++++++--
 gcc/config/s390/vx-builtins.md                     | 257 ++++++++++++++--
 gcc/testsuite/gcc.target/s390/arch13/bitops-1.c    |  91 ++++++
 gcc/testsuite/gcc.target/s390/arch13/bitops-2.c    |  93 ++++++
 .../s390/arch13/fp-signedint-convert-1.c           |  22 ++
 .../s390/arch13/fp-unsignedint-convert-1.c         |  24 ++
 gcc/testsuite/gcc.target/s390/arch13/popcount-1.c  |  25 ++
 gcc/testsuite/gcc.target/s390/arch13/sel-1.c       |  21 ++
 gcc/testsuite/gcc.target/s390/md/andc-splitter-1.c |  20 +-
 gcc/testsuite/gcc.target/s390/md/andc-splitter-2.c |  20 +-
 gcc/testsuite/gcc.target/s390/s390.exp             |   3 +
 .../s390/zvector/bswap-and-replicate-1.c           |  28 ++
 .../gcc.target/s390/zvector/get-element-bswap-1.c  |  28 ++
 .../gcc.target/s390/zvector/get-element-bswap-2.c  |  28 ++
 .../gcc.target/s390/zvector/get-element-bswap-3.c  |  28 ++
 .../gcc.target/s390/zvector/get-element-bswap-4.c  |  28 ++
 .../gcc.target/s390/zvector/replicate-bswap-1.c    |  28 ++
 .../gcc.target/s390/zvector/replicate-bswap-2.c    |  28 ++
 .../gcc.target/s390/zvector/set-element-bswap-1.c  |  28 ++
 .../gcc.target/s390/zvector/set-element-bswap-2.c  |  28 ++
 .../gcc.target/s390/zvector/set-element-bswap-3.c  |  31 ++
 .../gcc.target/s390/zvector/vec-double-compile.c   |  47 +++
 .../gcc.target/s390/zvector/vec-float-compile.c    |  47 +++
 .../s390/zvector/vec-revb-load-double-z14.c        |  24 ++
 .../gcc.target/s390/zvector/vec-revb-load-double.c |  27 ++
 .../s390/zvector/vec-revb-store-double-z14.c       |  26 ++
 .../s390/zvector/vec-revb-store-double.c           |  28 ++
 .../s390/zvector/vec-reve-load-byte-z14.c          |  24 ++
 .../gcc.target/s390/zvector/vec-reve-load-byte.c   |  30 ++
 .../s390/zvector/vec-reve-load-halfword-z14.c      |  24 ++
 .../s390/zvector/vec-reve-load-halfword.c          |  27 ++
 .../s390/zvector/vec-reve-store-byte-z14.c         |  26 ++
 .../gcc.target/s390/zvector/vec-reve-store-byte.c  |  28 ++
 .../s390/zvector/vec-search-string-cc-1.c          |  36 +++
 .../s390/zvector/vec-search-string-cc-compile.c    |  47 +++
 .../zvector/vec-search-string-until-zero-cc-1.c    |  37 +++
 .../vec-search-string-until-zero-cc-compile.c      |  47 +++
 .../s390/zvector/vec-shift-left-double-by-bit-1.c  |  69 +++++
 .../s390/zvector/vec-shift-right-double-by-bit-1.c |  69 +++++
 .../gcc.target/s390/zvector/vec-signed-compile.c   |  47 +++
 .../gcc.target/s390/zvector/vec-unsigned-compile.c |  47 +++
 gcc/testsuite/lib/target-supports.exp              |  16 +
 54 files changed, 2357 insertions(+), 145 deletions(-)
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/bitops-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/bitops-2.c
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/fp-signedint-convert-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/fp-unsignedint-convert-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/popcount-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/arch13/sel-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/bswap-and-replicate-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/get-element-bswap-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/get-element-bswap-2.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/get-element-bswap-3.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/get-element-bswap-4.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/replicate-bswap-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/replicate-bswap-2.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/set-element-bswap-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/set-element-bswap-2.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/set-element-bswap-3.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-double-compile.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-float-compile.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-revb-load-double-z14.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-revb-load-double.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-revb-store-double-z14.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-revb-store-double.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-load-byte-z14.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-load-byte.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-load-halfword-z14.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-load-halfword.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-store-byte-z14.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-reve-store-byte.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-search-string-cc-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-search-string-cc-compile.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-search-string-until-zero-cc-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-search-string-until-zero-cc-compile.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-shift-left-double-by-bit-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-shift-right-double-by-bit-1.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-signed-compile.c
 create mode 100644 gcc/testsuite/gcc.target/s390/zvector/vec-unsigned-compile.c

-- 
2.7.4