Skip to content

s390x/tcg: Vector Instruction Support Part 2

David Hildenbrand qemu-devel 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest40 patches 9 repliesIn review
  2. v241 patches 13 repliesSuperseded
  3. v141 patches 61 repliesSuperseded

Changes in v3 from the cover letter

- Use new vector helpers tcg_gen_gvec_abs(), tcg_gen_gvec_shl() and friends and tcg_gen_gvec_shlv() and friends.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/40s390x/tcg: Implement VECTOR ADDtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+57 -00 replies
2/40s390x/tcg: Implement VECTOR ADD COMPUTE CARRYtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+96 -02 replies
3/40s390x/tcg: Implement VECTOR ADD WITH CARRYtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+65 -00 replies
4/40s390x/tcg: Implement VECTOR ADD WITH CARRY COMPUTE CARRYtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+34 -01 reply
5/40s390x/tcg: Implement VECTOR AND (WITH COMPLEMENT)target/s390x/insn-data.def target/s390x/translate_vx.inc.c+18 -00 replies
6/40s390x/tcg: Implement VECTOR AVERAGEtarget/s390x/Makefile.objs target/s390x/helper.h target/s390x/insn-data.def +2 more+103 -10 replies
7/40s390x/tcg: Implement VECTOR AVERAGE LOGICALtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+68 -00 replies
8/40s390x/tcg: Implement VECTOR CHECKSUMtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+67 -00 replies
9/40s390x/tcg: Implement VECTOR ELEMENT COMPARE *target/s390x/insn-data.def target/s390x/translate_vx.inc.c+24 -00 replies
10/40s390x/tcg: Implement VECTOR COMPARE *target/s390x/cc_helper.c target/s390x/helper.c target/s390x/insn-data.def +3 more+54 -00 replies
11/40s390x/tcg: Implement VECTOR COUNT LEADING ZEROStarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+49 -00 replies
12/40s390x/tcg: Implement VECTOR COUNT TRAILING ZEROStarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+46 -01 reply
13/40s390x/tcg: Implement VECTOR EXCLUSIVE ORtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+9 -00 replies
14/40s390x/tcg: Implement VECTOR GALOIS FIELD MULTIPLY SUM (AND ACCUMULATE)target/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+217 -00 replies
15/40s390x/tcg: Implement VECTOR LOAD COMPLEMENTtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+18 -00 replies
16/40s390x/tcg: Implement VECTOR LOAD POSITIVEtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+15 -00 replies
17/40s390x/tcg: Implement VECTOR (MAXIMUM|MINIMUM) (LOGICAL)target/s390x/insn-data.def target/s390x/translate_vx.inc.c+39 -00 replies
18/40s390x/tcg: Implement VECTOR MULTIPLY AND ADD *target/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+277 -00 replies
19/40s390x/tcg: Implement VECTOR MULTIPLY *target/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+218 -00 replies
20/40s390x/tcg: Implement VECTOR NANDtarget/s390x/insn-data.def target/s390x/translate.c target/s390x/translate_vx.inc.c+10 -00 replies
21/40s390x/tcg: Implement VECTOR NORtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+9 -00 replies
22/40s390x/tcg: Implement VECTOR NOT EXCLUSIVE ORtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+9 -00 replies
23/40s390x/tcg: Implement VECTOR ORtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+9 -00 replies
24/40s390x/tcg: Implement VECTOR OR WITH COMPLEMENTtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+9 -00 replies
25/40s390x/tcg: Implement VECTOR POPULATION COUNTtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+37 -00 replies
26/40s390x/tcg: Implement VECTOR ELEMENT ROTATE LEFT LOGICALtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+98 -00 replies
27/40s390x/tcg: Implement VECTOR ELEMENT ROTATE AND INSERT UNDER MASKtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+75 -01 reply
28/40s390x/tcg: Implement VECTOR ELEMENT SHIFTtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+93 -00 replies
29/40s390x/tcg: Implement VECTOR SHIFT LEFT (BY BYTE)target/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+31 -00 replies
30/40s390x/tcg: Implement VECTOR SHIFT LEFT DOUBLE BY BYTEtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+31 -01 reply
31/40s390x/tcg: Implement VECTOR SHIFT RIGHT ARITHMETICtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+48 -00 replies
32/40s390x/tcg: Implement VECTOR SHIFT RIGHT LOGICAL *target/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+28 -00 replies
33/40s390x/tcg: Implement VECTOR SUBTRACTtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+19 -00 replies
34/40s390x/tcg: Implement VECTOR SUBTRACT COMPUTE BORROW INDICATIONtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+72 -01 reply
35/40s390x/tcg: Implement VECTOR SUBTRACT WITH BORROW INDICATIONtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+28 -00 replies
36/40s390x/tcg: Implement VECTOR SUBTRACT WITH BORROW COMPUTE BORROW INDICATIONtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+36 -01 reply
37/40s390x/tcg: Implement VECTOR SUM ACROSS DOUBLEWORDtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+31 -00 replies
38/40s390x/tcg: Implement VECTOR SUM ACROSS QUADWORDtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+34 -00 replies
39/40s390x/tcg: Implement VECTOR SUM ACROSS WORDtarget/s390x/insn-data.def target/s390x/translate_vx.inc.c+31 -00 replies
40/40s390x/tcg: Implement VECTOR TEST UNDER MASKtarget/s390x/helper.h target/s390x/insn-data.def target/s390x/translate_vx.inc.c +1 more+32 -01 reply

Reviews trailers per patch

All 40 patches have a Reviewed-by or Acked-by.

