1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 2
2 ; Test 128-bit OR in vector registers on z13
4 ; RUN: llc < %s -mtriple=s390x-linux-gnu -mcpu=z13 | FileCheck %s
7 define i128 @f1(i128 %a, i128 %b) {
10 ; CHECK-NEXT: vl %v0, 0(%r4), 3
11 ; CHECK-NEXT: vl %v1, 0(%r3), 3
12 ; CHECK-NEXT: vo %v0, %v1, %v0
13 ; CHECK-NEXT: vst %v0, 0(%r2), 3
20 define i128 @f2(i128 %a, i128 %b) {
23 ; CHECK-NEXT: vl %v0, 0(%r4), 3
24 ; CHECK-NEXT: vl %v1, 0(%r3), 3
25 ; CHECK-NEXT: vno %v0, %v1, %v0
26 ; CHECK-NEXT: vst %v0, 0(%r2), 3
29 %res = xor i128 %op, -1
34 define i128 @f3(i128 %a) {
37 ; CHECK-NEXT: vl %v0, 0(%r3), 3
38 ; CHECK-NEXT: vno %v0, %v0, %v0
39 ; CHECK-NEXT: vst %v0, 0(%r2), 3
41 %res = xor i128 %a, -1
46 define i128 @f4(i128 %mask, i128 %true, i128 %false) {
49 ; CHECK-NEXT: vl %v0, 0(%r3), 3
50 ; CHECK-NEXT: vl %v1, 0(%r5), 3
51 ; CHECK-NEXT: vl %v2, 0(%r4), 3
52 ; CHECK-NEXT: vsel %v0, %v2, %v1, %v0
53 ; CHECK-NEXT: vst %v0, 0(%r2), 3
55 %notmask = xor i128 %mask, -1
56 %res1 = and i128 %true, %mask
57 %res2 = and i128 %false, %notmask
58 %res = or i128 %res1, %res2