1*e9d12c24SStefan Pintilie; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py 2*e9d12c24SStefan Pintilie; RUN: llc -verify-machineinstrs -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \ 3*e9d12c24SStefan Pintilie; RUN: -mcpu=pwr9 -mtriple=powerpc64le < %s | FileCheck %s --check-prefix=PWR9LE 4*e9d12c24SStefan Pintilie; RUN: llc -verify-machineinstrs -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \ 5*e9d12c24SStefan Pintilie; RUN: -mcpu=pwr9 -mtriple=powerpc64 < %s | FileCheck %s --check-prefix=PWR9BE 6*e9d12c24SStefan Pintilie; RUN: llc -verify-machineinstrs -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \ 7*e9d12c24SStefan Pintilie; RUN: -mcpu=pwr10 -mtriple=powerpc64le < %s | FileCheck %s --check-prefix=PWR10LE 8*e9d12c24SStefan Pintilie; RUN: llc -verify-machineinstrs -ppc-asm-full-reg-names -ppc-vsr-nums-as-vr \ 9*e9d12c24SStefan Pintilie; RUN: -mcpu=pwr10 -mtriple=powerpc64 < %s | FileCheck %s --check-prefix=PWR10BE 10*e9d12c24SStefan Pintilie 11*e9d12c24SStefan Pintilie;; 12*e9d12c24SStefan Pintilie;; Vectors of type i32 13*e9d12c24SStefan Pintilie;; 14*e9d12c24SStefan Pintiliedefine dso_local i32 @v2i32(<2 x i32> %a) local_unnamed_addr #0 { 15*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v2i32: 16*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 17*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxspltw vs0, v2, 2 18*e9d12c24SStefan Pintilie; PWR9LE-NEXT: li r3, 0 19*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland v2, v2, vs0 20*e9d12c24SStefan Pintilie; PWR9LE-NEXT: vextuwrx r3, r3, v2 21*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 22*e9d12c24SStefan Pintilie; 23*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v2i32: 24*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 25*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxspltw vs0, v2, 1 26*e9d12c24SStefan Pintilie; PWR9BE-NEXT: li r3, 0 27*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland v2, v2, vs0 28*e9d12c24SStefan Pintilie; PWR9BE-NEXT: vextuwlx r3, r3, v2 29*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 30*e9d12c24SStefan Pintilie; 31*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v2i32: 32*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 33*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxspltw vs0, v2, 2 34*e9d12c24SStefan Pintilie; PWR10LE-NEXT: li r3, 0 35*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland v2, v2, vs0 36*e9d12c24SStefan Pintilie; PWR10LE-NEXT: vextuwrx r3, r3, v2 37*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 38*e9d12c24SStefan Pintilie; 39*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v2i32: 40*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 41*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxspltw vs0, v2, 1 42*e9d12c24SStefan Pintilie; PWR10BE-NEXT: li r3, 0 43*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland v2, v2, vs0 44*e9d12c24SStefan Pintilie; PWR10BE-NEXT: vextuwlx r3, r3, v2 45*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 46*e9d12c24SStefan Pintilieentry: 47*e9d12c24SStefan Pintilie %0 = call i32 @llvm.vector.reduce.and.v2i32(<2 x i32> %a) 48*e9d12c24SStefan Pintilie ret i32 %0 49*e9d12c24SStefan Pintilie} 50*e9d12c24SStefan Pintilie 51*e9d12c24SStefan Pintiliedefine dso_local i32 @v4i32(<4 x i32> %a) local_unnamed_addr #0 { 52*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v4i32: 53*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 54*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v3, v2 55*e9d12c24SStefan Pintilie; PWR9LE-NEXT: li r3, 0 56*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v2, v3 57*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxspltw vs1, vs0, 2 58*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland v2, vs0, vs1 59*e9d12c24SStefan Pintilie; PWR9LE-NEXT: vextuwrx r3, r3, v2 60*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 61*e9d12c24SStefan Pintilie; 62*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v4i32: 63*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 64*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v3, v2 65*e9d12c24SStefan Pintilie; PWR9BE-NEXT: li r3, 0 66*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v2, v3 67*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxspltw vs1, vs0, 1 68*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland v2, vs0, vs1 69*e9d12c24SStefan Pintilie; PWR9BE-NEXT: vextuwlx r3, r3, v2 70*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 71*e9d12c24SStefan Pintilie; 72*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v4i32: 73*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 74*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v3, v2 75*e9d12c24SStefan Pintilie; PWR10LE-NEXT: li r3, 0 76*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v2, v3 77*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxspltw vs0, vs0, 2 78*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval v2, v2, v3, vs0, 1 79*e9d12c24SStefan Pintilie; PWR10LE-NEXT: vextuwrx r3, r3, v2 80*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 81*e9d12c24SStefan Pintilie; 82*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v4i32: 83*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 84*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v3, v2 85*e9d12c24SStefan Pintilie; PWR10BE-NEXT: li r3, 0 86*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v2, v3 87*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxspltw vs0, vs0, 1 88*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval v2, v2, v3, vs0, 1 89*e9d12c24SStefan Pintilie; PWR10BE-NEXT: vextuwlx r3, r3, v2 90*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 91*e9d12c24SStefan Pintilieentry: 92*e9d12c24SStefan Pintilie %0 = call i32 @llvm.vector.reduce.and.v4i32(<4 x i32> %a) 93*e9d12c24SStefan Pintilie ret i32 %0 94*e9d12c24SStefan Pintilie} 95*e9d12c24SStefan Pintilie 96*e9d12c24SStefan Pintiliedefine dso_local i32 @v8i32(<8 x i32> %a) local_unnamed_addr #0 { 97*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v8i32: 98*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 99*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v2, v3 100*e9d12c24SStefan Pintilie; PWR9LE-NEXT: li r3, 0 101*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v2, vs0 102*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, v2 103*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxspltw vs1, vs0, 2 104*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland v2, vs0, vs1 105*e9d12c24SStefan Pintilie; PWR9LE-NEXT: vextuwrx r3, r3, v2 106*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 107*e9d12c24SStefan Pintilie; 108*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v8i32: 109*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 110*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v2, v3 111*e9d12c24SStefan Pintilie; PWR9BE-NEXT: li r3, 0 112*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v2, vs0 113*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, v2 114*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxspltw vs1, vs0, 1 115*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland v2, vs0, vs1 116*e9d12c24SStefan Pintilie; PWR9BE-NEXT: vextuwlx r3, r3, v2 117*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 118*e9d12c24SStefan Pintilie; 119*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v8i32: 120*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 121*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v2, v3 122*e9d12c24SStefan Pintilie; PWR10LE-NEXT: li r3, 0 123*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v4, vs0 124*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs1, v2, v3, v4, 1 125*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxspltw vs1, vs1, 2 126*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval v2, vs0, v4, vs1, 1 127*e9d12c24SStefan Pintilie; PWR10LE-NEXT: vextuwrx r3, r3, v2 128*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 129*e9d12c24SStefan Pintilie; 130*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v8i32: 131*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 132*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v2, v3 133*e9d12c24SStefan Pintilie; PWR10BE-NEXT: li r3, 0 134*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v4, vs0 135*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs1, v2, v3, v4, 1 136*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxspltw vs1, vs1, 1 137*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval v2, vs0, v4, vs1, 1 138*e9d12c24SStefan Pintilie; PWR10BE-NEXT: vextuwlx r3, r3, v2 139*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 140*e9d12c24SStefan Pintilieentry: 141*e9d12c24SStefan Pintilie %0 = call i32 @llvm.vector.reduce.and.v8i32(<8 x i32> %a) 142*e9d12c24SStefan Pintilie ret i32 %0 143*e9d12c24SStefan Pintilie} 144*e9d12c24SStefan Pintilie 145*e9d12c24SStefan Pintiliedefine dso_local i32 @v16i32(<16 x i32> %a) local_unnamed_addr #0 { 146*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v16i32: 147*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 148*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v3, v5 149*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs1, v2, v4 150*e9d12c24SStefan Pintilie; PWR9LE-NEXT: li r3, 0 151*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs1, vs0 152*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v2, vs0 153*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, v2 154*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxspltw vs1, vs0, 2 155*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland v2, vs0, vs1 156*e9d12c24SStefan Pintilie; PWR9LE-NEXT: vextuwrx r3, r3, v2 157*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 158*e9d12c24SStefan Pintilie; 159*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v16i32: 160*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 161*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v3, v5 162*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs1, v2, v4 163*e9d12c24SStefan Pintilie; PWR9BE-NEXT: li r3, 0 164*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs1, vs0 165*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v2, vs0 166*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, v2 167*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxspltw vs1, vs0, 1 168*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland v2, vs0, vs1 169*e9d12c24SStefan Pintilie; PWR9BE-NEXT: vextuwlx r3, r3, v2 170*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 171*e9d12c24SStefan Pintilie; 172*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v16i32: 173*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 174*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs1, v2, v4 175*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v3, v5 176*e9d12c24SStefan Pintilie; PWR10LE-NEXT: li r3, 0 177*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs2, vs1, v3, v5, 1 178*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v2, vs2 179*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs0, vs1, vs0, v2, 1 180*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxspltw vs0, vs0, 2 181*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval v2, vs2, v2, vs0, 1 182*e9d12c24SStefan Pintilie; PWR10LE-NEXT: vextuwrx r3, r3, v2 183*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 184*e9d12c24SStefan Pintilie; 185*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v16i32: 186*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 187*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs1, v2, v4 188*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v3, v5 189*e9d12c24SStefan Pintilie; PWR10BE-NEXT: li r3, 0 190*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs2, vs1, v3, v5, 1 191*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v2, vs2 192*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs0, vs1, vs0, v2, 1 193*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxspltw vs0, vs0, 1 194*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval v2, vs2, v2, vs0, 1 195*e9d12c24SStefan Pintilie; PWR10BE-NEXT: vextuwlx r3, r3, v2 196*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 197*e9d12c24SStefan Pintilieentry: 198*e9d12c24SStefan Pintilie %0 = call i32 @llvm.vector.reduce.and.v16i32(<16 x i32> %a) 199*e9d12c24SStefan Pintilie ret i32 %0 200*e9d12c24SStefan Pintilie} 201*e9d12c24SStefan Pintilie 202*e9d12c24SStefan Pintiliedeclare i32 @llvm.vector.reduce.and.v2i32(<2 x i32>) #0 203*e9d12c24SStefan Pintiliedeclare i32 @llvm.vector.reduce.and.v4i32(<4 x i32>) #0 204*e9d12c24SStefan Pintiliedeclare i32 @llvm.vector.reduce.and.v8i32(<8 x i32>) #0 205*e9d12c24SStefan Pintiliedeclare i32 @llvm.vector.reduce.and.v16i32(<16 x i32>) #0 206*e9d12c24SStefan Pintilie 207*e9d12c24SStefan Pintilie;; 208*e9d12c24SStefan Pintilie;; Vectors of type i64 209*e9d12c24SStefan Pintilie;; 210*e9d12c24SStefan Pintiliedefine dso_local i64 @v2i64(<2 x i64> %a) local_unnamed_addr #0 { 211*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v2i64: 212*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 213*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v3, v2 214*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v2, v3 215*e9d12c24SStefan Pintilie; PWR9LE-NEXT: mfvsrld r3, vs0 216*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 217*e9d12c24SStefan Pintilie; 218*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v2i64: 219*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 220*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v3, v2 221*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v2, v3 222*e9d12c24SStefan Pintilie; PWR9BE-NEXT: mffprd r3, f0 223*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 224*e9d12c24SStefan Pintilie; 225*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v2i64: 226*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 227*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v3, v2 228*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v2, v3 229*e9d12c24SStefan Pintilie; PWR10LE-NEXT: mfvsrld r3, vs0 230*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 231*e9d12c24SStefan Pintilie; 232*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v2i64: 233*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 234*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v3, v2 235*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v2, v3 236*e9d12c24SStefan Pintilie; PWR10BE-NEXT: mffprd r3, f0 237*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 238*e9d12c24SStefan Pintilieentry: 239*e9d12c24SStefan Pintilie %0 = call i64 @llvm.vector.reduce.and.v2i64(<2 x i64> %a) 240*e9d12c24SStefan Pintilie ret i64 %0 241*e9d12c24SStefan Pintilie} 242*e9d12c24SStefan Pintilie 243*e9d12c24SStefan Pintiliedefine dso_local i64 @v4i64(<4 x i64> %a) local_unnamed_addr #0 { 244*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v4i64: 245*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 246*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v2, v3 247*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v2, vs0 248*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, v2 249*e9d12c24SStefan Pintilie; PWR9LE-NEXT: mfvsrld r3, vs0 250*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 251*e9d12c24SStefan Pintilie; 252*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v4i64: 253*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 254*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v2, v3 255*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v2, vs0 256*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, v2 257*e9d12c24SStefan Pintilie; PWR9BE-NEXT: mffprd r3, f0 258*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 259*e9d12c24SStefan Pintilie; 260*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v4i64: 261*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 262*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v2, v3 263*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v4, vs0 264*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs0, v2, v3, v4, 1 265*e9d12c24SStefan Pintilie; PWR10LE-NEXT: mfvsrld r3, vs0 266*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 267*e9d12c24SStefan Pintilie; 268*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v4i64: 269*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 270*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v2, v3 271*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v4, vs0 272*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs0, v2, v3, v4, 1 273*e9d12c24SStefan Pintilie; PWR10BE-NEXT: mffprd r3, f0 274*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 275*e9d12c24SStefan Pintilieentry: 276*e9d12c24SStefan Pintilie %0 = call i64 @llvm.vector.reduce.and.v4i64(<4 x i64> %a) 277*e9d12c24SStefan Pintilie ret i64 %0 278*e9d12c24SStefan Pintilie} 279*e9d12c24SStefan Pintilie 280*e9d12c24SStefan Pintiliedefine dso_local i64 @v8i64(<8 x i64> %a) local_unnamed_addr #0 { 281*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v8i64: 282*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 283*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v3, v5 284*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs1, v2, v4 285*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs1, vs0 286*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v2, vs0 287*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, v2 288*e9d12c24SStefan Pintilie; PWR9LE-NEXT: mfvsrld r3, vs0 289*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 290*e9d12c24SStefan Pintilie; 291*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v8i64: 292*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 293*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v3, v5 294*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs1, v2, v4 295*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs1, vs0 296*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v2, vs0 297*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, v2 298*e9d12c24SStefan Pintilie; PWR9BE-NEXT: mffprd r3, f0 299*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 300*e9d12c24SStefan Pintilie; 301*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v8i64: 302*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 303*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs1, v2, v4 304*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v3, v5 305*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs2, vs1, v3, v5, 1 306*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v2, vs2 307*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs0, vs1, vs0, v2, 1 308*e9d12c24SStefan Pintilie; PWR10LE-NEXT: mfvsrld r3, vs0 309*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 310*e9d12c24SStefan Pintilie; 311*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v8i64: 312*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 313*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs1, v2, v4 314*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v3, v5 315*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs2, vs1, v3, v5, 1 316*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v2, vs2 317*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs0, vs1, vs0, v2, 1 318*e9d12c24SStefan Pintilie; PWR10BE-NEXT: mffprd r3, f0 319*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 320*e9d12c24SStefan Pintilieentry: 321*e9d12c24SStefan Pintilie %0 = call i64 @llvm.vector.reduce.and.v8i64(<8 x i64> %a) 322*e9d12c24SStefan Pintilie ret i64 %0 323*e9d12c24SStefan Pintilie} 324*e9d12c24SStefan Pintilie 325*e9d12c24SStefan Pintiliedefine dso_local i64 @v16i64(<16 x i64> %a) local_unnamed_addr #0 { 326*e9d12c24SStefan Pintilie; PWR9LE-LABEL: v16i64: 327*e9d12c24SStefan Pintilie; PWR9LE: # %bb.0: # %entry 328*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, v4, v8 329*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs1, v2, v6 330*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs2, v5, v9 331*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs3, v3, v7 332*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs2, vs3, vs2 333*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs1, vs0 334*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, vs2 335*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxswapd v2, vs0 336*e9d12c24SStefan Pintilie; PWR9LE-NEXT: xxland vs0, vs0, v2 337*e9d12c24SStefan Pintilie; PWR9LE-NEXT: mfvsrld r3, vs0 338*e9d12c24SStefan Pintilie; PWR9LE-NEXT: blr 339*e9d12c24SStefan Pintilie; 340*e9d12c24SStefan Pintilie; PWR9BE-LABEL: v16i64: 341*e9d12c24SStefan Pintilie; PWR9BE: # %bb.0: # %entry 342*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, v4, v8 343*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs1, v2, v6 344*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs2, v5, v9 345*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs3, v3, v7 346*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs2, vs3, vs2 347*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs1, vs0 348*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, vs2 349*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxswapd v2, vs0 350*e9d12c24SStefan Pintilie; PWR9BE-NEXT: xxland vs0, vs0, v2 351*e9d12c24SStefan Pintilie; PWR9BE-NEXT: mffprd r3, f0 352*e9d12c24SStefan Pintilie; PWR9BE-NEXT: blr 353*e9d12c24SStefan Pintilie; 354*e9d12c24SStefan Pintilie; PWR10LE-LABEL: v16i64: 355*e9d12c24SStefan Pintilie; PWR10LE: # %bb.0: # %entry 356*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs1, v2, v6 357*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs0, v5, v9 358*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxland vs2, v3, v7 359*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs1, vs1, v4, v8, 1 360*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs3, vs2, v5, v9, 1 361*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs0, vs1, vs2, vs0, 1 362*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxswapd v2, vs0 363*e9d12c24SStefan Pintilie; PWR10LE-NEXT: xxeval vs0, vs1, vs3, v2, 1 364*e9d12c24SStefan Pintilie; PWR10LE-NEXT: mfvsrld r3, vs0 365*e9d12c24SStefan Pintilie; PWR10LE-NEXT: blr 366*e9d12c24SStefan Pintilie; 367*e9d12c24SStefan Pintilie; PWR10BE-LABEL: v16i64: 368*e9d12c24SStefan Pintilie; PWR10BE: # %bb.0: # %entry 369*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs1, v2, v6 370*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs0, v5, v9 371*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxland vs2, v3, v7 372*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs1, vs1, v4, v8, 1 373*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs3, vs2, v5, v9, 1 374*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs0, vs1, vs2, vs0, 1 375*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxswapd v2, vs0 376*e9d12c24SStefan Pintilie; PWR10BE-NEXT: xxeval vs0, vs1, vs3, v2, 1 377*e9d12c24SStefan Pintilie; PWR10BE-NEXT: mffprd r3, f0 378*e9d12c24SStefan Pintilie; PWR10BE-NEXT: blr 379*e9d12c24SStefan Pintilieentry: 380*e9d12c24SStefan Pintilie %0 = call i64 @llvm.vector.reduce.and.v16i64(<16 x i64> %a) 381*e9d12c24SStefan Pintilie ret i64 %0 382*e9d12c24SStefan Pintilie} 383*e9d12c24SStefan Pintilie 384*e9d12c24SStefan Pintiliedeclare i64 @llvm.vector.reduce.and.v2i64(<2 x i64>) #0 385*e9d12c24SStefan Pintiliedeclare i64 @llvm.vector.reduce.and.v4i64(<4 x i64>) #0 386*e9d12c24SStefan Pintiliedeclare i64 @llvm.vector.reduce.and.v8i64(<8 x i64>) #0 387*e9d12c24SStefan Pintiliedeclare i64 @llvm.vector.reduce.and.v16i64(<16 x i64>) #0 388*e9d12c24SStefan Pintilie 389*e9d12c24SStefan Pintilie 390*e9d12c24SStefan Pintilieattributes #0 = { nounwind } 391