PatchRichard Henderson
1/40R-b
2/40R-b
3/40R-b
4/40R-b
5/40R-b
6/40R-b
7/40R-b
8/40R-b
9/40R-b
10/40R-b
11/40R-b
12/40R-b
13/40R-b
14/40R-b
15/40R-b
16/40R-b
17/40R-b
18/40R-b
19/40R-b
20/40R-b
21/40R-b
22/40R-b
23/40R-b
24/40R-b
25/40R-b
26/40R-b
27/40R-b
28/40R-b
29/40R-b
30/40R-b
31/40R-b
32/40R-b
33/40R-b
34/40R-b
35/40R-b
36/40R-b
37/40R-b
38/40R-b
39/40R-b
40/40R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [Qemu-devel] [PATCH v3 00/40] s390x/tcg: Vector Instruction Support Part 2

This is the second part of vector instruction support for s390x. It is based on the series by Richard:
[PATCH v2 00/29] tcg vector improvements

Part 1: Vector Support Instructions
Part 2: Vector Integer Instructions
Part 3: Vector String Instructions
Part 4: Vector Floating-Point Instructions

The current state can be found at (kept updated):
https://github.com/davidhildenbrand/qemu/tree/vx

With the current state I can boot Linux kernel + user space compiled with SIMD support. This allows to boot distributions compiled exclusively for z13, requiring SIMD support. Also, it is now possible to build a complete kernel using rpmbuild as quite some issues have been sorted out.

In this part, all Vector Integer Instructions introduced with the "Vector Facility" are added. Some instructions part of the Vector Extension Facilities are also added.

v2 -> v3:
- Use new vector helpers tcg_gen_gvec_abs(), tcg_gen_gvec_shl() and friends and tcg_gen_gvec_shlv() and friends.
v1 -> v2:
- Many suggestions and fixes as outlined by Richard H.
-- Mostly avoid oom helpers for 128-bit add/sub variants
-- New vector helpers are not considered for now

David Hildenbrand (40):
s390x/tcg: Implement VECTOR ADD
s390x/tcg: Implement VECTOR ADD COMPUTE CARRY
s390x/tcg: Implement VECTOR ADD WITH CARRY
s390x/tcg: Implement VECTOR ADD WITH CARRY COMPUTE CARRY s390x/tcg: Implement VECTOR AND (WITH COMPLEMENT) s390x/tcg: Implement VECTOR AVERAGE
s390x/tcg: Implement VECTOR AVERAGE LOGICAL
s390x/tcg: Implement VECTOR CHECKSUM
s390x/tcg: Implement VECTOR ELEMENT COMPARE *
s390x/tcg: Implement VECTOR COMPARE *
s390x/tcg: Implement VECTOR COUNT LEADING ZEROS
s390x/tcg: Implement VECTOR COUNT TRAILING ZEROS s390x/tcg: Implement VECTOR EXCLUSIVE OR
s390x/tcg: Implement VECTOR GALOIS FIELD MULTIPLY SUM (AND ACCUMULATE) s390x/tcg: Implement VECTOR LOAD COMPLEMENT
s390x/tcg: Implement VECTOR LOAD POSITIVE
s390x/tcg: Implement VECTOR (MAXIMUM|MINIMUM) (LOGICAL) s390x/tcg: Implement VECTOR MULTIPLY AND ADD *
s390x/tcg: Implement VECTOR MULTIPLY *
s390x/tcg: Implement VECTOR NAND
s390x/tcg: Implement VECTOR NOR
s390x/tcg: Implement VECTOR NOT EXCLUSIVE OR
s390x/tcg: Implement VECTOR OR
s390x/tcg: Implement VECTOR OR WITH COMPLEMENT
s390x/tcg: Implement VECTOR POPULATION COUNT
s390x/tcg: Implement VECTOR ELEMENT ROTATE LEFT LOGICAL s390x/tcg: Implement VECTOR ELEMENT ROTATE AND INSERT UNDER MASK s390x/tcg: Implement VECTOR ELEMENT SHIFT
s390x/tcg: Implement VECTOR SHIFT LEFT (BY BYTE) s390x/tcg: Implement VECTOR SHIFT LEFT DOUBLE BY BYTE s390x/tcg: Implement VECTOR SHIFT RIGHT ARITHMETIC s390x/tcg: Implement VECTOR SHIFT RIGHT LOGICAL * s390x/tcg: Implement VECTOR SUBTRACT
s390x/tcg: Implement VECTOR SUBTRACT COMPUTE BORROW INDICATION s390x/tcg: Implement VECTOR SUBTRACT WITH BORROW INDICATION s390x/tcg: Implement VECTOR SUBTRACT WITH BORROW COMPUTE BORROW
INDICATION
s390x/tcg: Implement VECTOR SUM ACROSS DOUBLEWORD s390x/tcg: Implement VECTOR SUM ACROSS QUADWORD
s390x/tcg: Implement VECTOR SUM ACROSS WORD
s390x/tcg: Implement VECTOR TEST UNDER MASK

 target/s390x/Makefile.objs      |    2 +-
 target/s390x/cc_helper.c        |   17 +
 target/s390x/helper.c           |    1 +
 target/s390x/helper.h           |   66 ++
 target/s390x/insn-data.def      |  137 +++
 target/s390x/internal.h         |    1 +
 target/s390x/translate.c        |    2 +
 target/s390x/translate_vx.inc.c | 1416 +++++++++++++++++++++++++++++++
 target/s390x/vec_int_helper.c   |  603 +++++++++++++
 9 files changed, 2244 insertions(+), 1 deletion(-)
 create mode 100644 target/s390x/vec_int_helper.c
Signature · 1 line
2.20.1