; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py UTC_ARGS: --version 6 ; RUN: opt -passes="print" -cost-kind=all 2>&1 -disable-output -mtriple=riscv64 -mattr=+v < %s | FileCheck %s ; RUN: opt -passes="print" -cost-kind=all 2>&1 -disable-output -mtriple=riscv64 -mattr=+v -intrinsic-cost-strategy=type-based-intrinsic-cost < %s | FileCheck %s define void @udiv() { ; CHECK-LABEL: 'udiv' ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I16 = call <1 x i16> @llvm.masked.udiv.v1i16(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I16 = call <2 x i16> @llvm.masked.udiv.v2i16(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I16 = call <4 x i16> @llvm.masked.udiv.v4i16(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V8I16 = call <8 x i16> @llvm.masked.udiv.v8i16(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.masked.udiv.v16i16(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V32I16 = call <32 x i16> @llvm.masked.udiv.v32i16(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I16 = call @llvm.masked.udiv.nxv1i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I16 = call @llvm.masked.udiv.nxv2i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV4I16 = call @llvm.masked.udiv.nxv4i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I16 = call @llvm.masked.udiv.nxv8i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I16 = call @llvm.masked.udiv.nxv16i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV32I16 = call @llvm.masked.udiv.nxv32i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I32 = call <1 x i32> @llvm.masked.udiv.v1i32(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I32 = call <2 x i32> @llvm.masked.udiv.v2i32(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I32 = call <4 x i32> @llvm.masked.udiv.v4i32(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.masked.udiv.v8i32(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V16I32 = call <16 x i32> @llvm.masked.udiv.v16i32(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I32 = call @llvm.masked.udiv.nxv1i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I32 = call @llvm.masked.udiv.nxv2i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I32 = call @llvm.masked.udiv.nxv4i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I32 = call @llvm.masked.udiv.nxv8i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I32 = call @llvm.masked.udiv.nxv16i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I64 = call <1 x i64> @llvm.masked.udiv.v1i64(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I64 = call <2 x i64> @llvm.masked.udiv.v2i64(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V4I64 = call <4 x i64> @llvm.masked.udiv.v4i64(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V8I64 = call <8 x i64> @llvm.masked.udiv.v8i64(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I64 = call @llvm.masked.udiv.nxv1i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV2I64 = call @llvm.masked.udiv.nxv2i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I64 = call @llvm.masked.udiv.nxv4i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I64 = call @llvm.masked.udiv.nxv8i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret void ; %V1I16 = call <1 x i16> @llvm.masked.udiv(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) %V2I16 = call <2 x i16> @llvm.masked.udiv(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) %V4I16 = call <4 x i16> @llvm.masked.udiv(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) %V8I16 = call <8 x i16> @llvm.masked.udiv(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) %V16I16 = call <16 x i16> @llvm.masked.udiv(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) %V32I16 = call <32 x i16> @llvm.masked.udiv(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) %NXV1I16 = call @llvm.masked.udiv( poison, poison, poison) %NXV2I16 = call @llvm.masked.udiv( poison, poison, poison) %NXV4I16 = call @llvm.masked.udiv( poison, poison, poison) %NXV8I16 = call @llvm.masked.udiv( poison, poison, poison) %NXV16I16 = call @llvm.masked.udiv( poison, poison, poison) %NXV32I16 = call @llvm.masked.udiv( poison, poison, poison) %V1I32 = call <1 x i32> @llvm.masked.udiv(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) %V2I32 = call <2 x i32> @llvm.masked.udiv(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) %V4I32 = call <4 x i32> @llvm.masked.udiv(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) %V8I32 = call <8 x i32> @llvm.masked.udiv(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) %V16I32 = call <16 x i32> @llvm.masked.udiv(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) %NXV1I32 = call @llvm.masked.udiv( poison, poison, poison) %NXV2I32 = call @llvm.masked.udiv( poison, poison, poison) %NXV4I32 = call @llvm.masked.udiv( poison, poison, poison) %NXV8I32 = call @llvm.masked.udiv( poison, poison, poison) %NXV16I32 = call @llvm.masked.udiv( poison, poison, poison) %V1I64 = call <1 x i64> @llvm.masked.udiv(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) %V2I64 = call <2 x i64> @llvm.masked.udiv(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) %V4I64 = call <4 x i64> @llvm.masked.udiv(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) %V8I64 = call <8 x i64> @llvm.masked.udiv(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) %NXV1I64 = call @llvm.masked.udiv( poison, poison, poison) %NXV2I64 = call @llvm.masked.udiv( poison, poison, poison) %NXV4I64 = call @llvm.masked.udiv( poison, poison, poison) %NXV8I64 = call @llvm.masked.udiv( poison, poison, poison) ret void } define void @sdiv() { ; CHECK-LABEL: 'sdiv' ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I16 = call <1 x i16> @llvm.masked.sdiv.v1i16(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I16 = call <2 x i16> @llvm.masked.sdiv.v2i16(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I16 = call <4 x i16> @llvm.masked.sdiv.v4i16(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V8I16 = call <8 x i16> @llvm.masked.sdiv.v8i16(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.masked.sdiv.v16i16(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V32I16 = call <32 x i16> @llvm.masked.sdiv.v32i16(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I16 = call @llvm.masked.sdiv.nxv1i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I16 = call @llvm.masked.sdiv.nxv2i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV4I16 = call @llvm.masked.sdiv.nxv4i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I16 = call @llvm.masked.sdiv.nxv8i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I16 = call @llvm.masked.sdiv.nxv16i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV32I16 = call @llvm.masked.sdiv.nxv32i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I32 = call <1 x i32> @llvm.masked.sdiv.v1i32(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I32 = call <2 x i32> @llvm.masked.sdiv.v2i32(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I32 = call <4 x i32> @llvm.masked.sdiv.v4i32(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.masked.sdiv.v8i32(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V16I32 = call <16 x i32> @llvm.masked.sdiv.v16i32(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I32 = call @llvm.masked.sdiv.nxv1i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I32 = call @llvm.masked.sdiv.nxv2i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I32 = call @llvm.masked.sdiv.nxv4i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I32 = call @llvm.masked.sdiv.nxv8i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I32 = call @llvm.masked.sdiv.nxv16i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I64 = call <1 x i64> @llvm.masked.sdiv.v1i64(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I64 = call <2 x i64> @llvm.masked.sdiv.v2i64(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V4I64 = call <4 x i64> @llvm.masked.sdiv.v4i64(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V8I64 = call <8 x i64> @llvm.masked.sdiv.v8i64(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I64 = call @llvm.masked.sdiv.nxv1i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV2I64 = call @llvm.masked.sdiv.nxv2i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I64 = call @llvm.masked.sdiv.nxv4i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I64 = call @llvm.masked.sdiv.nxv8i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret void ; %V1I16 = call <1 x i16> @llvm.masked.sdiv(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) %V2I16 = call <2 x i16> @llvm.masked.sdiv(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) %V4I16 = call <4 x i16> @llvm.masked.sdiv(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) %V8I16 = call <8 x i16> @llvm.masked.sdiv(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) %V16I16 = call <16 x i16> @llvm.masked.sdiv(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) %V32I16 = call <32 x i16> @llvm.masked.sdiv(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) %NXV1I16 = call @llvm.masked.sdiv( poison, poison, poison) %NXV2I16 = call @llvm.masked.sdiv( poison, poison, poison) %NXV4I16 = call @llvm.masked.sdiv( poison, poison, poison) %NXV8I16 = call @llvm.masked.sdiv( poison, poison, poison) %NXV16I16 = call @llvm.masked.sdiv( poison, poison, poison) %NXV32I16 = call @llvm.masked.sdiv( poison, poison, poison) %V1I32 = call <1 x i32> @llvm.masked.sdiv(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) %V2I32 = call <2 x i32> @llvm.masked.sdiv(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) %V4I32 = call <4 x i32> @llvm.masked.sdiv(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) %V8I32 = call <8 x i32> @llvm.masked.sdiv(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) %V16I32 = call <16 x i32> @llvm.masked.sdiv(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) %NXV1I32 = call @llvm.masked.sdiv( poison, poison, poison) %NXV2I32 = call @llvm.masked.sdiv( poison, poison, poison) %NXV4I32 = call @llvm.masked.sdiv( poison, poison, poison) %NXV8I32 = call @llvm.masked.sdiv( poison, poison, poison) %NXV16I32 = call @llvm.masked.sdiv( poison, poison, poison) %V1I64 = call <1 x i64> @llvm.masked.sdiv(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) %V2I64 = call <2 x i64> @llvm.masked.sdiv(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) %V4I64 = call <4 x i64> @llvm.masked.sdiv(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) %V8I64 = call <8 x i64> @llvm.masked.sdiv(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) %NXV1I64 = call @llvm.masked.sdiv( poison, poison, poison) %NXV2I64 = call @llvm.masked.sdiv( poison, poison, poison) %NXV4I64 = call @llvm.masked.sdiv( poison, poison, poison) %NXV8I64 = call @llvm.masked.sdiv( poison, poison, poison) ret void } define void @urem() { ; CHECK-LABEL: 'urem' ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I16 = call <1 x i16> @llvm.masked.urem.v1i16(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I16 = call <2 x i16> @llvm.masked.urem.v2i16(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I16 = call <4 x i16> @llvm.masked.urem.v4i16(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V8I16 = call <8 x i16> @llvm.masked.urem.v8i16(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.masked.urem.v16i16(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V32I16 = call <32 x i16> @llvm.masked.urem.v32i16(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I16 = call @llvm.masked.urem.nxv1i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I16 = call @llvm.masked.urem.nxv2i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV4I16 = call @llvm.masked.urem.nxv4i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I16 = call @llvm.masked.urem.nxv8i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I16 = call @llvm.masked.urem.nxv16i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV32I16 = call @llvm.masked.urem.nxv32i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I32 = call <1 x i32> @llvm.masked.urem.v1i32(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I32 = call <2 x i32> @llvm.masked.urem.v2i32(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I32 = call <4 x i32> @llvm.masked.urem.v4i32(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.masked.urem.v8i32(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V16I32 = call <16 x i32> @llvm.masked.urem.v16i32(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I32 = call @llvm.masked.urem.nxv1i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I32 = call @llvm.masked.urem.nxv2i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I32 = call @llvm.masked.urem.nxv4i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I32 = call @llvm.masked.urem.nxv8i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I32 = call @llvm.masked.urem.nxv16i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I64 = call <1 x i64> @llvm.masked.urem.v1i64(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I64 = call <2 x i64> @llvm.masked.urem.v2i64(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V4I64 = call <4 x i64> @llvm.masked.urem.v4i64(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V8I64 = call <8 x i64> @llvm.masked.urem.v8i64(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I64 = call @llvm.masked.urem.nxv1i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV2I64 = call @llvm.masked.urem.nxv2i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I64 = call @llvm.masked.urem.nxv4i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I64 = call @llvm.masked.urem.nxv8i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret void ; %V1I16 = call <1 x i16> @llvm.masked.urem(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) %V2I16 = call <2 x i16> @llvm.masked.urem(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) %V4I16 = call <4 x i16> @llvm.masked.urem(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) %V8I16 = call <8 x i16> @llvm.masked.urem(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) %V16I16 = call <16 x i16> @llvm.masked.urem(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) %V32I16 = call <32 x i16> @llvm.masked.urem(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) %NXV1I16 = call @llvm.masked.urem( poison, poison, poison) %NXV2I16 = call @llvm.masked.urem( poison, poison, poison) %NXV4I16 = call @llvm.masked.urem( poison, poison, poison) %NXV8I16 = call @llvm.masked.urem( poison, poison, poison) %NXV16I16 = call @llvm.masked.urem( poison, poison, poison) %NXV32I16 = call @llvm.masked.urem( poison, poison, poison) %V1I32 = call <1 x i32> @llvm.masked.urem(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) %V2I32 = call <2 x i32> @llvm.masked.urem(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) %V4I32 = call <4 x i32> @llvm.masked.urem(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) %V8I32 = call <8 x i32> @llvm.masked.urem(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) %V16I32 = call <16 x i32> @llvm.masked.urem(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) %NXV1I32 = call @llvm.masked.urem( poison, poison, poison) %NXV2I32 = call @llvm.masked.urem( poison, poison, poison) %NXV4I32 = call @llvm.masked.urem( poison, poison, poison) %NXV8I32 = call @llvm.masked.urem( poison, poison, poison) %NXV16I32 = call @llvm.masked.urem( poison, poison, poison) %V1I64 = call <1 x i64> @llvm.masked.urem(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) %V2I64 = call <2 x i64> @llvm.masked.urem(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) %V4I64 = call <4 x i64> @llvm.masked.urem(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) %V8I64 = call <8 x i64> @llvm.masked.urem(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) %NXV1I64 = call @llvm.masked.urem( poison, poison, poison) %NXV2I64 = call @llvm.masked.urem( poison, poison, poison) %NXV4I64 = call @llvm.masked.urem( poison, poison, poison) %NXV8I64 = call @llvm.masked.urem( poison, poison, poison) ret void } define void @srem() { ; CHECK-LABEL: 'srem' ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I16 = call <1 x i16> @llvm.masked.srem.v1i16(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I16 = call <2 x i16> @llvm.masked.srem.v2i16(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I16 = call <4 x i16> @llvm.masked.srem.v4i16(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V8I16 = call <8 x i16> @llvm.masked.srem.v8i16(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.masked.srem.v16i16(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V32I16 = call <32 x i16> @llvm.masked.srem.v32i16(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I16 = call @llvm.masked.srem.nxv1i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I16 = call @llvm.masked.srem.nxv2i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV4I16 = call @llvm.masked.srem.nxv4i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I16 = call @llvm.masked.srem.nxv8i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I16 = call @llvm.masked.srem.nxv16i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV32I16 = call @llvm.masked.srem.nxv32i16( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I32 = call <1 x i32> @llvm.masked.srem.v1i32(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I32 = call <2 x i32> @llvm.masked.srem.v2i32(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V4I32 = call <4 x i32> @llvm.masked.srem.v4i32(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.masked.srem.v8i32(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V16I32 = call <16 x i32> @llvm.masked.srem.v16i32(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I32 = call @llvm.masked.srem.nxv1i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV2I32 = call @llvm.masked.srem.nxv2i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I32 = call @llvm.masked.srem.nxv4i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I32 = call @llvm.masked.srem.nxv8i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV16I32 = call @llvm.masked.srem.nxv16i32( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V1I64 = call <1 x i64> @llvm.masked.srem.v1i64(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %V2I64 = call <2 x i64> @llvm.masked.srem.v2i64(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %V4I64 = call <4 x i64> @llvm.masked.srem.v4i64(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %V8I64 = call <8 x i64> @llvm.masked.srem.v8i64(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) ; CHECK-NEXT: Cost Model: Found costs of 4 for: %NXV1I64 = call @llvm.masked.srem.nxv1i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:4 SizeLat:4 for: %NXV2I64 = call @llvm.masked.srem.nxv2i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:16 CodeSize:4 Lat:4 SizeLat:4 for: %NXV4I64 = call @llvm.masked.srem.nxv4i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:32 CodeSize:4 Lat:4 SizeLat:4 for: %NXV8I64 = call @llvm.masked.srem.nxv8i64( poison, poison, poison) ; CHECK-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret void ; %V1I16 = call <1 x i16> @llvm.masked.srem(<1 x i16> poison, <1 x i16> poison, <1 x i1> poison) %V2I16 = call <2 x i16> @llvm.masked.srem(<2 x i16> poison, <2 x i16> poison, <2 x i1> poison) %V4I16 = call <4 x i16> @llvm.masked.srem(<4 x i16> poison, <4 x i16> poison, <4 x i1> poison) %V8I16 = call <8 x i16> @llvm.masked.srem(<8 x i16> poison, <8 x i16> poison, <8 x i1> poison) %V16I16 = call <16 x i16> @llvm.masked.srem(<16 x i16> poison, <16 x i16> poison, <16 x i1> poison) %V32I16 = call <32 x i16> @llvm.masked.srem(<32 x i16> poison, <32 x i16> poison, <32 x i1> poison) %NXV1I16 = call @llvm.masked.srem( poison, poison, poison) %NXV2I16 = call @llvm.masked.srem( poison, poison, poison) %NXV4I16 = call @llvm.masked.srem( poison, poison, poison) %NXV8I16 = call @llvm.masked.srem( poison, poison, poison) %NXV16I16 = call @llvm.masked.srem( poison, poison, poison) %NXV32I16 = call @llvm.masked.srem( poison, poison, poison) %V1I32 = call <1 x i32> @llvm.masked.srem(<1 x i32> poison, <1 x i32> poison, <1 x i1> poison) %V2I32 = call <2 x i32> @llvm.masked.srem(<2 x i32> poison, <2 x i32> poison, <2 x i1> poison) %V4I32 = call <4 x i32> @llvm.masked.srem(<4 x i32> poison, <4 x i32> poison, <4 x i1> poison) %V8I32 = call <8 x i32> @llvm.masked.srem(<8 x i32> poison, <8 x i32> poison, <8 x i1> poison) %V16I32 = call <16 x i32> @llvm.masked.srem(<16 x i32> poison, <16 x i32> poison, <16 x i1> poison) %NXV1I32 = call @llvm.masked.srem( poison, poison, poison) %NXV2I32 = call @llvm.masked.srem( poison, poison, poison) %NXV4I32 = call @llvm.masked.srem( poison, poison, poison) %NXV8I32 = call @llvm.masked.srem( poison, poison, poison) %NXV16I32 = call @llvm.masked.srem( poison, poison, poison) %V1I64 = call <1 x i64> @llvm.masked.srem(<1 x i64> poison, <1 x i64> poison, <1 x i1> poison) %V2I64 = call <2 x i64> @llvm.masked.srem(<2 x i64> poison, <2 x i64> poison, <2 x i1> poison) %V4I64 = call <4 x i64> @llvm.masked.srem(<4 x i64> poison, <4 x i64> poison, <4 x i1> poison) %V8I64 = call <8 x i64> @llvm.masked.srem(<8 x i64> poison, <8 x i64> poison, <8 x i1> poison) %NXV1I64 = call @llvm.masked.srem( poison, poison, poison) %NXV2I64 = call @llvm.masked.srem( poison, poison, poison) %NXV4I64 = call @llvm.masked.srem( poison, poison, poison) %NXV8I64 = call @llvm.masked.srem( poison, poison, poison) ret void }