brintos

brintos / llvm-project-archived public Read only

0
0
Text · 53.6 KiB · 6f631b2 Raw
913 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py2; RUN: opt < %s -mtriple=riscv32 -mattr=+d,+zfh,+zvfh,+v -passes="print<cost-model>" -cost-kind=throughput 2>&1 -disable-output | FileCheck %s3; RUN: opt < %s -mtriple=riscv64 -mattr=+d,+zfh,+zvfh,+v -passes="print<cost-model>" -cost-kind=throughput 2>&1 -disable-output | FileCheck %s4; RUN: opt < %s -mtriple=riscv32 -mattr=+d,+zfh,+zvfh,+v -passes="print<cost-model>" -cost-kind=code-size 2>&1 -disable-output | FileCheck %s --check-prefix=SIZE5; RUN: opt < %s -mtriple=riscv64 -mattr=+d,+zfh,+zvfh,+v -passes="print<cost-model>" -cost-kind=code-size 2>&1 -disable-output | FileCheck %s --check-prefix=SIZE6 7define half @vreduce_fadd_nxv1f16(<vscale x 1 x half> %v, half %s) {8; CHECK-LABEL: 'vreduce_fadd_nxv1f16'9; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)10; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red11;12; SIZE-LABEL: 'vreduce_fadd_nxv1f16'13; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)14; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red15;16  %red = call reassoc half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)17  ret half %red18}19 20define half @vreduce_ord_fadd_nxv1f16(<vscale x 1 x half> %v, half %s) {21; CHECK-LABEL: 'vreduce_ord_fadd_nxv1f16'22; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)23; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red24;25; SIZE-LABEL: 'vreduce_ord_fadd_nxv1f16'26; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)27; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red28;29  %red = call half @llvm.vector.reduce.fadd.nxv1f16(half %s, <vscale x 1 x half> %v)30  ret half %red31}32 33define half @vreduce_fadd_nxv2f16(<vscale x 2 x half> %v, half %s) {34; CHECK-LABEL: 'vreduce_fadd_nxv2f16'35; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)36; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red37;38; SIZE-LABEL: 'vreduce_fadd_nxv2f16'39; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)40; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red41;42  %red = call reassoc half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)43  ret half %red44}45 46define half @vreduce_ord_fadd_nxv2f16(<vscale x 2 x half> %v, half %s) {47; CHECK-LABEL: 'vreduce_ord_fadd_nxv2f16'48; CHECK-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)49; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red50;51; SIZE-LABEL: 'vreduce_ord_fadd_nxv2f16'52; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)53; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red54;55  %red = call half @llvm.vector.reduce.fadd.nxv2f16(half %s, <vscale x 2 x half> %v)56  ret half %red57}58 59define half @vreduce_fadd_nxv4f16(<vscale x 4 x half> %v, half %s) {60; CHECK-LABEL: 'vreduce_fadd_nxv4f16'61; CHECK-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)62; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red63;64; SIZE-LABEL: 'vreduce_fadd_nxv4f16'65; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)66; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red67;68  %red = call reassoc half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)69  ret half %red70}71 72define half @vreduce_ord_fadd_nxv4f16(<vscale x 4 x half> %v, half %s) {73; CHECK-LABEL: 'vreduce_ord_fadd_nxv4f16'74; CHECK-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)75; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red76;77; SIZE-LABEL: 'vreduce_ord_fadd_nxv4f16'78; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)79; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red80;81  %red = call half @llvm.vector.reduce.fadd.nxv4f16(half %s, <vscale x 4 x half> %v)82  ret half %red83}84 85define float @vreduce_fadd_nxv1f32(<vscale x 1 x float> %v, float %s) {86; CHECK-LABEL: 'vreduce_fadd_nxv1f32'87; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)88; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red89;90; SIZE-LABEL: 'vreduce_fadd_nxv1f32'91; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)92; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red93;94  %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)95  ret float %red96}97 98define float @vreduce_ord_fadd_nxv1f32(<vscale x 1 x float> %v, float %s) {99; CHECK-LABEL: 'vreduce_ord_fadd_nxv1f32'100; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)101; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red102;103; SIZE-LABEL: 'vreduce_ord_fadd_nxv1f32'104; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)105; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red106;107  %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)108  ret float %red109}110 111define float @vreduce_fwadd_nxv1f32(<vscale x 1 x half> %v, float %s) {112; CHECK-LABEL: 'vreduce_fwadd_nxv1f32'113; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>114; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)115; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red116;117; SIZE-LABEL: 'vreduce_fwadd_nxv1f32'118; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>119; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)120; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red121;122  %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>123  %red = call reassoc float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)124  ret float %red125}126 127define float @vreduce_ord_fwadd_nxv1f32(<vscale x 1 x half> %v, float %s) {128; CHECK-LABEL: 'vreduce_ord_fwadd_nxv1f32'129; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>130; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)131; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red132;133; SIZE-LABEL: 'vreduce_ord_fwadd_nxv1f32'134; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>135; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)136; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red137;138  %e = fpext <vscale x 1 x half> %v to <vscale x 1 x float>139  %red = call float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %e)140  ret float %red141}142 143define float @vreduce_fadd_nxv2f32(<vscale x 2 x float> %v, float %s) {144; CHECK-LABEL: 'vreduce_fadd_nxv2f32'145; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)146; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red147;148; SIZE-LABEL: 'vreduce_fadd_nxv2f32'149; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)150; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red151;152  %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)153  ret float %red154}155 156define float @vreduce_ord_fadd_nxv2f32(<vscale x 2 x float> %v, float %s) {157; CHECK-LABEL: 'vreduce_ord_fadd_nxv2f32'158; CHECK-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)159; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red160;161; SIZE-LABEL: 'vreduce_ord_fadd_nxv2f32'162; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)163; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red164;165  %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %v)166  ret float %red167}168 169define float @vreduce_fwadd_nxv2f32(<vscale x 2 x half> %v, float %s) {170; CHECK-LABEL: 'vreduce_fwadd_nxv2f32'171; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>172; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)173; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red174;175; SIZE-LABEL: 'vreduce_fwadd_nxv2f32'176; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>177; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)178; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red179;180  %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>181  %red = call reassoc float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)182  ret float %red183}184 185define float @vreduce_ord_fwadd_nxv2f32(<vscale x 2 x half> %v, float %s) {186; CHECK-LABEL: 'vreduce_ord_fwadd_nxv2f32'187; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>188; CHECK-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)189; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red190;191; SIZE-LABEL: 'vreduce_ord_fwadd_nxv2f32'192; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>193; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)194; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red195;196  %e = fpext <vscale x 2 x half> %v to <vscale x 2 x float>197  %red = call float @llvm.vector.reduce.fadd.nxv2f32(float %s, <vscale x 2 x float> %e)198  ret float %red199}200 201define float @vreduce_fadd_nxv4f32(<vscale x 4 x float> %v, float %s) {202; CHECK-LABEL: 'vreduce_fadd_nxv4f32'203; CHECK-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)204; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red205;206; SIZE-LABEL: 'vreduce_fadd_nxv4f32'207; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)208; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red209;210  %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)211  ret float %red212}213 214define float @vreduce_ord_fadd_nxv4f32(<vscale x 4 x float> %v, float %s) {215; CHECK-LABEL: 'vreduce_ord_fadd_nxv4f32'216; CHECK-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)217; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red218;219; SIZE-LABEL: 'vreduce_ord_fadd_nxv4f32'220; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)221; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red222;223  %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %v)224  ret float %red225}226 227define float @vreduce_fwadd_nxv4f32(<vscale x 4 x half> %v, float %s) {228; CHECK-LABEL: 'vreduce_fwadd_nxv4f32'229; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>230; CHECK-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)231; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red232;233; SIZE-LABEL: 'vreduce_fwadd_nxv4f32'234; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>235; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)236; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red237;238  %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>239  %red = call reassoc float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)240  ret float %red241}242 243define float @vreduce_ord_fwadd_nxv4f32(<vscale x 4 x half> %v, float %s) {244; CHECK-LABEL: 'vreduce_ord_fwadd_nxv4f32'245; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>246; CHECK-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)247; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red248;249; SIZE-LABEL: 'vreduce_ord_fwadd_nxv4f32'250; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>251; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)252; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red253;254  %e = fpext <vscale x 4 x half> %v to <vscale x 4 x float>255  %red = call float @llvm.vector.reduce.fadd.nxv4f32(float %s, <vscale x 4 x float> %e)256  ret float %red257}258 259define double @vreduce_fadd_nxv1f64(<vscale x 1 x double> %v, double %s) {260; CHECK-LABEL: 'vreduce_fadd_nxv1f64'261; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)262; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red263;264; SIZE-LABEL: 'vreduce_fadd_nxv1f64'265; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)266; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red267;268  %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)269  ret double %red270}271 272define double @vreduce_ord_fadd_nxv1f64(<vscale x 1 x double> %v, double %s) {273; CHECK-LABEL: 'vreduce_ord_fadd_nxv1f64'274; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)275; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red276;277; SIZE-LABEL: 'vreduce_ord_fadd_nxv1f64'278; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)279; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red280;281  %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %v)282  ret double %red283}284 285define double @vreduce_fwadd_nxv1f64(<vscale x 1 x float> %v, double %s) {286; CHECK-LABEL: 'vreduce_fwadd_nxv1f64'287; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>288; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)289; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red290;291; SIZE-LABEL: 'vreduce_fwadd_nxv1f64'292; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>293; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)294; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red295;296  %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>297  %red = call reassoc double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)298  ret double %red299}300 301define double @vreduce_ord_fwadd_nxv1f64(<vscale x 1 x float> %v, double %s) {302; CHECK-LABEL: 'vreduce_ord_fwadd_nxv1f64'303; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>304; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)305; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red306;307; SIZE-LABEL: 'vreduce_ord_fwadd_nxv1f64'308; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>309; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)310; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red311;312  %e = fpext <vscale x 1 x float> %v to <vscale x 1 x double>313  %red = call double @llvm.vector.reduce.fadd.nxv1f64(double %s, <vscale x 1 x double> %e)314  ret double %red315}316 317define double @vreduce_fadd_nxv2f64(<vscale x 2 x double> %v, double %s) {318; CHECK-LABEL: 'vreduce_fadd_nxv2f64'319; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)320; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red321;322; SIZE-LABEL: 'vreduce_fadd_nxv2f64'323; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)324; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red325;326  %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)327  ret double %red328}329 330define double @vreduce_ord_fadd_nxv2f64(<vscale x 2 x double> %v, double %s) {331; CHECK-LABEL: 'vreduce_ord_fadd_nxv2f64'332; CHECK-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)333; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red334;335; SIZE-LABEL: 'vreduce_ord_fadd_nxv2f64'336; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)337; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red338;339  %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %v)340  ret double %red341}342 343define double @vreduce_fwadd_nxv2f64(<vscale x 2 x float> %v, double %s) {344; CHECK-LABEL: 'vreduce_fwadd_nxv2f64'345; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>346; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)347; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red348;349; SIZE-LABEL: 'vreduce_fwadd_nxv2f64'350; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>351; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)352; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red353;354  %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>355  %red = call reassoc double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)356  ret double %red357}358 359define double @vreduce_ord_fwadd_nxv2f64(<vscale x 2 x float> %v, double %s) {360; CHECK-LABEL: 'vreduce_ord_fwadd_nxv2f64'361; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>362; CHECK-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)363; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red364;365; SIZE-LABEL: 'vreduce_ord_fwadd_nxv2f64'366; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>367; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)368; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red369;370  %e = fpext <vscale x 2 x float> %v to <vscale x 2 x double>371  %red = call double @llvm.vector.reduce.fadd.nxv2f64(double %s, <vscale x 2 x double> %e)372  ret double %red373}374 375define double @vreduce_fadd_nxv4f64(<vscale x 4 x double> %v, double %s) {376; CHECK-LABEL: 'vreduce_fadd_nxv4f64'377; CHECK-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)378; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red379;380; SIZE-LABEL: 'vreduce_fadd_nxv4f64'381; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)382; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red383;384  %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)385  ret double %red386}387 388define double @vreduce_ord_fadd_nxv4f64(<vscale x 4 x double> %v, double %s) {389; CHECK-LABEL: 'vreduce_ord_fadd_nxv4f64'390; CHECK-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)391; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red392;393; SIZE-LABEL: 'vreduce_ord_fadd_nxv4f64'394; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)395; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red396;397  %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %v)398  ret double %red399}400 401define double @vreduce_fwadd_nxv4f64(<vscale x 4 x float> %v, double %s) {402; CHECK-LABEL: 'vreduce_fwadd_nxv4f64'403; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>404; CHECK-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)405; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red406;407; SIZE-LABEL: 'vreduce_fwadd_nxv4f64'408; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>409; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)410; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red411;412  %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>413  %red = call reassoc double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)414  ret double %red415}416 417define double @vreduce_ord_fwadd_nxv4f64(<vscale x 4 x float> %v, double %s) {418; CHECK-LABEL: 'vreduce_ord_fwadd_nxv4f64'419; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>420; CHECK-NEXT:  Cost Model: Found an estimated cost of 10 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)421; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red422;423; SIZE-LABEL: 'vreduce_ord_fwadd_nxv4f64'424; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>425; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)426; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red427;428  %e = fpext <vscale x 4 x float> %v to <vscale x 4 x double>429  %red = call double @llvm.vector.reduce.fadd.nxv4f64(double %s, <vscale x 4 x double> %e)430  ret double %red431}432 433define half @vreduce_fmin_nxv1f16(<vscale x 1 x half> %v) {434; CHECK-LABEL: 'vreduce_fmin_nxv1f16'435; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)436; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red437;438; SIZE-LABEL: 'vreduce_fmin_nxv1f16'439; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)440; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red441;442  %red = call half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)443  ret half %red444}445 446define half @vreduce_fmin_nxv1f16_nonans(<vscale x 1 x half> %v) {447; CHECK-LABEL: 'vreduce_fmin_nxv1f16_nonans'448; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)449; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red450;451; SIZE-LABEL: 'vreduce_fmin_nxv1f16_nonans'452; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)453; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red454;455  %red = call nnan half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)456  ret half %red457}458 459define half @vreduce_fmin_nxv1f16_nonans_noinfs(<vscale x 1 x half> %v) #1 {460; CHECK-LABEL: 'vreduce_fmin_nxv1f16_nonans_noinfs'461; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)462; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red463;464; SIZE-LABEL: 'vreduce_fmin_nxv1f16_nonans_noinfs'465; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)466; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red467;468  %red = call nnan ninf half @llvm.vector.reduce.fmin.nxv1f16(<vscale x 1 x half> %v)469  ret half %red470}471 472define half @vreduce_fmin_nxv2f16(<vscale x 2 x half> %v) {473; CHECK-LABEL: 'vreduce_fmin_nxv2f16'474; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv2f16(<vscale x 2 x half> %v)475; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red476;477; SIZE-LABEL: 'vreduce_fmin_nxv2f16'478; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv2f16(<vscale x 2 x half> %v)479; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red480;481  %red = call half @llvm.vector.reduce.fmin.nxv2f16(<vscale x 2 x half> %v)482  ret half %red483}484 485define half @vreduce_fmin_nxv4f16(<vscale x 4 x half> %v) {486; CHECK-LABEL: 'vreduce_fmin_nxv4f16'487; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv4f16(<vscale x 4 x half> %v)488; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red489;490; SIZE-LABEL: 'vreduce_fmin_nxv4f16'491; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv4f16(<vscale x 4 x half> %v)492; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red493;494  %red = call half @llvm.vector.reduce.fmin.nxv4f16(<vscale x 4 x half> %v)495  ret half %red496}497 498define half @vreduce_fmin_nxv64f16(<vscale x 64 x half> %v) {499; CHECK-LABEL: 'vreduce_fmin_nxv64f16'500; CHECK-NEXT:  Cost Model: Found an estimated cost of 15 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv64f16(<vscale x 64 x half> %v)501; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red502;503; SIZE-LABEL: 'vreduce_fmin_nxv64f16'504; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fmin.nxv64f16(<vscale x 64 x half> %v)505; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red506;507  %red = call half @llvm.vector.reduce.fmin.nxv64f16(<vscale x 64 x half> %v)508  ret half %red509}510 511define float @vreduce_fmin_nxv1f32(<vscale x 1 x float> %v) {512; CHECK-LABEL: 'vreduce_fmin_nxv1f32'513; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)514; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red515;516; SIZE-LABEL: 'vreduce_fmin_nxv1f32'517; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)518; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red519;520  %red = call float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)521  ret float %red522}523 524define float @vreduce_fmin_nxv1f32_nonans(<vscale x 1 x float> %v) {525; CHECK-LABEL: 'vreduce_fmin_nxv1f32_nonans'526; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)527; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red528;529; SIZE-LABEL: 'vreduce_fmin_nxv1f32_nonans'530; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)531; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red532;533  %red = call nnan float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)534  ret float %red535}536 537define float @vreduce_fmin_nxv1f32_nonans_noinfs(<vscale x 1 x float> %v) {538; CHECK-LABEL: 'vreduce_fmin_nxv1f32_nonans_noinfs'539; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)540; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red541;542; SIZE-LABEL: 'vreduce_fmin_nxv1f32_nonans_noinfs'543; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)544; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red545;546  %red = call nnan ninf float @llvm.vector.reduce.fmin.nxv1f32(<vscale x 1 x float> %v)547  ret float %red548}549 550define float @vreduce_fmin_nxv2f32(<vscale x 2 x float> %v) {551; CHECK-LABEL: 'vreduce_fmin_nxv2f32'552; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv2f32(<vscale x 2 x float> %v)553; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red554;555; SIZE-LABEL: 'vreduce_fmin_nxv2f32'556; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv2f32(<vscale x 2 x float> %v)557; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red558;559  %red = call float @llvm.vector.reduce.fmin.nxv2f32(<vscale x 2 x float> %v)560  ret float %red561}562 563define float @vreduce_fmin_nxv4f32(<vscale x 4 x float> %v) {564; CHECK-LABEL: 'vreduce_fmin_nxv4f32'565; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv4f32(<vscale x 4 x float> %v)566; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red567;568; SIZE-LABEL: 'vreduce_fmin_nxv4f32'569; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv4f32(<vscale x 4 x float> %v)570; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red571;572  %red = call float @llvm.vector.reduce.fmin.nxv4f32(<vscale x 4 x float> %v)573  ret float %red574}575 576define float @vreduce_fmin_nxv32f32(<vscale x 32 x float> %v) {577; CHECK-LABEL: 'vreduce_fmin_nxv32f32'578; CHECK-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv32f32(<vscale x 32 x float> %v)579; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red580;581; SIZE-LABEL: 'vreduce_fmin_nxv32f32'582; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fmin.nxv32f32(<vscale x 32 x float> %v)583; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red584;585  %red = call float @llvm.vector.reduce.fmin.nxv32f32(<vscale x 32 x float> %v)586  ret float %red587}588 589define double @vreduce_fmin_nxv1f64(<vscale x 1 x double> %v) {590; CHECK-LABEL: 'vreduce_fmin_nxv1f64'591; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)592; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red593;594; SIZE-LABEL: 'vreduce_fmin_nxv1f64'595; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)596; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red597;598  %red = call double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)599  ret double %red600}601 602define double @vreduce_fmin_nxv1f64_nonans(<vscale x 1 x double> %v) {603; CHECK-LABEL: 'vreduce_fmin_nxv1f64_nonans'604; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)605; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red606;607; SIZE-LABEL: 'vreduce_fmin_nxv1f64_nonans'608; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)609; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red610;611  %red = call nnan double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)612  ret double %red613}614 615define double @vreduce_fmin_nxv1f64_nonans_noinfs(<vscale x 1 x double> %v) {616; CHECK-LABEL: 'vreduce_fmin_nxv1f64_nonans_noinfs'617; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)618; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red619;620; SIZE-LABEL: 'vreduce_fmin_nxv1f64_nonans_noinfs'621; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)622; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red623;624  %red = call nnan ninf double @llvm.vector.reduce.fmin.nxv1f64(<vscale x 1 x double> %v)625  ret double %red626}627 628define double @vreduce_fmin_nxv2f64(<vscale x 2 x double> %v) {629; CHECK-LABEL: 'vreduce_fmin_nxv2f64'630; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv2f64(<vscale x 2 x double> %v)631; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red632;633; SIZE-LABEL: 'vreduce_fmin_nxv2f64'634; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv2f64(<vscale x 2 x double> %v)635; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red636;637  %red = call double @llvm.vector.reduce.fmin.nxv2f64(<vscale x 2 x double> %v)638  ret double %red639}640 641define double @vreduce_fmin_nxv4f64(<vscale x 4 x double> %v) {642; CHECK-LABEL: 'vreduce_fmin_nxv4f64'643; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv4f64(<vscale x 4 x double> %v)644; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red645;646; SIZE-LABEL: 'vreduce_fmin_nxv4f64'647; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv4f64(<vscale x 4 x double> %v)648; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red649;650  %red = call double @llvm.vector.reduce.fmin.nxv4f64(<vscale x 4 x double> %v)651  ret double %red652}653 654define double @vreduce_fmin_nxv16f64(<vscale x 16 x double> %v) {655; CHECK-LABEL: 'vreduce_fmin_nxv16f64'656; CHECK-NEXT:  Cost Model: Found an estimated cost of 13 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv16f64(<vscale x 16 x double> %v)657; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red658;659; SIZE-LABEL: 'vreduce_fmin_nxv16f64'660; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fmin.nxv16f64(<vscale x 16 x double> %v)661; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red662;663  %red = call double @llvm.vector.reduce.fmin.nxv16f64(<vscale x 16 x double> %v)664  ret double %red665}666 667define half @vreduce_fmax_nxv1f16(<vscale x 1 x half> %v) {668; CHECK-LABEL: 'vreduce_fmax_nxv1f16'669; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)670; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red671;672; SIZE-LABEL: 'vreduce_fmax_nxv1f16'673; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)674; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red675;676  %red = call half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)677  ret half %red678}679 680define half @vreduce_fmax_nxv1f16_nonans(<vscale x 1 x half> %v) {681; CHECK-LABEL: 'vreduce_fmax_nxv1f16_nonans'682; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)683; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red684;685; SIZE-LABEL: 'vreduce_fmax_nxv1f16_nonans'686; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)687; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red688;689  %red = call nnan half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)690  ret half %red691}692 693define half @vreduce_fmax_nxv1f16_nonans_noinfs(<vscale x 1 x half> %v) #1 {694; CHECK-LABEL: 'vreduce_fmax_nxv1f16_nonans_noinfs'695; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)696; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red697;698; SIZE-LABEL: 'vreduce_fmax_nxv1f16_nonans_noinfs'699; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)700; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red701;702  %red = call nnan ninf half @llvm.vector.reduce.fmax.nxv1f16(<vscale x 1 x half> %v)703  ret half %red704}705 706define half @vreduce_fmax_nxv2f16(<vscale x 2 x half> %v) {707; CHECK-LABEL: 'vreduce_fmax_nxv2f16'708; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv2f16(<vscale x 2 x half> %v)709; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red710;711; SIZE-LABEL: 'vreduce_fmax_nxv2f16'712; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv2f16(<vscale x 2 x half> %v)713; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red714;715  %red = call half @llvm.vector.reduce.fmax.nxv2f16(<vscale x 2 x half> %v)716  ret half %red717}718 719define half @vreduce_fmax_nxv4f16(<vscale x 4 x half> %v) {720; CHECK-LABEL: 'vreduce_fmax_nxv4f16'721; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv4f16(<vscale x 4 x half> %v)722; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red723;724; SIZE-LABEL: 'vreduce_fmax_nxv4f16'725; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv4f16(<vscale x 4 x half> %v)726; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red727;728  %red = call half @llvm.vector.reduce.fmax.nxv4f16(<vscale x 4 x half> %v)729  ret half %red730}731 732define half @vreduce_fmax_nxv64f16(<vscale x 64 x half> %v) {733; CHECK-LABEL: 'vreduce_fmax_nxv64f16'734; CHECK-NEXT:  Cost Model: Found an estimated cost of 15 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv64f16(<vscale x 64 x half> %v)735; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret half %red736;737; SIZE-LABEL: 'vreduce_fmax_nxv64f16'738; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call half @llvm.vector.reduce.fmax.nxv64f16(<vscale x 64 x half> %v)739; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret half %red740;741  %red = call half @llvm.vector.reduce.fmax.nxv64f16(<vscale x 64 x half> %v)742  ret half %red743}744 745define float @vreduce_fmax_nxv1f32(<vscale x 1 x float> %v) {746; CHECK-LABEL: 'vreduce_fmax_nxv1f32'747; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)748; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red749;750; SIZE-LABEL: 'vreduce_fmax_nxv1f32'751; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)752; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red753;754  %red = call float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)755  ret float %red756}757 758define float @vreduce_fmax_nxv1f32_nonans(<vscale x 1 x float> %v) {759; CHECK-LABEL: 'vreduce_fmax_nxv1f32_nonans'760; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)761; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red762;763; SIZE-LABEL: 'vreduce_fmax_nxv1f32_nonans'764; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)765; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red766;767  %red = call nnan float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)768  ret float %red769}770 771define float @vreduce_fmax_nxv1f32_nonans_noinfs(<vscale x 1 x float> %v) {772; CHECK-LABEL: 'vreduce_fmax_nxv1f32_nonans_noinfs'773; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)774; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red775;776; SIZE-LABEL: 'vreduce_fmax_nxv1f32_nonans_noinfs'777; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)778; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red779;780  %red = call nnan ninf float @llvm.vector.reduce.fmax.nxv1f32(<vscale x 1 x float> %v)781  ret float %red782}783 784define float @vreduce_fmax_nxv2f32(<vscale x 2 x float> %v) {785; CHECK-LABEL: 'vreduce_fmax_nxv2f32'786; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv2f32(<vscale x 2 x float> %v)787; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red788;789; SIZE-LABEL: 'vreduce_fmax_nxv2f32'790; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv2f32(<vscale x 2 x float> %v)791; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red792;793  %red = call float @llvm.vector.reduce.fmax.nxv2f32(<vscale x 2 x float> %v)794  ret float %red795}796 797define float @vreduce_fmax_nxv4f32(<vscale x 4 x float> %v) {798; CHECK-LABEL: 'vreduce_fmax_nxv4f32'799; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv4f32(<vscale x 4 x float> %v)800; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red801;802; SIZE-LABEL: 'vreduce_fmax_nxv4f32'803; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv4f32(<vscale x 4 x float> %v)804; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red805;806  %red = call float @llvm.vector.reduce.fmax.nxv4f32(<vscale x 4 x float> %v)807  ret float %red808}809 810define float @vreduce_fmax_nxv32f32(<vscale x 32 x float> %v) {811; CHECK-LABEL: 'vreduce_fmax_nxv32f32'812; CHECK-NEXT:  Cost Model: Found an estimated cost of 14 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv32f32(<vscale x 32 x float> %v)813; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red814;815; SIZE-LABEL: 'vreduce_fmax_nxv32f32'816; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call float @llvm.vector.reduce.fmax.nxv32f32(<vscale x 32 x float> %v)817; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red818;819  %red = call float @llvm.vector.reduce.fmax.nxv32f32(<vscale x 32 x float> %v)820  ret float %red821}822 823define double @vreduce_fmax_nxv1f64(<vscale x 1 x double> %v) {824; CHECK-LABEL: 'vreduce_fmax_nxv1f64'825; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)826; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red827;828; SIZE-LABEL: 'vreduce_fmax_nxv1f64'829; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)830; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red831;832  %red = call double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)833  ret double %red834}835 836define double @vreduce_fmax_nxv1f64_nonans(<vscale x 1 x double> %v) {837; CHECK-LABEL: 'vreduce_fmax_nxv1f64_nonans'838; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)839; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red840;841; SIZE-LABEL: 'vreduce_fmax_nxv1f64_nonans'842; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)843; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red844;845  %red = call nnan double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)846  ret double %red847}848 849define double @vreduce_fmax_nxv1f64_nonans_noinfs(<vscale x 1 x double> %v) {850; CHECK-LABEL: 'vreduce_fmax_nxv1f64_nonans_noinfs'851; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)852; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red853;854; SIZE-LABEL: 'vreduce_fmax_nxv1f64_nonans_noinfs'855; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call nnan ninf double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)856; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red857;858  %red = call nnan ninf double @llvm.vector.reduce.fmax.nxv1f64(<vscale x 1 x double> %v)859  ret double %red860}861 862define double @vreduce_fmax_nxv2f64(<vscale x 2 x double> %v) {863; CHECK-LABEL: 'vreduce_fmax_nxv2f64'864; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv2f64(<vscale x 2 x double> %v)865; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red866;867; SIZE-LABEL: 'vreduce_fmax_nxv2f64'868; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv2f64(<vscale x 2 x double> %v)869; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red870;871  %red = call double @llvm.vector.reduce.fmax.nxv2f64(<vscale x 2 x double> %v)872  ret double %red873}874 875define double @vreduce_fmax_nxv4f64(<vscale x 4 x double> %v) {876; CHECK-LABEL: 'vreduce_fmax_nxv4f64'877; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv4f64(<vscale x 4 x double> %v)878; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red879;880; SIZE-LABEL: 'vreduce_fmax_nxv4f64'881; SIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv4f64(<vscale x 4 x double> %v)882; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red883;884  %red = call double @llvm.vector.reduce.fmax.nxv4f64(<vscale x 4 x double> %v)885  ret double %red886}887 888define double @vreduce_fmax_nxv16f64(<vscale x 16 x double> %v) {889; CHECK-LABEL: 'vreduce_fmax_nxv16f64'890; CHECK-NEXT:  Cost Model: Found an estimated cost of 13 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv16f64(<vscale x 16 x double> %v)891; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret double %red892;893; SIZE-LABEL: 'vreduce_fmax_nxv16f64'894; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call double @llvm.vector.reduce.fmax.nxv16f64(<vscale x 16 x double> %v)895; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret double %red896;897  %red = call double @llvm.vector.reduce.fmax.nxv16f64(<vscale x 16 x double> %v)898  ret double %red899}900 901define float @vreduce_nsz_fadd_nxv1f32(<vscale x 1 x float> %v, float %s) {902; CHECK-LABEL: 'vreduce_nsz_fadd_nxv1f32'903; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc nsz float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)904; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret float %red905;906; SIZE-LABEL: 'vreduce_nsz_fadd_nxv1f32'907; SIZE-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %red = call reassoc nsz float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)908; SIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret float %red909;910  %red = call reassoc nsz float @llvm.vector.reduce.fadd.nxv1f32(float %s, <vscale x 1 x float> %v)911  ret float %red912}913