1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py 2; RUN: opt < %s -mtriple=riscv32 -mattr=+v -riscv-v-vector-bits-min=256 -passes='print<cost-model>' -cost-kind=throughput 2>&1 -disable-output | FileCheck %s 3; RUN: opt < %s -mtriple=riscv64 -mattr=+v -riscv-v-vector-bits-min=256 -passes='print<cost-model>' -cost-kind=throughput 2>&1 -disable-output | FileCheck %s 4 5define i32 @reduce_umin_i1(i32 %arg) { 6; CHECK-LABEL: 'reduce_umin_i1' 7; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V1 = call i1 @llvm.vector.reduce.umax.v1i1(<1 x i1> undef) 8; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i1 @llvm.vector.reduce.umax.v2i1(<2 x i1> undef) 9; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V4 = call i1 @llvm.vector.reduce.umax.v4i1(<4 x i1> undef) 10; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V8 = call i1 @llvm.vector.reduce.umax.v8i1(<8 x i1> undef) 11; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V16 = call i1 @llvm.vector.reduce.umax.v16i1(<16 x i1> undef) 12; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V32 = call i1 @llvm.vector.reduce.umax.v32i1(<32 x i1> undef) 13; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V64 = call i1 @llvm.vector.reduce.umax.v64i1(<64 x i1> undef) 14; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V128 = call i1 @llvm.vector.reduce.umax.v128i1(<128 x i1> undef) 15; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 16; 17 %V1 = call i1 @llvm.vector.reduce.umax.v1i1(<1 x i1> undef) 18 %V2 = call i1 @llvm.vector.reduce.umax.v2i1(<2 x i1> undef) 19 %V4 = call i1 @llvm.vector.reduce.umax.v4i1(<4 x i1> undef) 20 %V8 = call i1 @llvm.vector.reduce.umax.v8i1(<8 x i1> undef) 21 %V16 = call i1 @llvm.vector.reduce.umax.v16i1(<16 x i1> undef) 22 %V32 = call i1 @llvm.vector.reduce.umax.v32i1(<32 x i1> undef) 23 %V64 = call i1 @llvm.vector.reduce.umax.v64i1(<64 x i1> undef) 24 %V128 = call i1 @llvm.vector.reduce.umax.v128i1(<128 x i1> undef) 25 ret i32 undef 26} 27 28define i32 @reduce_umax_i8(i32 %arg) { 29; CHECK-LABEL: 'reduce_umax_i8' 30; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i8 @llvm.vector.reduce.umax.v1i8(<1 x i8> undef) 31; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i8 @llvm.vector.reduce.umax.v2i8(<2 x i8> undef) 32; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i8 @llvm.vector.reduce.umax.v4i8(<4 x i8> undef) 33; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i8 @llvm.vector.reduce.umax.v8i8(<8 x i8> undef) 34; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i8 @llvm.vector.reduce.umax.v16i8(<16 x i8> undef) 35; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i8 @llvm.vector.reduce.umax.v32i8(<32 x i8> undef) 36; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i8 @llvm.vector.reduce.umax.v64i8(<64 x i8> undef) 37; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V128 = call i8 @llvm.vector.reduce.umax.v128i8(<128 x i8> undef) 38; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 39; 40 %V1 = call i8 @llvm.vector.reduce.umax.v1i8(<1 x i8> undef) 41 %V2 = call i8 @llvm.vector.reduce.umax.v2i8(<2 x i8> undef) 42 %V4 = call i8 @llvm.vector.reduce.umax.v4i8(<4 x i8> undef) 43 %V8 = call i8 @llvm.vector.reduce.umax.v8i8(<8 x i8> undef) 44 %V16 = call i8 @llvm.vector.reduce.umax.v16i8(<16 x i8> undef) 45 %V32 = call i8 @llvm.vector.reduce.umax.v32i8(<32 x i8> undef) 46 %V64 = call i8 @llvm.vector.reduce.umax.v64i8(<64 x i8> undef) 47 %V128 = call i8 @llvm.vector.reduce.umax.v128i8(<128 x i8> undef) 48 ret i32 undef 49} 50 51define i32 @reduce_umax_i16(i32 %arg) { 52; CHECK-LABEL: 'reduce_umax_i16' 53; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i16 @llvm.vector.reduce.umax.v1i16(<1 x i16> undef) 54; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i16 @llvm.vector.reduce.umax.v2i16(<2 x i16> undef) 55; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i16 @llvm.vector.reduce.umax.v4i16(<4 x i16> undef) 56; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i16 @llvm.vector.reduce.umax.v8i16(<8 x i16> undef) 57; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i16 @llvm.vector.reduce.umax.v16i16(<16 x i16> undef) 58; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i16 @llvm.vector.reduce.umax.v32i16(<32 x i16> undef) 59; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i16 @llvm.vector.reduce.umax.v64i16(<64 x i16> undef) 60; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V128 = call i16 @llvm.vector.reduce.umax.v128i16(<128 x i16> undef) 61; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 62; 63 %V1 = call i16 @llvm.vector.reduce.umax.v1i16(<1 x i16> undef) 64 %V2 = call i16 @llvm.vector.reduce.umax.v2i16(<2 x i16> undef) 65 %V4 = call i16 @llvm.vector.reduce.umax.v4i16(<4 x i16> undef) 66 %V8 = call i16 @llvm.vector.reduce.umax.v8i16(<8 x i16> undef) 67 %V16 = call i16 @llvm.vector.reduce.umax.v16i16(<16 x i16> undef) 68 %V32 = call i16 @llvm.vector.reduce.umax.v32i16(<32 x i16> undef) 69 %V64 = call i16 @llvm.vector.reduce.umax.v64i16(<64 x i16> undef) 70 %V128 = call i16 @llvm.vector.reduce.umax.v128i16(<128 x i16> undef) 71 ret i32 undef 72} 73 74define i32 @reduce_umax_i32(i32 %arg) { 75; CHECK-LABEL: 'reduce_umax_i32' 76; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i32 @llvm.vector.reduce.umax.v1i32(<1 x i32> undef) 77; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i32 @llvm.vector.reduce.umax.v2i32(<2 x i32> undef) 78; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i32 @llvm.vector.reduce.umax.v4i32(<4 x i32> undef) 79; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i32 @llvm.vector.reduce.umax.v8i32(<8 x i32> undef) 80; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i32 @llvm.vector.reduce.umax.v16i32(<16 x i32> undef) 81; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i32 @llvm.vector.reduce.umax.v32i32(<32 x i32> undef) 82; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i32 @llvm.vector.reduce.umax.v64i32(<64 x i32> undef) 83; CHECK-NEXT: Cost Model: Found an estimated cost of 10 for instruction: %V128 = call i32 @llvm.vector.reduce.umax.v128i32(<128 x i32> undef) 84; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 85; 86 %V1 = call i32 @llvm.vector.reduce.umax.v1i32(<1 x i32> undef) 87 %V2 = call i32 @llvm.vector.reduce.umax.v2i32(<2 x i32> undef) 88 %V4 = call i32 @llvm.vector.reduce.umax.v4i32(<4 x i32> undef) 89 %V8 = call i32 @llvm.vector.reduce.umax.v8i32(<8 x i32> undef) 90 %V16 = call i32 @llvm.vector.reduce.umax.v16i32(<16 x i32> undef) 91 %V32 = call i32 @llvm.vector.reduce.umax.v32i32(<32 x i32> undef) 92 %V64 = call i32 @llvm.vector.reduce.umax.v64i32(<64 x i32> undef) 93 %V128 = call i32 @llvm.vector.reduce.umax.v128i32(<128 x i32> undef) 94 ret i32 undef 95} 96 97define i32 @reduce_umax_i64(i32 %arg) { 98; CHECK-LABEL: 'reduce_umax_i64' 99; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i64 @llvm.vector.reduce.umax.v1i64(<1 x i64> undef) 100; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i64 @llvm.vector.reduce.umax.v2i64(<2 x i64> undef) 101; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i64 @llvm.vector.reduce.umax.v4i64(<4 x i64> undef) 102; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i64 @llvm.vector.reduce.umax.v8i64(<8 x i64> undef) 103; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i64 @llvm.vector.reduce.umax.v16i64(<16 x i64> undef) 104; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i64 @llvm.vector.reduce.umax.v32i64(<32 x i64> undef) 105; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V64 = call i64 @llvm.vector.reduce.umax.v64i64(<64 x i64> undef) 106; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %V128 = call i64 @llvm.vector.reduce.umax.v128i64(<128 x i64> undef) 107; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 108; 109 %V1 = call i64 @llvm.vector.reduce.umax.v1i64(<1 x i64> undef) 110 %V2 = call i64 @llvm.vector.reduce.umax.v2i64(<2 x i64> undef) 111 %V4 = call i64 @llvm.vector.reduce.umax.v4i64(<4 x i64> undef) 112 %V8 = call i64 @llvm.vector.reduce.umax.v8i64(<8 x i64> undef) 113 %V16 = call i64 @llvm.vector.reduce.umax.v16i64(<16 x i64> undef) 114 %V32 = call i64 @llvm.vector.reduce.umax.v32i64(<32 x i64> undef) 115 %V64 = call i64 @llvm.vector.reduce.umax.v64i64(<64 x i64> undef) 116 %V128 = call i64 @llvm.vector.reduce.umax.v128i64(<128 x i64> undef) 117 ret i32 undef 118} 119 120define i32 @reduce_smin_i1(i32 %arg) { 121; CHECK-LABEL: 'reduce_smin_i1' 122; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V1 = call i1 @llvm.vector.reduce.smax.v1i1(<1 x i1> undef) 123; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i1 @llvm.vector.reduce.smax.v2i1(<2 x i1> undef) 124; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V4 = call i1 @llvm.vector.reduce.smax.v4i1(<4 x i1> undef) 125; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V8 = call i1 @llvm.vector.reduce.smax.v8i1(<8 x i1> undef) 126; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V16 = call i1 @llvm.vector.reduce.smax.v16i1(<16 x i1> undef) 127; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V32 = call i1 @llvm.vector.reduce.smax.v32i1(<32 x i1> undef) 128; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V64 = call i1 @llvm.vector.reduce.smax.v64i1(<64 x i1> undef) 129; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V128 = call i1 @llvm.vector.reduce.smax.v128i1(<128 x i1> undef) 130; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 131; 132 %V1 = call i1 @llvm.vector.reduce.smax.v1i1(<1 x i1> undef) 133 %V2 = call i1 @llvm.vector.reduce.smax.v2i1(<2 x i1> undef) 134 %V4 = call i1 @llvm.vector.reduce.smax.v4i1(<4 x i1> undef) 135 %V8 = call i1 @llvm.vector.reduce.smax.v8i1(<8 x i1> undef) 136 %V16 = call i1 @llvm.vector.reduce.smax.v16i1(<16 x i1> undef) 137 %V32 = call i1 @llvm.vector.reduce.smax.v32i1(<32 x i1> undef) 138 %V64 = call i1 @llvm.vector.reduce.smax.v64i1(<64 x i1> undef) 139 %V128 = call i1 @llvm.vector.reduce.smax.v128i1(<128 x i1> undef) 140 ret i32 undef 141} 142 143define i32 @reduce_smax_i8(i32 %arg) { 144; CHECK-LABEL: 'reduce_smax_i8' 145; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i8 @llvm.vector.reduce.smax.v1i8(<1 x i8> undef) 146; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i8 @llvm.vector.reduce.smax.v2i8(<2 x i8> undef) 147; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i8 @llvm.vector.reduce.smax.v4i8(<4 x i8> undef) 148; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i8 @llvm.vector.reduce.smax.v8i8(<8 x i8> undef) 149; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i8 @llvm.vector.reduce.smax.v16i8(<16 x i8> undef) 150; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i8 @llvm.vector.reduce.smax.v32i8(<32 x i8> undef) 151; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i8 @llvm.vector.reduce.smax.v64i8(<64 x i8> undef) 152; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V128 = call i8 @llvm.vector.reduce.smax.v128i8(<128 x i8> undef) 153; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 154; 155 %V1 = call i8 @llvm.vector.reduce.smax.v1i8(<1 x i8> undef) 156 %V2 = call i8 @llvm.vector.reduce.smax.v2i8(<2 x i8> undef) 157 %V4 = call i8 @llvm.vector.reduce.smax.v4i8(<4 x i8> undef) 158 %V8 = call i8 @llvm.vector.reduce.smax.v8i8(<8 x i8> undef) 159 %V16 = call i8 @llvm.vector.reduce.smax.v16i8(<16 x i8> undef) 160 %V32 = call i8 @llvm.vector.reduce.smax.v32i8(<32 x i8> undef) 161 %V64 = call i8 @llvm.vector.reduce.smax.v64i8(<64 x i8> undef) 162 %V128 = call i8 @llvm.vector.reduce.smax.v128i8(<128 x i8> undef) 163 ret i32 undef 164} 165 166define i32 @reduce_smax_i16(i32 %arg) { 167; CHECK-LABEL: 'reduce_smax_i16' 168; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i16 @llvm.vector.reduce.smax.v1i16(<1 x i16> undef) 169; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i16 @llvm.vector.reduce.smax.v2i16(<2 x i16> undef) 170; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i16 @llvm.vector.reduce.smax.v4i16(<4 x i16> undef) 171; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i16 @llvm.vector.reduce.smax.v8i16(<8 x i16> undef) 172; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i16 @llvm.vector.reduce.smax.v16i16(<16 x i16> undef) 173; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i16 @llvm.vector.reduce.smax.v32i16(<32 x i16> undef) 174; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i16 @llvm.vector.reduce.smax.v64i16(<64 x i16> undef) 175; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V128 = call i16 @llvm.vector.reduce.smax.v128i16(<128 x i16> undef) 176; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 177; 178 %V1 = call i16 @llvm.vector.reduce.smax.v1i16(<1 x i16> undef) 179 %V2 = call i16 @llvm.vector.reduce.smax.v2i16(<2 x i16> undef) 180 %V4 = call i16 @llvm.vector.reduce.smax.v4i16(<4 x i16> undef) 181 %V8 = call i16 @llvm.vector.reduce.smax.v8i16(<8 x i16> undef) 182 %V16 = call i16 @llvm.vector.reduce.smax.v16i16(<16 x i16> undef) 183 %V32 = call i16 @llvm.vector.reduce.smax.v32i16(<32 x i16> undef) 184 %V64 = call i16 @llvm.vector.reduce.smax.v64i16(<64 x i16> undef) 185 %V128 = call i16 @llvm.vector.reduce.smax.v128i16(<128 x i16> undef) 186 ret i32 undef 187} 188 189define i32 @reduce_smax_i32(i32 %arg) { 190; CHECK-LABEL: 'reduce_smax_i32' 191; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i32 @llvm.vector.reduce.smax.v1i32(<1 x i32> undef) 192; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i32 @llvm.vector.reduce.smax.v2i32(<2 x i32> undef) 193; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i32 @llvm.vector.reduce.smax.v4i32(<4 x i32> undef) 194; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i32 @llvm.vector.reduce.smax.v8i32(<8 x i32> undef) 195; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i32 @llvm.vector.reduce.smax.v16i32(<16 x i32> undef) 196; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i32 @llvm.vector.reduce.smax.v32i32(<32 x i32> undef) 197; CHECK-NEXT: Cost Model: Found an estimated cost of 8 for instruction: %V64 = call i32 @llvm.vector.reduce.smax.v64i32(<64 x i32> undef) 198; CHECK-NEXT: Cost Model: Found an estimated cost of 10 for instruction: %V128 = call i32 @llvm.vector.reduce.smax.v128i32(<128 x i32> undef) 199; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 200; 201 %V1 = call i32 @llvm.vector.reduce.smax.v1i32(<1 x i32> undef) 202 %V2 = call i32 @llvm.vector.reduce.smax.v2i32(<2 x i32> undef) 203 %V4 = call i32 @llvm.vector.reduce.smax.v4i32(<4 x i32> undef) 204 %V8 = call i32 @llvm.vector.reduce.smax.v8i32(<8 x i32> undef) 205 %V16 = call i32 @llvm.vector.reduce.smax.v16i32(<16 x i32> undef) 206 %V32 = call i32 @llvm.vector.reduce.smax.v32i32(<32 x i32> undef) 207 %V64 = call i32 @llvm.vector.reduce.smax.v64i32(<64 x i32> undef) 208 %V128 = call i32 @llvm.vector.reduce.smax.v128i32(<128 x i32> undef) 209 ret i32 undef 210} 211 212define i32 @reduce_smax_i64(i32 %arg) { 213; CHECK-LABEL: 'reduce_smax_i64' 214; CHECK-NEXT: Cost Model: Found an estimated cost of 2 for instruction: %V1 = call i64 @llvm.vector.reduce.smax.v1i64(<1 x i64> undef) 215; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %V2 = call i64 @llvm.vector.reduce.smax.v2i64(<2 x i64> undef) 216; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V4 = call i64 @llvm.vector.reduce.smax.v4i64(<4 x i64> undef) 217; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %V8 = call i64 @llvm.vector.reduce.smax.v8i64(<8 x i64> undef) 218; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %V16 = call i64 @llvm.vector.reduce.smax.v16i64(<16 x i64> undef) 219; CHECK-NEXT: Cost Model: Found an estimated cost of 7 for instruction: %V32 = call i64 @llvm.vector.reduce.smax.v32i64(<32 x i64> undef) 220; CHECK-NEXT: Cost Model: Found an estimated cost of 9 for instruction: %V64 = call i64 @llvm.vector.reduce.smax.v64i64(<64 x i64> undef) 221; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %V128 = call i64 @llvm.vector.reduce.smax.v128i64(<128 x i64> undef) 222; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret i32 undef 223; 224 %V1 = call i64 @llvm.vector.reduce.smax.v1i64(<1 x i64> undef) 225 %V2 = call i64 @llvm.vector.reduce.smax.v2i64(<2 x i64> undef) 226 %V4 = call i64 @llvm.vector.reduce.smax.v4i64(<4 x i64> undef) 227 %V8 = call i64 @llvm.vector.reduce.smax.v8i64(<8 x i64> undef) 228 %V16 = call i64 @llvm.vector.reduce.smax.v16i64(<16 x i64> undef) 229 %V32 = call i64 @llvm.vector.reduce.smax.v32i64(<32 x i64> undef) 230 %V64 = call i64 @llvm.vector.reduce.smax.v64i64(<64 x i64> undef) 231 %V128 = call i64 @llvm.vector.reduce.smax.v128i64(<128 x i64> undef) 232 ret i32 undef 233} 234 235 236declare i1 @llvm.vector.reduce.umax.v1i1(<1 x i1>) 237declare i1 @llvm.vector.reduce.umax.v2i1(<2 x i1>) 238declare i1 @llvm.vector.reduce.umax.v4i1(<4 x i1>) 239declare i1 @llvm.vector.reduce.umax.v8i1(<8 x i1>) 240declare i1 @llvm.vector.reduce.umax.v16i1(<16 x i1>) 241declare i1 @llvm.vector.reduce.umax.v32i1(<32 x i1>) 242declare i1 @llvm.vector.reduce.umax.v64i1(<64 x i1>) 243declare i1 @llvm.vector.reduce.umax.v128i1(<128 x i1>) 244declare i8 @llvm.vector.reduce.umax.v1i8(<1 x i8>) 245declare i8 @llvm.vector.reduce.umax.v2i8(<2 x i8>) 246declare i8 @llvm.vector.reduce.umax.v4i8(<4 x i8>) 247declare i8 @llvm.vector.reduce.umax.v8i8(<8 x i8>) 248declare i8 @llvm.vector.reduce.umax.v16i8(<16 x i8>) 249declare i8 @llvm.vector.reduce.umax.v32i8(<32 x i8>) 250declare i8 @llvm.vector.reduce.umax.v64i8(<64 x i8>) 251declare i8 @llvm.vector.reduce.umax.v128i8(<128 x i8>) 252declare i16 @llvm.vector.reduce.umax.v1i16(<1 x i16>) 253declare i16 @llvm.vector.reduce.umax.v2i16(<2 x i16>) 254declare i16 @llvm.vector.reduce.umax.v4i16(<4 x i16>) 255declare i16 @llvm.vector.reduce.umax.v8i16(<8 x i16>) 256declare i16 @llvm.vector.reduce.umax.v16i16(<16 x i16>) 257declare i16 @llvm.vector.reduce.umax.v32i16(<32 x i16>) 258declare i16 @llvm.vector.reduce.umax.v64i16(<64 x i16>) 259declare i16 @llvm.vector.reduce.umax.v128i16(<128 x i16>) 260declare i32 @llvm.vector.reduce.umax.v1i32(<1 x i32>) 261declare i32 @llvm.vector.reduce.umax.v2i32(<2 x i32>) 262declare i32 @llvm.vector.reduce.umax.v4i32(<4 x i32>) 263declare i32 @llvm.vector.reduce.umax.v8i32(<8 x i32>) 264declare i32 @llvm.vector.reduce.umax.v16i32(<16 x i32>) 265declare i32 @llvm.vector.reduce.umax.v32i32(<32 x i32>) 266declare i32 @llvm.vector.reduce.umax.v64i32(<64 x i32>) 267declare i32 @llvm.vector.reduce.umax.v128i32(<128 x i32>) 268declare i64 @llvm.vector.reduce.umax.v1i64(<1 x i64>) 269declare i64 @llvm.vector.reduce.umax.v2i64(<2 x i64>) 270declare i64 @llvm.vector.reduce.umax.v4i64(<4 x i64>) 271declare i64 @llvm.vector.reduce.umax.v8i64(<8 x i64>) 272declare i64 @llvm.vector.reduce.umax.v16i64(<16 x i64>) 273declare i64 @llvm.vector.reduce.umax.v32i64(<32 x i64>) 274declare i64 @llvm.vector.reduce.umax.v64i64(<64 x i64>) 275declare i64 @llvm.vector.reduce.umax.v128i64(<128 x i64>) 276declare i1 @llvm.vector.reduce.smax.v1i1(<1 x i1>) 277declare i1 @llvm.vector.reduce.smax.v2i1(<2 x i1>) 278declare i1 @llvm.vector.reduce.smax.v4i1(<4 x i1>) 279declare i1 @llvm.vector.reduce.smax.v8i1(<8 x i1>) 280declare i1 @llvm.vector.reduce.smax.v16i1(<16 x i1>) 281declare i1 @llvm.vector.reduce.smax.v32i1(<32 x i1>) 282declare i1 @llvm.vector.reduce.smax.v64i1(<64 x i1>) 283declare i1 @llvm.vector.reduce.smax.v128i1(<128 x i1>) 284declare i8 @llvm.vector.reduce.smax.v1i8(<1 x i8>) 285declare i8 @llvm.vector.reduce.smax.v2i8(<2 x i8>) 286declare i8 @llvm.vector.reduce.smax.v4i8(<4 x i8>) 287declare i8 @llvm.vector.reduce.smax.v8i8(<8 x i8>) 288declare i8 @llvm.vector.reduce.smax.v16i8(<16 x i8>) 289declare i8 @llvm.vector.reduce.smax.v32i8(<32 x i8>) 290declare i8 @llvm.vector.reduce.smax.v64i8(<64 x i8>) 291declare i8 @llvm.vector.reduce.smax.v128i8(<128 x i8>) 292declare i16 @llvm.vector.reduce.smax.v1i16(<1 x i16>) 293declare i16 @llvm.vector.reduce.smax.v2i16(<2 x i16>) 294declare i16 @llvm.vector.reduce.smax.v4i16(<4 x i16>) 295declare i16 @llvm.vector.reduce.smax.v8i16(<8 x i16>) 296declare i16 @llvm.vector.reduce.smax.v16i16(<16 x i16>) 297declare i16 @llvm.vector.reduce.smax.v32i16(<32 x i16>) 298declare i16 @llvm.vector.reduce.smax.v64i16(<64 x i16>) 299declare i16 @llvm.vector.reduce.smax.v128i16(<128 x i16>) 300declare i32 @llvm.vector.reduce.smax.v1i32(<1 x i32>) 301declare i32 @llvm.vector.reduce.smax.v2i32(<2 x i32>) 302declare i32 @llvm.vector.reduce.smax.v4i32(<4 x i32>) 303declare i32 @llvm.vector.reduce.smax.v8i32(<8 x i32>) 304declare i32 @llvm.vector.reduce.smax.v16i32(<16 x i32>) 305declare i32 @llvm.vector.reduce.smax.v32i32(<32 x i32>) 306declare i32 @llvm.vector.reduce.smax.v64i32(<64 x i32>) 307declare i32 @llvm.vector.reduce.smax.v128i32(<128 x i32>) 308declare i64 @llvm.vector.reduce.smax.v1i64(<1 x i64>) 309declare i64 @llvm.vector.reduce.smax.v2i64(<2 x i64>) 310declare i64 @llvm.vector.reduce.smax.v4i64(<4 x i64>) 311declare i64 @llvm.vector.reduce.smax.v8i64(<8 x i64>) 312declare i64 @llvm.vector.reduce.smax.v16i64(<16 x i64>) 313declare i64 @llvm.vector.reduce.smax.v32i64(<32 x i64>) 314declare i64 @llvm.vector.reduce.smax.v64i64(<64 x i64>) 315declare i64 @llvm.vector.reduce.smax.v128i64(<128 x i64>) 316