1346c1f26S4vtomat; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py 2*09058654SEric Biggers; RUN: sed 's/iXLen/i32/g' %s | llc -mtriple=riscv32 -mattr=+v,+zvbb \ 3346c1f26S4vtomat; RUN: -verify-machineinstrs | FileCheck %s --check-prefixes=CHECK 4*09058654SEric Biggers; RUN: sed 's/iXLen/i64/g' %s | llc -mtriple=riscv64 -mattr=+v,+zvbb \ 5346c1f26S4vtomat; RUN: -verify-machineinstrs | FileCheck %s --check-prefixes=CHECK 6346c1f26S4vtomat 7346c1f26S4vtomatdeclare <vscale x 1 x i8> @llvm.riscv.vclz.nxv1i8( 8346c1f26S4vtomat <vscale x 1 x i8>, 9346c1f26S4vtomat <vscale x 1 x i8>, 10346c1f26S4vtomat iXLen); 11346c1f26S4vtomat 12346c1f26S4vtomatdefine <vscale x 1 x i8> @intrinsic_vclz_vs_nxv1i8(<vscale x 1 x i8> %0, iXLen %1) nounwind { 13346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv1i8: 14346c1f26S4vtomat; CHECK: # %bb.0: # %entry 15346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf8, ta, ma 16346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 17346c1f26S4vtomat; CHECK-NEXT: ret 18346c1f26S4vtomatentry: 19346c1f26S4vtomat %a = call <vscale x 1 x i8> @llvm.riscv.vclz.nxv1i8( 20346c1f26S4vtomat <vscale x 1 x i8> undef, 21346c1f26S4vtomat <vscale x 1 x i8> %0, 22346c1f26S4vtomat iXLen %1) 23346c1f26S4vtomat 24346c1f26S4vtomat ret <vscale x 1 x i8> %a 25346c1f26S4vtomat} 26346c1f26S4vtomat 27346c1f26S4vtomatdeclare <vscale x 1 x i8> @llvm.riscv.vclz.mask.nxv1i8( 28346c1f26S4vtomat <vscale x 1 x i8>, 29346c1f26S4vtomat <vscale x 1 x i8>, 30346c1f26S4vtomat <vscale x 1 x i1>, 31346c1f26S4vtomat iXLen, 32346c1f26S4vtomat iXLen); 33346c1f26S4vtomat 34346c1f26S4vtomatdefine <vscale x 1 x i8> @intrinsic_vclz_mask_vs_nxv1i8(<vscale x 1 x i1> %0, <vscale x 1 x i8> %1, <vscale x 1 x i8> %2, iXLen %3) nounwind { 35346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv1i8: 36346c1f26S4vtomat; CHECK: # %bb.0: # %entry 37346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf8, ta, mu 38346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 39346c1f26S4vtomat; CHECK-NEXT: ret 40346c1f26S4vtomatentry: 41346c1f26S4vtomat %a = call <vscale x 1 x i8> @llvm.riscv.vclz.mask.nxv1i8( 42346c1f26S4vtomat <vscale x 1 x i8> %1, 43346c1f26S4vtomat <vscale x 1 x i8> %2, 44346c1f26S4vtomat <vscale x 1 x i1> %0, 45346c1f26S4vtomat iXLen %3, iXLen 1) 46346c1f26S4vtomat 47346c1f26S4vtomat ret <vscale x 1 x i8> %a 48346c1f26S4vtomat} 49346c1f26S4vtomat 50346c1f26S4vtomatdeclare <vscale x 2 x i8> @llvm.riscv.vclz.nxv2i8( 51346c1f26S4vtomat <vscale x 2 x i8>, 52346c1f26S4vtomat <vscale x 2 x i8>, 53346c1f26S4vtomat iXLen); 54346c1f26S4vtomat 55346c1f26S4vtomatdefine <vscale x 2 x i8> @intrinsic_vclz_vs_nxv2i8(<vscale x 2 x i8> %0, iXLen %1) nounwind { 56346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv2i8: 57346c1f26S4vtomat; CHECK: # %bb.0: # %entry 58346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf4, ta, ma 59346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 60346c1f26S4vtomat; CHECK-NEXT: ret 61346c1f26S4vtomatentry: 62346c1f26S4vtomat %a = call <vscale x 2 x i8> @llvm.riscv.vclz.nxv2i8( 63346c1f26S4vtomat <vscale x 2 x i8> undef, 64346c1f26S4vtomat <vscale x 2 x i8> %0, 65346c1f26S4vtomat iXLen %1) 66346c1f26S4vtomat 67346c1f26S4vtomat ret <vscale x 2 x i8> %a 68346c1f26S4vtomat} 69346c1f26S4vtomat 70346c1f26S4vtomatdeclare <vscale x 2 x i8> @llvm.riscv.vclz.mask.nxv2i8( 71346c1f26S4vtomat <vscale x 2 x i8>, 72346c1f26S4vtomat <vscale x 2 x i8>, 73346c1f26S4vtomat <vscale x 2 x i1>, 74346c1f26S4vtomat iXLen, 75346c1f26S4vtomat iXLen); 76346c1f26S4vtomat 77346c1f26S4vtomatdefine <vscale x 2 x i8> @intrinsic_vclz_mask_vs_nxv2i8(<vscale x 2 x i1> %0, <vscale x 2 x i8> %1, <vscale x 2 x i8> %2, iXLen %3) nounwind { 78346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv2i8: 79346c1f26S4vtomat; CHECK: # %bb.0: # %entry 80346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf4, ta, mu 81346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 82346c1f26S4vtomat; CHECK-NEXT: ret 83346c1f26S4vtomatentry: 84346c1f26S4vtomat %a = call <vscale x 2 x i8> @llvm.riscv.vclz.mask.nxv2i8( 85346c1f26S4vtomat <vscale x 2 x i8> %1, 86346c1f26S4vtomat <vscale x 2 x i8> %2, 87346c1f26S4vtomat <vscale x 2 x i1> %0, 88346c1f26S4vtomat iXLen %3, iXLen 1) 89346c1f26S4vtomat 90346c1f26S4vtomat ret <vscale x 2 x i8> %a 91346c1f26S4vtomat} 92346c1f26S4vtomat 93346c1f26S4vtomatdeclare <vscale x 4 x i8> @llvm.riscv.vclz.nxv4i8( 94346c1f26S4vtomat <vscale x 4 x i8>, 95346c1f26S4vtomat <vscale x 4 x i8>, 96346c1f26S4vtomat iXLen); 97346c1f26S4vtomat 98346c1f26S4vtomatdefine <vscale x 4 x i8> @intrinsic_vclz_vs_nxv4i8(<vscale x 4 x i8> %0, iXLen %1) nounwind { 99346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv4i8: 100346c1f26S4vtomat; CHECK: # %bb.0: # %entry 101346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf2, ta, ma 102346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 103346c1f26S4vtomat; CHECK-NEXT: ret 104346c1f26S4vtomatentry: 105346c1f26S4vtomat %a = call <vscale x 4 x i8> @llvm.riscv.vclz.nxv4i8( 106346c1f26S4vtomat <vscale x 4 x i8> undef, 107346c1f26S4vtomat <vscale x 4 x i8> %0, 108346c1f26S4vtomat iXLen %1) 109346c1f26S4vtomat 110346c1f26S4vtomat ret <vscale x 4 x i8> %a 111346c1f26S4vtomat} 112346c1f26S4vtomat 113346c1f26S4vtomatdeclare <vscale x 4 x i8> @llvm.riscv.vclz.mask.nxv4i8( 114346c1f26S4vtomat <vscale x 4 x i8>, 115346c1f26S4vtomat <vscale x 4 x i8>, 116346c1f26S4vtomat <vscale x 4 x i1>, 117346c1f26S4vtomat iXLen, 118346c1f26S4vtomat iXLen); 119346c1f26S4vtomat 120346c1f26S4vtomatdefine <vscale x 4 x i8> @intrinsic_vclz_mask_vs_nxv4i8(<vscale x 4 x i1> %0, <vscale x 4 x i8> %1, <vscale x 4 x i8> %2, iXLen %3) nounwind { 121346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv4i8: 122346c1f26S4vtomat; CHECK: # %bb.0: # %entry 123346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, mf2, ta, mu 124346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 125346c1f26S4vtomat; CHECK-NEXT: ret 126346c1f26S4vtomatentry: 127346c1f26S4vtomat %a = call <vscale x 4 x i8> @llvm.riscv.vclz.mask.nxv4i8( 128346c1f26S4vtomat <vscale x 4 x i8> %1, 129346c1f26S4vtomat <vscale x 4 x i8> %2, 130346c1f26S4vtomat <vscale x 4 x i1> %0, 131346c1f26S4vtomat iXLen %3, iXLen 1) 132346c1f26S4vtomat 133346c1f26S4vtomat ret <vscale x 4 x i8> %a 134346c1f26S4vtomat} 135346c1f26S4vtomat 136346c1f26S4vtomatdeclare <vscale x 8 x i8> @llvm.riscv.vclz.nxv8i8( 137346c1f26S4vtomat <vscale x 8 x i8>, 138346c1f26S4vtomat <vscale x 8 x i8>, 139346c1f26S4vtomat iXLen); 140346c1f26S4vtomat 141346c1f26S4vtomatdefine <vscale x 8 x i8> @intrinsic_vclz_vs_nxv8i8(<vscale x 8 x i8> %0, iXLen %1) nounwind { 142346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv8i8: 143346c1f26S4vtomat; CHECK: # %bb.0: # %entry 144346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m1, ta, ma 145346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 146346c1f26S4vtomat; CHECK-NEXT: ret 147346c1f26S4vtomatentry: 148346c1f26S4vtomat %a = call <vscale x 8 x i8> @llvm.riscv.vclz.nxv8i8( 149346c1f26S4vtomat <vscale x 8 x i8> undef, 150346c1f26S4vtomat <vscale x 8 x i8> %0, 151346c1f26S4vtomat iXLen %1) 152346c1f26S4vtomat 153346c1f26S4vtomat ret <vscale x 8 x i8> %a 154346c1f26S4vtomat} 155346c1f26S4vtomat 156346c1f26S4vtomatdeclare <vscale x 8 x i8> @llvm.riscv.vclz.mask.nxv8i8( 157346c1f26S4vtomat <vscale x 8 x i8>, 158346c1f26S4vtomat <vscale x 8 x i8>, 159346c1f26S4vtomat <vscale x 8 x i1>, 160346c1f26S4vtomat iXLen, 161346c1f26S4vtomat iXLen); 162346c1f26S4vtomat 163346c1f26S4vtomatdefine <vscale x 8 x i8> @intrinsic_vclz_mask_vs_nxv8i8(<vscale x 8 x i1> %0, <vscale x 8 x i8> %1, <vscale x 8 x i8> %2, iXLen %3) nounwind { 164346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv8i8: 165346c1f26S4vtomat; CHECK: # %bb.0: # %entry 166346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m1, ta, mu 167346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 168346c1f26S4vtomat; CHECK-NEXT: ret 169346c1f26S4vtomatentry: 170346c1f26S4vtomat %a = call <vscale x 8 x i8> @llvm.riscv.vclz.mask.nxv8i8( 171346c1f26S4vtomat <vscale x 8 x i8> %1, 172346c1f26S4vtomat <vscale x 8 x i8> %2, 173346c1f26S4vtomat <vscale x 8 x i1> %0, 174346c1f26S4vtomat iXLen %3, iXLen 1) 175346c1f26S4vtomat 176346c1f26S4vtomat ret <vscale x 8 x i8> %a 177346c1f26S4vtomat} 178346c1f26S4vtomat 179346c1f26S4vtomatdeclare <vscale x 16 x i8> @llvm.riscv.vclz.nxv16i8( 180346c1f26S4vtomat <vscale x 16 x i8>, 181346c1f26S4vtomat <vscale x 16 x i8>, 182346c1f26S4vtomat iXLen); 183346c1f26S4vtomat 184346c1f26S4vtomatdefine <vscale x 16 x i8> @intrinsic_vclz_vs_nxv16i8(<vscale x 16 x i8> %0, iXLen %1) nounwind { 185346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv16i8: 186346c1f26S4vtomat; CHECK: # %bb.0: # %entry 187346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m2, ta, ma 188346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 189346c1f26S4vtomat; CHECK-NEXT: ret 190346c1f26S4vtomatentry: 191346c1f26S4vtomat %a = call <vscale x 16 x i8> @llvm.riscv.vclz.nxv16i8( 192346c1f26S4vtomat <vscale x 16 x i8> undef, 193346c1f26S4vtomat <vscale x 16 x i8> %0, 194346c1f26S4vtomat iXLen %1) 195346c1f26S4vtomat 196346c1f26S4vtomat ret <vscale x 16 x i8> %a 197346c1f26S4vtomat} 198346c1f26S4vtomat 199346c1f26S4vtomatdeclare <vscale x 16 x i8> @llvm.riscv.vclz.mask.nxv16i8( 200346c1f26S4vtomat <vscale x 16 x i8>, 201346c1f26S4vtomat <vscale x 16 x i8>, 202346c1f26S4vtomat <vscale x 16 x i1>, 203346c1f26S4vtomat iXLen, 204346c1f26S4vtomat iXLen); 205346c1f26S4vtomat 206346c1f26S4vtomatdefine <vscale x 16 x i8> @intrinsic_vclz_mask_vs_nxv16i8(<vscale x 16 x i1> %0, <vscale x 16 x i8> %1, <vscale x 16 x i8> %2, iXLen %3) nounwind { 207346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv16i8: 208346c1f26S4vtomat; CHECK: # %bb.0: # %entry 209346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m2, ta, mu 210346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v10, v0.t 211346c1f26S4vtomat; CHECK-NEXT: ret 212346c1f26S4vtomatentry: 213346c1f26S4vtomat %a = call <vscale x 16 x i8> @llvm.riscv.vclz.mask.nxv16i8( 214346c1f26S4vtomat <vscale x 16 x i8> %1, 215346c1f26S4vtomat <vscale x 16 x i8> %2, 216346c1f26S4vtomat <vscale x 16 x i1> %0, 217346c1f26S4vtomat iXLen %3, iXLen 1) 218346c1f26S4vtomat 219346c1f26S4vtomat ret <vscale x 16 x i8> %a 220346c1f26S4vtomat} 221346c1f26S4vtomat 222346c1f26S4vtomatdeclare <vscale x 32 x i8> @llvm.riscv.vclz.nxv32i8( 223346c1f26S4vtomat <vscale x 32 x i8>, 224346c1f26S4vtomat <vscale x 32 x i8>, 225346c1f26S4vtomat iXLen); 226346c1f26S4vtomat 227346c1f26S4vtomatdefine <vscale x 32 x i8> @intrinsic_vclz_vs_nxv32i8(<vscale x 32 x i8> %0, iXLen %1) nounwind { 228346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv32i8: 229346c1f26S4vtomat; CHECK: # %bb.0: # %entry 230346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m4, ta, ma 231346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 232346c1f26S4vtomat; CHECK-NEXT: ret 233346c1f26S4vtomatentry: 234346c1f26S4vtomat %a = call <vscale x 32 x i8> @llvm.riscv.vclz.nxv32i8( 235346c1f26S4vtomat <vscale x 32 x i8> undef, 236346c1f26S4vtomat <vscale x 32 x i8> %0, 237346c1f26S4vtomat iXLen %1) 238346c1f26S4vtomat 239346c1f26S4vtomat ret <vscale x 32 x i8> %a 240346c1f26S4vtomat} 241346c1f26S4vtomat 242346c1f26S4vtomatdeclare <vscale x 32 x i8> @llvm.riscv.vclz.mask.nxv32i8( 243346c1f26S4vtomat <vscale x 32 x i8>, 244346c1f26S4vtomat <vscale x 32 x i8>, 245346c1f26S4vtomat <vscale x 32 x i1>, 246346c1f26S4vtomat iXLen, 247346c1f26S4vtomat iXLen); 248346c1f26S4vtomat 249346c1f26S4vtomatdefine <vscale x 32 x i8> @intrinsic_vclz_mask_vs_nxv32i8(<vscale x 32 x i1> %0, <vscale x 32 x i8> %1, <vscale x 32 x i8> %2, iXLen %3) nounwind { 250346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv32i8: 251346c1f26S4vtomat; CHECK: # %bb.0: # %entry 252346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m4, ta, mu 253346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v12, v0.t 254346c1f26S4vtomat; CHECK-NEXT: ret 255346c1f26S4vtomatentry: 256346c1f26S4vtomat %a = call <vscale x 32 x i8> @llvm.riscv.vclz.mask.nxv32i8( 257346c1f26S4vtomat <vscale x 32 x i8> %1, 258346c1f26S4vtomat <vscale x 32 x i8> %2, 259346c1f26S4vtomat <vscale x 32 x i1> %0, 260346c1f26S4vtomat iXLen %3, iXLen 1) 261346c1f26S4vtomat 262346c1f26S4vtomat ret <vscale x 32 x i8> %a 263346c1f26S4vtomat} 264346c1f26S4vtomat 265346c1f26S4vtomatdeclare <vscale x 64 x i8> @llvm.riscv.vclz.nxv64i8( 266346c1f26S4vtomat <vscale x 64 x i8>, 267346c1f26S4vtomat <vscale x 64 x i8>, 268346c1f26S4vtomat iXLen); 269346c1f26S4vtomat 270346c1f26S4vtomatdefine <vscale x 64 x i8> @intrinsic_vclz_vs_nxv64i8(<vscale x 64 x i8> %0, iXLen %1) nounwind { 271346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv64i8: 272346c1f26S4vtomat; CHECK: # %bb.0: # %entry 273346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m8, ta, ma 274346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 275346c1f26S4vtomat; CHECK-NEXT: ret 276346c1f26S4vtomatentry: 277346c1f26S4vtomat %a = call <vscale x 64 x i8> @llvm.riscv.vclz.nxv64i8( 278346c1f26S4vtomat <vscale x 64 x i8> undef, 279346c1f26S4vtomat <vscale x 64 x i8> %0, 280346c1f26S4vtomat iXLen %1) 281346c1f26S4vtomat 282346c1f26S4vtomat ret <vscale x 64 x i8> %a 283346c1f26S4vtomat} 284346c1f26S4vtomat 285346c1f26S4vtomatdeclare <vscale x 64 x i8> @llvm.riscv.vclz.mask.nxv64i8( 286346c1f26S4vtomat <vscale x 64 x i8>, 287346c1f26S4vtomat <vscale x 64 x i8>, 288346c1f26S4vtomat <vscale x 64 x i1>, 289346c1f26S4vtomat iXLen, 290346c1f26S4vtomat iXLen); 291346c1f26S4vtomat 292346c1f26S4vtomatdefine <vscale x 64 x i8> @intrinsic_vclz_mask_vs_nxv64i8(<vscale x 64 x i1> %0, <vscale x 64 x i8> %1, <vscale x 64 x i8> %2, iXLen %3) nounwind { 293346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv64i8: 294346c1f26S4vtomat; CHECK: # %bb.0: # %entry 295346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e8, m8, ta, mu 296346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v16, v0.t 297346c1f26S4vtomat; CHECK-NEXT: ret 298346c1f26S4vtomatentry: 299346c1f26S4vtomat %a = call <vscale x 64 x i8> @llvm.riscv.vclz.mask.nxv64i8( 300346c1f26S4vtomat <vscale x 64 x i8> %1, 301346c1f26S4vtomat <vscale x 64 x i8> %2, 302346c1f26S4vtomat <vscale x 64 x i1> %0, 303346c1f26S4vtomat iXLen %3, iXLen 1) 304346c1f26S4vtomat 305346c1f26S4vtomat ret <vscale x 64 x i8> %a 306346c1f26S4vtomat} 307346c1f26S4vtomat 308346c1f26S4vtomatdeclare <vscale x 1 x i16> @llvm.riscv.vclz.nxv1i16( 309346c1f26S4vtomat <vscale x 1 x i16>, 310346c1f26S4vtomat <vscale x 1 x i16>, 311346c1f26S4vtomat iXLen); 312346c1f26S4vtomat 313346c1f26S4vtomatdefine <vscale x 1 x i16> @intrinsic_vclz_vs_nxv1i16(<vscale x 1 x i16> %0, iXLen %1) nounwind { 314346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv1i16: 315346c1f26S4vtomat; CHECK: # %bb.0: # %entry 316346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, mf4, ta, ma 317346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 318346c1f26S4vtomat; CHECK-NEXT: ret 319346c1f26S4vtomatentry: 320346c1f26S4vtomat %a = call <vscale x 1 x i16> @llvm.riscv.vclz.nxv1i16( 321346c1f26S4vtomat <vscale x 1 x i16> undef, 322346c1f26S4vtomat <vscale x 1 x i16> %0, 323346c1f26S4vtomat iXLen %1) 324346c1f26S4vtomat 325346c1f26S4vtomat ret <vscale x 1 x i16> %a 326346c1f26S4vtomat} 327346c1f26S4vtomat 328346c1f26S4vtomatdeclare <vscale x 1 x i16> @llvm.riscv.vclz.mask.nxv1i16( 329346c1f26S4vtomat <vscale x 1 x i16>, 330346c1f26S4vtomat <vscale x 1 x i16>, 331346c1f26S4vtomat <vscale x 1 x i1>, 332346c1f26S4vtomat iXLen, 333346c1f26S4vtomat iXLen); 334346c1f26S4vtomat 335346c1f26S4vtomatdefine <vscale x 1 x i16> @intrinsic_vclz_mask_vs_nxv1i16(<vscale x 1 x i1> %0, <vscale x 1 x i16> %1, <vscale x 1 x i16> %2, iXLen %3) nounwind { 336346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv1i16: 337346c1f26S4vtomat; CHECK: # %bb.0: # %entry 338346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, mf4, ta, mu 339346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 340346c1f26S4vtomat; CHECK-NEXT: ret 341346c1f26S4vtomatentry: 342346c1f26S4vtomat %a = call <vscale x 1 x i16> @llvm.riscv.vclz.mask.nxv1i16( 343346c1f26S4vtomat <vscale x 1 x i16> %1, 344346c1f26S4vtomat <vscale x 1 x i16> %2, 345346c1f26S4vtomat <vscale x 1 x i1> %0, 346346c1f26S4vtomat iXLen %3, iXLen 1) 347346c1f26S4vtomat 348346c1f26S4vtomat ret <vscale x 1 x i16> %a 349346c1f26S4vtomat} 350346c1f26S4vtomat 351346c1f26S4vtomatdeclare <vscale x 2 x i16> @llvm.riscv.vclz.nxv2i16( 352346c1f26S4vtomat <vscale x 2 x i16>, 353346c1f26S4vtomat <vscale x 2 x i16>, 354346c1f26S4vtomat iXLen); 355346c1f26S4vtomat 356346c1f26S4vtomatdefine <vscale x 2 x i16> @intrinsic_vclz_vs_nxv2i16(<vscale x 2 x i16> %0, iXLen %1) nounwind { 357346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv2i16: 358346c1f26S4vtomat; CHECK: # %bb.0: # %entry 359346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, mf2, ta, ma 360346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 361346c1f26S4vtomat; CHECK-NEXT: ret 362346c1f26S4vtomatentry: 363346c1f26S4vtomat %a = call <vscale x 2 x i16> @llvm.riscv.vclz.nxv2i16( 364346c1f26S4vtomat <vscale x 2 x i16> undef, 365346c1f26S4vtomat <vscale x 2 x i16> %0, 366346c1f26S4vtomat iXLen %1) 367346c1f26S4vtomat 368346c1f26S4vtomat ret <vscale x 2 x i16> %a 369346c1f26S4vtomat} 370346c1f26S4vtomat 371346c1f26S4vtomatdeclare <vscale x 2 x i16> @llvm.riscv.vclz.mask.nxv2i16( 372346c1f26S4vtomat <vscale x 2 x i16>, 373346c1f26S4vtomat <vscale x 2 x i16>, 374346c1f26S4vtomat <vscale x 2 x i1>, 375346c1f26S4vtomat iXLen, 376346c1f26S4vtomat iXLen); 377346c1f26S4vtomat 378346c1f26S4vtomatdefine <vscale x 2 x i16> @intrinsic_vclz_mask_vs_nxv2i16(<vscale x 2 x i1> %0, <vscale x 2 x i16> %1, <vscale x 2 x i16> %2, iXLen %3) nounwind { 379346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv2i16: 380346c1f26S4vtomat; CHECK: # %bb.0: # %entry 381346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, mf2, ta, mu 382346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 383346c1f26S4vtomat; CHECK-NEXT: ret 384346c1f26S4vtomatentry: 385346c1f26S4vtomat %a = call <vscale x 2 x i16> @llvm.riscv.vclz.mask.nxv2i16( 386346c1f26S4vtomat <vscale x 2 x i16> %1, 387346c1f26S4vtomat <vscale x 2 x i16> %2, 388346c1f26S4vtomat <vscale x 2 x i1> %0, 389346c1f26S4vtomat iXLen %3, iXLen 1) 390346c1f26S4vtomat 391346c1f26S4vtomat ret <vscale x 2 x i16> %a 392346c1f26S4vtomat} 393346c1f26S4vtomat 394346c1f26S4vtomatdeclare <vscale x 4 x i16> @llvm.riscv.vclz.nxv4i16( 395346c1f26S4vtomat <vscale x 4 x i16>, 396346c1f26S4vtomat <vscale x 4 x i16>, 397346c1f26S4vtomat iXLen); 398346c1f26S4vtomat 399346c1f26S4vtomatdefine <vscale x 4 x i16> @intrinsic_vclz_vs_nxv4i16(<vscale x 4 x i16> %0, iXLen %1) nounwind { 400346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv4i16: 401346c1f26S4vtomat; CHECK: # %bb.0: # %entry 402346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m1, ta, ma 403346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 404346c1f26S4vtomat; CHECK-NEXT: ret 405346c1f26S4vtomatentry: 406346c1f26S4vtomat %a = call <vscale x 4 x i16> @llvm.riscv.vclz.nxv4i16( 407346c1f26S4vtomat <vscale x 4 x i16> undef, 408346c1f26S4vtomat <vscale x 4 x i16> %0, 409346c1f26S4vtomat iXLen %1) 410346c1f26S4vtomat 411346c1f26S4vtomat ret <vscale x 4 x i16> %a 412346c1f26S4vtomat} 413346c1f26S4vtomat 414346c1f26S4vtomatdeclare <vscale x 4 x i16> @llvm.riscv.vclz.mask.nxv4i16( 415346c1f26S4vtomat <vscale x 4 x i16>, 416346c1f26S4vtomat <vscale x 4 x i16>, 417346c1f26S4vtomat <vscale x 4 x i1>, 418346c1f26S4vtomat iXLen, 419346c1f26S4vtomat iXLen); 420346c1f26S4vtomat 421346c1f26S4vtomatdefine <vscale x 4 x i16> @intrinsic_vclz_mask_vs_nxv4i16(<vscale x 4 x i1> %0, <vscale x 4 x i16> %1, <vscale x 4 x i16> %2, iXLen %3) nounwind { 422346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv4i16: 423346c1f26S4vtomat; CHECK: # %bb.0: # %entry 424346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m1, ta, mu 425346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 426346c1f26S4vtomat; CHECK-NEXT: ret 427346c1f26S4vtomatentry: 428346c1f26S4vtomat %a = call <vscale x 4 x i16> @llvm.riscv.vclz.mask.nxv4i16( 429346c1f26S4vtomat <vscale x 4 x i16> %1, 430346c1f26S4vtomat <vscale x 4 x i16> %2, 431346c1f26S4vtomat <vscale x 4 x i1> %0, 432346c1f26S4vtomat iXLen %3, iXLen 1) 433346c1f26S4vtomat 434346c1f26S4vtomat ret <vscale x 4 x i16> %a 435346c1f26S4vtomat} 436346c1f26S4vtomat 437346c1f26S4vtomatdeclare <vscale x 8 x i16> @llvm.riscv.vclz.nxv8i16( 438346c1f26S4vtomat <vscale x 8 x i16>, 439346c1f26S4vtomat <vscale x 8 x i16>, 440346c1f26S4vtomat iXLen); 441346c1f26S4vtomat 442346c1f26S4vtomatdefine <vscale x 8 x i16> @intrinsic_vclz_vs_nxv8i16(<vscale x 8 x i16> %0, iXLen %1) nounwind { 443346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv8i16: 444346c1f26S4vtomat; CHECK: # %bb.0: # %entry 445346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m2, ta, ma 446346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 447346c1f26S4vtomat; CHECK-NEXT: ret 448346c1f26S4vtomatentry: 449346c1f26S4vtomat %a = call <vscale x 8 x i16> @llvm.riscv.vclz.nxv8i16( 450346c1f26S4vtomat <vscale x 8 x i16> undef, 451346c1f26S4vtomat <vscale x 8 x i16> %0, 452346c1f26S4vtomat iXLen %1) 453346c1f26S4vtomat 454346c1f26S4vtomat ret <vscale x 8 x i16> %a 455346c1f26S4vtomat} 456346c1f26S4vtomat 457346c1f26S4vtomatdeclare <vscale x 8 x i16> @llvm.riscv.vclz.mask.nxv8i16( 458346c1f26S4vtomat <vscale x 8 x i16>, 459346c1f26S4vtomat <vscale x 8 x i16>, 460346c1f26S4vtomat <vscale x 8 x i1>, 461346c1f26S4vtomat iXLen, 462346c1f26S4vtomat iXLen); 463346c1f26S4vtomat 464346c1f26S4vtomatdefine <vscale x 8 x i16> @intrinsic_vclz_mask_vs_nxv8i16(<vscale x 8 x i1> %0, <vscale x 8 x i16> %1, <vscale x 8 x i16> %2, iXLen %3) nounwind { 465346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv8i16: 466346c1f26S4vtomat; CHECK: # %bb.0: # %entry 467346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m2, ta, mu 468346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v10, v0.t 469346c1f26S4vtomat; CHECK-NEXT: ret 470346c1f26S4vtomatentry: 471346c1f26S4vtomat %a = call <vscale x 8 x i16> @llvm.riscv.vclz.mask.nxv8i16( 472346c1f26S4vtomat <vscale x 8 x i16> %1, 473346c1f26S4vtomat <vscale x 8 x i16> %2, 474346c1f26S4vtomat <vscale x 8 x i1> %0, 475346c1f26S4vtomat iXLen %3, iXLen 1) 476346c1f26S4vtomat 477346c1f26S4vtomat ret <vscale x 8 x i16> %a 478346c1f26S4vtomat} 479346c1f26S4vtomat 480346c1f26S4vtomatdeclare <vscale x 16 x i16> @llvm.riscv.vclz.nxv16i16( 481346c1f26S4vtomat <vscale x 16 x i16>, 482346c1f26S4vtomat <vscale x 16 x i16>, 483346c1f26S4vtomat iXLen); 484346c1f26S4vtomat 485346c1f26S4vtomatdefine <vscale x 16 x i16> @intrinsic_vclz_vs_nxv16i16(<vscale x 16 x i16> %0, iXLen %1) nounwind { 486346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv16i16: 487346c1f26S4vtomat; CHECK: # %bb.0: # %entry 488346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m4, ta, ma 489346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 490346c1f26S4vtomat; CHECK-NEXT: ret 491346c1f26S4vtomatentry: 492346c1f26S4vtomat %a = call <vscale x 16 x i16> @llvm.riscv.vclz.nxv16i16( 493346c1f26S4vtomat <vscale x 16 x i16> undef, 494346c1f26S4vtomat <vscale x 16 x i16> %0, 495346c1f26S4vtomat iXLen %1) 496346c1f26S4vtomat 497346c1f26S4vtomat ret <vscale x 16 x i16> %a 498346c1f26S4vtomat} 499346c1f26S4vtomat 500346c1f26S4vtomatdeclare <vscale x 16 x i16> @llvm.riscv.vclz.mask.nxv16i16( 501346c1f26S4vtomat <vscale x 16 x i16>, 502346c1f26S4vtomat <vscale x 16 x i16>, 503346c1f26S4vtomat <vscale x 16 x i1>, 504346c1f26S4vtomat iXLen, 505346c1f26S4vtomat iXLen); 506346c1f26S4vtomat 507346c1f26S4vtomatdefine <vscale x 16 x i16> @intrinsic_vclz_mask_vs_nxv16i16(<vscale x 16 x i1> %0, <vscale x 16 x i16> %1, <vscale x 16 x i16> %2, iXLen %3) nounwind { 508346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv16i16: 509346c1f26S4vtomat; CHECK: # %bb.0: # %entry 510346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m4, ta, mu 511346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v12, v0.t 512346c1f26S4vtomat; CHECK-NEXT: ret 513346c1f26S4vtomatentry: 514346c1f26S4vtomat %a = call <vscale x 16 x i16> @llvm.riscv.vclz.mask.nxv16i16( 515346c1f26S4vtomat <vscale x 16 x i16> %1, 516346c1f26S4vtomat <vscale x 16 x i16> %2, 517346c1f26S4vtomat <vscale x 16 x i1> %0, 518346c1f26S4vtomat iXLen %3, iXLen 1) 519346c1f26S4vtomat 520346c1f26S4vtomat ret <vscale x 16 x i16> %a 521346c1f26S4vtomat} 522346c1f26S4vtomat 523346c1f26S4vtomatdeclare <vscale x 32 x i16> @llvm.riscv.vclz.nxv32i16( 524346c1f26S4vtomat <vscale x 32 x i16>, 525346c1f26S4vtomat <vscale x 32 x i16>, 526346c1f26S4vtomat iXLen); 527346c1f26S4vtomat 528346c1f26S4vtomatdefine <vscale x 32 x i16> @intrinsic_vclz_vs_nxv32i16(<vscale x 32 x i16> %0, iXLen %1) nounwind { 529346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv32i16: 530346c1f26S4vtomat; CHECK: # %bb.0: # %entry 531346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m8, ta, ma 532346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 533346c1f26S4vtomat; CHECK-NEXT: ret 534346c1f26S4vtomatentry: 535346c1f26S4vtomat %a = call <vscale x 32 x i16> @llvm.riscv.vclz.nxv32i16( 536346c1f26S4vtomat <vscale x 32 x i16> undef, 537346c1f26S4vtomat <vscale x 32 x i16> %0, 538346c1f26S4vtomat iXLen %1) 539346c1f26S4vtomat 540346c1f26S4vtomat ret <vscale x 32 x i16> %a 541346c1f26S4vtomat} 542346c1f26S4vtomat 543346c1f26S4vtomatdeclare <vscale x 32 x i16> @llvm.riscv.vclz.mask.nxv32i16( 544346c1f26S4vtomat <vscale x 32 x i16>, 545346c1f26S4vtomat <vscale x 32 x i16>, 546346c1f26S4vtomat <vscale x 32 x i1>, 547346c1f26S4vtomat iXLen, 548346c1f26S4vtomat iXLen); 549346c1f26S4vtomat 550346c1f26S4vtomatdefine <vscale x 32 x i16> @intrinsic_vclz_mask_vs_nxv32i16(<vscale x 32 x i1> %0, <vscale x 32 x i16> %1, <vscale x 32 x i16> %2, iXLen %3) nounwind { 551346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv32i16: 552346c1f26S4vtomat; CHECK: # %bb.0: # %entry 553346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e16, m8, ta, mu 554346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v16, v0.t 555346c1f26S4vtomat; CHECK-NEXT: ret 556346c1f26S4vtomatentry: 557346c1f26S4vtomat %a = call <vscale x 32 x i16> @llvm.riscv.vclz.mask.nxv32i16( 558346c1f26S4vtomat <vscale x 32 x i16> %1, 559346c1f26S4vtomat <vscale x 32 x i16> %2, 560346c1f26S4vtomat <vscale x 32 x i1> %0, 561346c1f26S4vtomat iXLen %3, iXLen 1) 562346c1f26S4vtomat 563346c1f26S4vtomat ret <vscale x 32 x i16> %a 564346c1f26S4vtomat} 565346c1f26S4vtomat 566346c1f26S4vtomatdeclare <vscale x 1 x i32> @llvm.riscv.vclz.nxv1i32( 567346c1f26S4vtomat <vscale x 1 x i32>, 568346c1f26S4vtomat <vscale x 1 x i32>, 569346c1f26S4vtomat iXLen); 570346c1f26S4vtomat 571346c1f26S4vtomatdefine <vscale x 1 x i32> @intrinsic_vclz_vs_nxv1i32(<vscale x 1 x i32> %0, iXLen %1) nounwind { 572346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv1i32: 573346c1f26S4vtomat; CHECK: # %bb.0: # %entry 574346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma 575346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 576346c1f26S4vtomat; CHECK-NEXT: ret 577346c1f26S4vtomatentry: 578346c1f26S4vtomat %a = call <vscale x 1 x i32> @llvm.riscv.vclz.nxv1i32( 579346c1f26S4vtomat <vscale x 1 x i32> undef, 580346c1f26S4vtomat <vscale x 1 x i32> %0, 581346c1f26S4vtomat iXLen %1) 582346c1f26S4vtomat 583346c1f26S4vtomat ret <vscale x 1 x i32> %a 584346c1f26S4vtomat} 585346c1f26S4vtomat 586346c1f26S4vtomatdeclare <vscale x 1 x i32> @llvm.riscv.vclz.mask.nxv1i32( 587346c1f26S4vtomat <vscale x 1 x i32>, 588346c1f26S4vtomat <vscale x 1 x i32>, 589346c1f26S4vtomat <vscale x 1 x i1>, 590346c1f26S4vtomat iXLen, 591346c1f26S4vtomat iXLen); 592346c1f26S4vtomat 593346c1f26S4vtomatdefine <vscale x 1 x i32> @intrinsic_vclz_mask_vs_nxv1i32(<vscale x 1 x i1> %0, <vscale x 1 x i32> %1, <vscale x 1 x i32> %2, iXLen %3) nounwind { 594346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv1i32: 595346c1f26S4vtomat; CHECK: # %bb.0: # %entry 596346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, mu 597346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 598346c1f26S4vtomat; CHECK-NEXT: ret 599346c1f26S4vtomatentry: 600346c1f26S4vtomat %a = call <vscale x 1 x i32> @llvm.riscv.vclz.mask.nxv1i32( 601346c1f26S4vtomat <vscale x 1 x i32> %1, 602346c1f26S4vtomat <vscale x 1 x i32> %2, 603346c1f26S4vtomat <vscale x 1 x i1> %0, 604346c1f26S4vtomat iXLen %3, iXLen 1) 605346c1f26S4vtomat 606346c1f26S4vtomat ret <vscale x 1 x i32> %a 607346c1f26S4vtomat} 608346c1f26S4vtomat 609346c1f26S4vtomatdeclare <vscale x 2 x i32> @llvm.riscv.vclz.nxv2i32( 610346c1f26S4vtomat <vscale x 2 x i32>, 611346c1f26S4vtomat <vscale x 2 x i32>, 612346c1f26S4vtomat iXLen); 613346c1f26S4vtomat 614346c1f26S4vtomatdefine <vscale x 2 x i32> @intrinsic_vclz_vs_nxv2i32(<vscale x 2 x i32> %0, iXLen %1) nounwind { 615346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv2i32: 616346c1f26S4vtomat; CHECK: # %bb.0: # %entry 617346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma 618346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 619346c1f26S4vtomat; CHECK-NEXT: ret 620346c1f26S4vtomatentry: 621346c1f26S4vtomat %a = call <vscale x 2 x i32> @llvm.riscv.vclz.nxv2i32( 622346c1f26S4vtomat <vscale x 2 x i32> undef, 623346c1f26S4vtomat <vscale x 2 x i32> %0, 624346c1f26S4vtomat iXLen %1) 625346c1f26S4vtomat 626346c1f26S4vtomat ret <vscale x 2 x i32> %a 627346c1f26S4vtomat} 628346c1f26S4vtomat 629346c1f26S4vtomatdeclare <vscale x 2 x i32> @llvm.riscv.vclz.mask.nxv2i32( 630346c1f26S4vtomat <vscale x 2 x i32>, 631346c1f26S4vtomat <vscale x 2 x i32>, 632346c1f26S4vtomat <vscale x 2 x i1>, 633346c1f26S4vtomat iXLen, 634346c1f26S4vtomat iXLen); 635346c1f26S4vtomat 636346c1f26S4vtomatdefine <vscale x 2 x i32> @intrinsic_vclz_mask_vs_nxv2i32(<vscale x 2 x i1> %0, <vscale x 2 x i32> %1, <vscale x 2 x i32> %2, iXLen %3) nounwind { 637346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv2i32: 638346c1f26S4vtomat; CHECK: # %bb.0: # %entry 639346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, mu 640346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 641346c1f26S4vtomat; CHECK-NEXT: ret 642346c1f26S4vtomatentry: 643346c1f26S4vtomat %a = call <vscale x 2 x i32> @llvm.riscv.vclz.mask.nxv2i32( 644346c1f26S4vtomat <vscale x 2 x i32> %1, 645346c1f26S4vtomat <vscale x 2 x i32> %2, 646346c1f26S4vtomat <vscale x 2 x i1> %0, 647346c1f26S4vtomat iXLen %3, iXLen 1) 648346c1f26S4vtomat 649346c1f26S4vtomat ret <vscale x 2 x i32> %a 650346c1f26S4vtomat} 651346c1f26S4vtomat 652346c1f26S4vtomatdeclare <vscale x 4 x i32> @llvm.riscv.vclz.nxv4i32( 653346c1f26S4vtomat <vscale x 4 x i32>, 654346c1f26S4vtomat <vscale x 4 x i32>, 655346c1f26S4vtomat iXLen); 656346c1f26S4vtomat 657346c1f26S4vtomatdefine <vscale x 4 x i32> @intrinsic_vclz_vs_nxv4i32(<vscale x 4 x i32> %0, iXLen %1) nounwind { 658346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv4i32: 659346c1f26S4vtomat; CHECK: # %bb.0: # %entry 660346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma 661346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 662346c1f26S4vtomat; CHECK-NEXT: ret 663346c1f26S4vtomatentry: 664346c1f26S4vtomat %a = call <vscale x 4 x i32> @llvm.riscv.vclz.nxv4i32( 665346c1f26S4vtomat <vscale x 4 x i32> undef, 666346c1f26S4vtomat <vscale x 4 x i32> %0, 667346c1f26S4vtomat iXLen %1) 668346c1f26S4vtomat 669346c1f26S4vtomat ret <vscale x 4 x i32> %a 670346c1f26S4vtomat} 671346c1f26S4vtomat 672346c1f26S4vtomatdeclare <vscale x 4 x i32> @llvm.riscv.vclz.mask.nxv4i32( 673346c1f26S4vtomat <vscale x 4 x i32>, 674346c1f26S4vtomat <vscale x 4 x i32>, 675346c1f26S4vtomat <vscale x 4 x i1>, 676346c1f26S4vtomat iXLen, 677346c1f26S4vtomat iXLen); 678346c1f26S4vtomat 679346c1f26S4vtomatdefine <vscale x 4 x i32> @intrinsic_vclz_mask_vs_nxv4i32(<vscale x 4 x i1> %0, <vscale x 4 x i32> %1, <vscale x 4 x i32> %2, iXLen %3) nounwind { 680346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv4i32: 681346c1f26S4vtomat; CHECK: # %bb.0: # %entry 682346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, mu 683346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v10, v0.t 684346c1f26S4vtomat; CHECK-NEXT: ret 685346c1f26S4vtomatentry: 686346c1f26S4vtomat %a = call <vscale x 4 x i32> @llvm.riscv.vclz.mask.nxv4i32( 687346c1f26S4vtomat <vscale x 4 x i32> %1, 688346c1f26S4vtomat <vscale x 4 x i32> %2, 689346c1f26S4vtomat <vscale x 4 x i1> %0, 690346c1f26S4vtomat iXLen %3, iXLen 1) 691346c1f26S4vtomat 692346c1f26S4vtomat ret <vscale x 4 x i32> %a 693346c1f26S4vtomat} 694346c1f26S4vtomat 695346c1f26S4vtomatdeclare <vscale x 8 x i32> @llvm.riscv.vclz.nxv8i32( 696346c1f26S4vtomat <vscale x 8 x i32>, 697346c1f26S4vtomat <vscale x 8 x i32>, 698346c1f26S4vtomat iXLen); 699346c1f26S4vtomat 700346c1f26S4vtomatdefine <vscale x 8 x i32> @intrinsic_vclz_vs_nxv8i32(<vscale x 8 x i32> %0, iXLen %1) nounwind { 701346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv8i32: 702346c1f26S4vtomat; CHECK: # %bb.0: # %entry 703346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma 704346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 705346c1f26S4vtomat; CHECK-NEXT: ret 706346c1f26S4vtomatentry: 707346c1f26S4vtomat %a = call <vscale x 8 x i32> @llvm.riscv.vclz.nxv8i32( 708346c1f26S4vtomat <vscale x 8 x i32> undef, 709346c1f26S4vtomat <vscale x 8 x i32> %0, 710346c1f26S4vtomat iXLen %1) 711346c1f26S4vtomat 712346c1f26S4vtomat ret <vscale x 8 x i32> %a 713346c1f26S4vtomat} 714346c1f26S4vtomat 715346c1f26S4vtomatdeclare <vscale x 8 x i32> @llvm.riscv.vclz.mask.nxv8i32( 716346c1f26S4vtomat <vscale x 8 x i32>, 717346c1f26S4vtomat <vscale x 8 x i32>, 718346c1f26S4vtomat <vscale x 8 x i1>, 719346c1f26S4vtomat iXLen, 720346c1f26S4vtomat iXLen); 721346c1f26S4vtomat 722346c1f26S4vtomatdefine <vscale x 8 x i32> @intrinsic_vclz_mask_vs_nxv8i32(<vscale x 8 x i1> %0, <vscale x 8 x i32> %1, <vscale x 8 x i32> %2, iXLen %3) nounwind { 723346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv8i32: 724346c1f26S4vtomat; CHECK: # %bb.0: # %entry 725346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, mu 726346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v12, v0.t 727346c1f26S4vtomat; CHECK-NEXT: ret 728346c1f26S4vtomatentry: 729346c1f26S4vtomat %a = call <vscale x 8 x i32> @llvm.riscv.vclz.mask.nxv8i32( 730346c1f26S4vtomat <vscale x 8 x i32> %1, 731346c1f26S4vtomat <vscale x 8 x i32> %2, 732346c1f26S4vtomat <vscale x 8 x i1> %0, 733346c1f26S4vtomat iXLen %3, iXLen 1) 734346c1f26S4vtomat 735346c1f26S4vtomat ret <vscale x 8 x i32> %a 736346c1f26S4vtomat} 737346c1f26S4vtomat 738346c1f26S4vtomatdeclare <vscale x 16 x i32> @llvm.riscv.vclz.nxv16i32( 739346c1f26S4vtomat <vscale x 16 x i32>, 740346c1f26S4vtomat <vscale x 16 x i32>, 741346c1f26S4vtomat iXLen); 742346c1f26S4vtomat 743346c1f26S4vtomatdefine <vscale x 16 x i32> @intrinsic_vclz_vs_nxv16i32(<vscale x 16 x i32> %0, iXLen %1) nounwind { 744346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv16i32: 745346c1f26S4vtomat; CHECK: # %bb.0: # %entry 746346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma 747346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 748346c1f26S4vtomat; CHECK-NEXT: ret 749346c1f26S4vtomatentry: 750346c1f26S4vtomat %a = call <vscale x 16 x i32> @llvm.riscv.vclz.nxv16i32( 751346c1f26S4vtomat <vscale x 16 x i32> undef, 752346c1f26S4vtomat <vscale x 16 x i32> %0, 753346c1f26S4vtomat iXLen %1) 754346c1f26S4vtomat 755346c1f26S4vtomat ret <vscale x 16 x i32> %a 756346c1f26S4vtomat} 757346c1f26S4vtomat 758346c1f26S4vtomatdeclare <vscale x 16 x i32> @llvm.riscv.vclz.mask.nxv16i32( 759346c1f26S4vtomat <vscale x 16 x i32>, 760346c1f26S4vtomat <vscale x 16 x i32>, 761346c1f26S4vtomat <vscale x 16 x i1>, 762346c1f26S4vtomat iXLen, 763346c1f26S4vtomat iXLen); 764346c1f26S4vtomat 765346c1f26S4vtomatdefine <vscale x 16 x i32> @intrinsic_vclz_mask_vs_nxv16i32(<vscale x 16 x i1> %0, <vscale x 16 x i32> %1, <vscale x 16 x i32> %2, iXLen %3) nounwind { 766346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv16i32: 767346c1f26S4vtomat; CHECK: # %bb.0: # %entry 768346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, mu 769346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v16, v0.t 770346c1f26S4vtomat; CHECK-NEXT: ret 771346c1f26S4vtomatentry: 772346c1f26S4vtomat %a = call <vscale x 16 x i32> @llvm.riscv.vclz.mask.nxv16i32( 773346c1f26S4vtomat <vscale x 16 x i32> %1, 774346c1f26S4vtomat <vscale x 16 x i32> %2, 775346c1f26S4vtomat <vscale x 16 x i1> %0, 776346c1f26S4vtomat iXLen %3, iXLen 1) 777346c1f26S4vtomat 778346c1f26S4vtomat ret <vscale x 16 x i32> %a 779346c1f26S4vtomat} 780346c1f26S4vtomat 781346c1f26S4vtomatdeclare <vscale x 1 x i64> @llvm.riscv.vclz.nxv1i64( 782346c1f26S4vtomat <vscale x 1 x i64>, 783346c1f26S4vtomat <vscale x 1 x i64>, 784346c1f26S4vtomat iXLen); 785346c1f26S4vtomat 786346c1f26S4vtomatdefine <vscale x 1 x i64> @intrinsic_vclz_vs_nxv1i64(<vscale x 1 x i64> %0, iXLen %1) nounwind { 787346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv1i64: 788346c1f26S4vtomat; CHECK: # %bb.0: # %entry 789346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma 790346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 791346c1f26S4vtomat; CHECK-NEXT: ret 792346c1f26S4vtomatentry: 793346c1f26S4vtomat %a = call <vscale x 1 x i64> @llvm.riscv.vclz.nxv1i64( 794346c1f26S4vtomat <vscale x 1 x i64> undef, 795346c1f26S4vtomat <vscale x 1 x i64> %0, 796346c1f26S4vtomat iXLen %1) 797346c1f26S4vtomat 798346c1f26S4vtomat ret <vscale x 1 x i64> %a 799346c1f26S4vtomat} 800346c1f26S4vtomat 801346c1f26S4vtomatdeclare <vscale x 1 x i64> @llvm.riscv.vclz.mask.nxv1i64( 802346c1f26S4vtomat <vscale x 1 x i64>, 803346c1f26S4vtomat <vscale x 1 x i64>, 804346c1f26S4vtomat <vscale x 1 x i1>, 805346c1f26S4vtomat iXLen, 806346c1f26S4vtomat iXLen); 807346c1f26S4vtomat 808346c1f26S4vtomatdefine <vscale x 1 x i64> @intrinsic_vclz_mask_vs_nxv1i64(<vscale x 1 x i1> %0, <vscale x 1 x i64> %1, <vscale x 1 x i64> %2, iXLen %3) nounwind { 809346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv1i64: 810346c1f26S4vtomat; CHECK: # %bb.0: # %entry 811346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, mu 812346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v9, v0.t 813346c1f26S4vtomat; CHECK-NEXT: ret 814346c1f26S4vtomatentry: 815346c1f26S4vtomat %a = call <vscale x 1 x i64> @llvm.riscv.vclz.mask.nxv1i64( 816346c1f26S4vtomat <vscale x 1 x i64> %1, 817346c1f26S4vtomat <vscale x 1 x i64> %2, 818346c1f26S4vtomat <vscale x 1 x i1> %0, 819346c1f26S4vtomat iXLen %3, iXLen 1) 820346c1f26S4vtomat 821346c1f26S4vtomat ret <vscale x 1 x i64> %a 822346c1f26S4vtomat} 823346c1f26S4vtomat 824346c1f26S4vtomatdeclare <vscale x 2 x i64> @llvm.riscv.vclz.nxv2i64( 825346c1f26S4vtomat <vscale x 2 x i64>, 826346c1f26S4vtomat <vscale x 2 x i64>, 827346c1f26S4vtomat iXLen); 828346c1f26S4vtomat 829346c1f26S4vtomatdefine <vscale x 2 x i64> @intrinsic_vclz_vs_nxv2i64(<vscale x 2 x i64> %0, iXLen %1) nounwind { 830346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv2i64: 831346c1f26S4vtomat; CHECK: # %bb.0: # %entry 832346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma 833346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 834346c1f26S4vtomat; CHECK-NEXT: ret 835346c1f26S4vtomatentry: 836346c1f26S4vtomat %a = call <vscale x 2 x i64> @llvm.riscv.vclz.nxv2i64( 837346c1f26S4vtomat <vscale x 2 x i64> undef, 838346c1f26S4vtomat <vscale x 2 x i64> %0, 839346c1f26S4vtomat iXLen %1) 840346c1f26S4vtomat 841346c1f26S4vtomat ret <vscale x 2 x i64> %a 842346c1f26S4vtomat} 843346c1f26S4vtomat 844346c1f26S4vtomatdeclare <vscale x 2 x i64> @llvm.riscv.vclz.mask.nxv2i64( 845346c1f26S4vtomat <vscale x 2 x i64>, 846346c1f26S4vtomat <vscale x 2 x i64>, 847346c1f26S4vtomat <vscale x 2 x i1>, 848346c1f26S4vtomat iXLen, 849346c1f26S4vtomat iXLen); 850346c1f26S4vtomat 851346c1f26S4vtomatdefine <vscale x 2 x i64> @intrinsic_vclz_mask_vs_nxv2i64(<vscale x 2 x i1> %0, <vscale x 2 x i64> %1, <vscale x 2 x i64> %2, iXLen %3) nounwind { 852346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv2i64: 853346c1f26S4vtomat; CHECK: # %bb.0: # %entry 854346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, mu 855346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v10, v0.t 856346c1f26S4vtomat; CHECK-NEXT: ret 857346c1f26S4vtomatentry: 858346c1f26S4vtomat %a = call <vscale x 2 x i64> @llvm.riscv.vclz.mask.nxv2i64( 859346c1f26S4vtomat <vscale x 2 x i64> %1, 860346c1f26S4vtomat <vscale x 2 x i64> %2, 861346c1f26S4vtomat <vscale x 2 x i1> %0, 862346c1f26S4vtomat iXLen %3, iXLen 1) 863346c1f26S4vtomat 864346c1f26S4vtomat ret <vscale x 2 x i64> %a 865346c1f26S4vtomat} 866346c1f26S4vtomat 867346c1f26S4vtomatdeclare <vscale x 4 x i64> @llvm.riscv.vclz.nxv4i64( 868346c1f26S4vtomat <vscale x 4 x i64>, 869346c1f26S4vtomat <vscale x 4 x i64>, 870346c1f26S4vtomat iXLen); 871346c1f26S4vtomat 872346c1f26S4vtomatdefine <vscale x 4 x i64> @intrinsic_vclz_vs_nxv4i64(<vscale x 4 x i64> %0, iXLen %1) nounwind { 873346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv4i64: 874346c1f26S4vtomat; CHECK: # %bb.0: # %entry 875346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma 876346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 877346c1f26S4vtomat; CHECK-NEXT: ret 878346c1f26S4vtomatentry: 879346c1f26S4vtomat %a = call <vscale x 4 x i64> @llvm.riscv.vclz.nxv4i64( 880346c1f26S4vtomat <vscale x 4 x i64> undef, 881346c1f26S4vtomat <vscale x 4 x i64> %0, 882346c1f26S4vtomat iXLen %1) 883346c1f26S4vtomat 884346c1f26S4vtomat ret <vscale x 4 x i64> %a 885346c1f26S4vtomat} 886346c1f26S4vtomat 887346c1f26S4vtomatdeclare <vscale x 4 x i64> @llvm.riscv.vclz.mask.nxv4i64( 888346c1f26S4vtomat <vscale x 4 x i64>, 889346c1f26S4vtomat <vscale x 4 x i64>, 890346c1f26S4vtomat <vscale x 4 x i1>, 891346c1f26S4vtomat iXLen, 892346c1f26S4vtomat iXLen); 893346c1f26S4vtomat 894346c1f26S4vtomatdefine <vscale x 4 x i64> @intrinsic_vclz_mask_vs_nxv4i64(<vscale x 4 x i1> %0, <vscale x 4 x i64> %1, <vscale x 4 x i64> %2, iXLen %3) nounwind { 895346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv4i64: 896346c1f26S4vtomat; CHECK: # %bb.0: # %entry 897346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, mu 898346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v12, v0.t 899346c1f26S4vtomat; CHECK-NEXT: ret 900346c1f26S4vtomatentry: 901346c1f26S4vtomat %a = call <vscale x 4 x i64> @llvm.riscv.vclz.mask.nxv4i64( 902346c1f26S4vtomat <vscale x 4 x i64> %1, 903346c1f26S4vtomat <vscale x 4 x i64> %2, 904346c1f26S4vtomat <vscale x 4 x i1> %0, 905346c1f26S4vtomat iXLen %3, iXLen 1) 906346c1f26S4vtomat 907346c1f26S4vtomat ret <vscale x 4 x i64> %a 908346c1f26S4vtomat} 909346c1f26S4vtomat 910346c1f26S4vtomatdeclare <vscale x 8 x i64> @llvm.riscv.vclz.nxv8i64( 911346c1f26S4vtomat <vscale x 8 x i64>, 912346c1f26S4vtomat <vscale x 8 x i64>, 913346c1f26S4vtomat iXLen); 914346c1f26S4vtomat 915346c1f26S4vtomatdefine <vscale x 8 x i64> @intrinsic_vclz_vs_nxv8i64(<vscale x 8 x i64> %0, iXLen %1) nounwind { 916346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_vs_nxv8i64: 917346c1f26S4vtomat; CHECK: # %bb.0: # %entry 918346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma 919346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v8 920346c1f26S4vtomat; CHECK-NEXT: ret 921346c1f26S4vtomatentry: 922346c1f26S4vtomat %a = call <vscale x 8 x i64> @llvm.riscv.vclz.nxv8i64( 923346c1f26S4vtomat <vscale x 8 x i64> undef, 924346c1f26S4vtomat <vscale x 8 x i64> %0, 925346c1f26S4vtomat iXLen %1) 926346c1f26S4vtomat 927346c1f26S4vtomat ret <vscale x 8 x i64> %a 928346c1f26S4vtomat} 929346c1f26S4vtomat 930346c1f26S4vtomatdeclare <vscale x 8 x i64> @llvm.riscv.vclz.mask.nxv8i64( 931346c1f26S4vtomat <vscale x 8 x i64>, 932346c1f26S4vtomat <vscale x 8 x i64>, 933346c1f26S4vtomat <vscale x 8 x i1>, 934346c1f26S4vtomat iXLen, 935346c1f26S4vtomat iXLen); 936346c1f26S4vtomat 937346c1f26S4vtomatdefine <vscale x 8 x i64> @intrinsic_vclz_mask_vs_nxv8i64(<vscale x 8 x i1> %0, <vscale x 8 x i64> %1, <vscale x 8 x i64> %2, iXLen %3) nounwind { 938346c1f26S4vtomat; CHECK-LABEL: intrinsic_vclz_mask_vs_nxv8i64: 939346c1f26S4vtomat; CHECK: # %bb.0: # %entry 940346c1f26S4vtomat; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, mu 941346c1f26S4vtomat; CHECK-NEXT: vclz.v v8, v16, v0.t 942346c1f26S4vtomat; CHECK-NEXT: ret 943346c1f26S4vtomatentry: 944346c1f26S4vtomat %a = call <vscale x 8 x i64> @llvm.riscv.vclz.mask.nxv8i64( 945346c1f26S4vtomat <vscale x 8 x i64> %1, 946346c1f26S4vtomat <vscale x 8 x i64> %2, 947346c1f26S4vtomat <vscale x 8 x i1> %0, 948346c1f26S4vtomat iXLen %3, iXLen 1) 949346c1f26S4vtomat 950346c1f26S4vtomat ret <vscale x 8 x i64> %a 951346c1f26S4vtomat} 952