488 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py2; RUN: opt -passes="print<cost-model>" -cost-kind=all 2>&1 -disable-output -mtriple=thumbv8.1m.main-none-eabi -mattr=+mve < %s | FileCheck %s --check-prefixes=MVE,MVEI3; RUN: opt -passes="print<cost-model>" -cost-kind=all 2>&1 -disable-output -mtriple=thumbv8.1m.main-none-eabi -mattr=+mve.fp < %s | FileCheck %s --check-prefixes=MVE,MVEF4 5target datalayout = "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64"6 7declare i64 @llvm.smin.i64(i64, i64)8declare <2 x i64> @llvm.smin.v2i64(<2 x i64>, <2 x i64>)9declare <4 x i64> @llvm.smin.v4i64(<4 x i64>, <4 x i64>)10declare <8 x i64> @llvm.smin.v8i64(<8 x i64>, <8 x i64>)11 12declare i32 @llvm.smin.i32(i32, i32)13declare <2 x i32> @llvm.smin.v2i32(<2 x i32>, <2 x i32>)14declare <4 x i32> @llvm.smin.v4i32(<4 x i32>, <4 x i32>)15declare <8 x i32> @llvm.smin.v8i32(<8 x i32>, <8 x i32>)16declare <16 x i32> @llvm.smin.v16i32(<16 x i32>, <16 x i32>)17 18declare i16 @llvm.smin.i16(i16, i16)19declare <2 x i16> @llvm.smin.v2i16(<2 x i16>, <2 x i16>)20declare <4 x i16> @llvm.smin.v4i16(<4 x i16>, <4 x i16>)21declare <8 x i16> @llvm.smin.v8i16(<8 x i16>, <8 x i16>)22declare <16 x i16> @llvm.smin.v16i16(<16 x i16>, <16 x i16>)23declare <32 x i16> @llvm.smin.v32i16(<32 x i16>, <32 x i16>)24 25declare i8 @llvm.smin.i8(i8, i8)26declare <2 x i8> @llvm.smin.v2i8(<2 x i8>, <2 x i8>)27declare <4 x i8> @llvm.smin.v4i8(<4 x i8>, <4 x i8>)28declare <8 x i8> @llvm.smin.v8i8(<8 x i8>, <8 x i8>)29declare <16 x i8> @llvm.smin.v16i8(<16 x i8>, <16 x i8>)30declare <32 x i8> @llvm.smin.v32i8(<32 x i8>, <32 x i8>)31declare <64 x i8> @llvm.smin.v64i8(<64 x i8>, <64 x i8>)32 33define i32 @smin(i32 %arg) {34; MVE-LABEL: 'smin'35; MVE-NEXT: Cost Model: Found costs of RThru:3 CodeSize:4 Lat:3 SizeLat:3 for: %I64 = call i64 @llvm.smin.i64(i64 undef, i64 undef)36; MVE-NEXT: Cost Model: Found costs of RThru:38 CodeSize:19 Lat:38 SizeLat:38 for: %V2I64 = call <2 x i64> @llvm.smin.v2i64(<2 x i64> undef, <2 x i64> undef)37; MVE-NEXT: Cost Model: Found costs of RThru:76 CodeSize:38 Lat:76 SizeLat:76 for: %V4I64 = call <4 x i64> @llvm.smin.v4i64(<4 x i64> undef, <4 x i64> undef)38; MVE-NEXT: Cost Model: Found costs of RThru:152 CodeSize:76 Lat:152 SizeLat:152 for: %V8I64 = call <8 x i64> @llvm.smin.v8i64(<8 x i64> undef, <8 x i64> undef)39; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I32 = call i32 @llvm.smin.i32(i32 undef, i32 undef)40; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I32 = call <2 x i32> @llvm.smin.v2i32(<2 x i32> undef, <2 x i32> undef)41; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I32 = call <4 x i32> @llvm.smin.v4i32(<4 x i32> undef, <4 x i32> undef)42; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.smin.v8i32(<8 x i32> undef, <8 x i32> undef)43; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16I32 = call <16 x i32> @llvm.smin.v16i32(<16 x i32> undef, <16 x i32> undef)44; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I16 = call i16 @llvm.smin.i16(i16 undef, i16 undef)45; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I16 = call <2 x i16> @llvm.smin.v2i16(<2 x i16> undef, <2 x i16> undef)46; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I16 = call <4 x i16> @llvm.smin.v4i16(<4 x i16> undef, <4 x i16> undef)47; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I16 = call <8 x i16> @llvm.smin.v8i16(<8 x i16> undef, <8 x i16> undef)48; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.smin.v16i16(<16 x i16> undef, <16 x i16> undef)49; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32I16 = call <32 x i16> @llvm.smin.v32i16(<32 x i16> undef, <32 x i16> undef)50; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I8 = call i8 @llvm.smin.i8(i8 undef, i8 undef)51; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I8 = call <2 x i8> @llvm.smin.v2i8(<2 x i8> undef, <2 x i8> undef)52; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I8 = call <4 x i8> @llvm.smin.v4i8(<4 x i8> undef, <4 x i8> undef)53; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I8 = call <8 x i8> @llvm.smin.v8i8(<8 x i8> undef, <8 x i8> undef)54; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V16I8 = call <16 x i8> @llvm.smin.v16i8(<16 x i8> undef, <16 x i8> undef)55; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V32I8 = call <32 x i8> @llvm.smin.v32i8(<32 x i8> undef, <32 x i8> undef)56; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V64I8 = call <64 x i8> @llvm.smin.v64i8(<64 x i8> undef, <64 x i8> undef)57; MVE-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 undef58;59 %I64 = call i64 @llvm.smin.i64(i64 undef, i64 undef)60 %V2I64 = call <2 x i64> @llvm.smin.v2i64(<2 x i64> undef, <2 x i64> undef)61 %V4I64 = call <4 x i64> @llvm.smin.v4i64(<4 x i64> undef, <4 x i64> undef)62 %V8I64 = call <8 x i64> @llvm.smin.v8i64(<8 x i64> undef, <8 x i64> undef)63 64 %I32 = call i32 @llvm.smin.i32(i32 undef, i32 undef)65 %V2I32 = call <2 x i32> @llvm.smin.v2i32(<2 x i32> undef, <2 x i32> undef)66 %V4I32 = call <4 x i32> @llvm.smin.v4i32(<4 x i32> undef, <4 x i32> undef)67 %V8I32 = call <8 x i32> @llvm.smin.v8i32(<8 x i32> undef, <8 x i32> undef)68 %V16I32 = call <16 x i32> @llvm.smin.v16i32(<16 x i32> undef, <16 x i32> undef)69 70 %I16 = call i16 @llvm.smin.i16(i16 undef, i16 undef)71 %V2I16 = call <2 x i16> @llvm.smin.v2i16(<2 x i16> undef, <2 x i16> undef)72 %V4I16 = call <4 x i16> @llvm.smin.v4i16(<4 x i16> undef, <4 x i16> undef)73 %V8I16 = call <8 x i16> @llvm.smin.v8i16(<8 x i16> undef, <8 x i16> undef)74 %V16I16 = call <16 x i16> @llvm.smin.v16i16(<16 x i16> undef, <16 x i16> undef)75 %V32I16 = call <32 x i16> @llvm.smin.v32i16(<32 x i16> undef, <32 x i16> undef)76 77 %I8 = call i8 @llvm.smin.i8(i8 undef, i8 undef)78 %V2I8 = call <2 x i8> @llvm.smin.v2i8(<2 x i8> undef, <2 x i8> undef)79 %V4I8 = call <4 x i8> @llvm.smin.v4i8(<4 x i8> undef, <4 x i8> undef)80 %V8I8 = call <8 x i8> @llvm.smin.v8i8(<8 x i8> undef, <8 x i8> undef)81 %V16I8 = call <16 x i8> @llvm.smin.v16i8(<16 x i8> undef, <16 x i8> undef)82 %V32I8 = call <32 x i8> @llvm.smin.v32i8(<32 x i8> undef, <32 x i8> undef)83 %V64I8 = call <64 x i8> @llvm.smin.v64i8(<64 x i8> undef, <64 x i8> undef)84 85 ret i32 undef86}87 88 89declare i64 @llvm.smax.i64(i64, i64)90declare <2 x i64> @llvm.smax.v2i64(<2 x i64>, <2 x i64>)91declare <4 x i64> @llvm.smax.v4i64(<4 x i64>, <4 x i64>)92declare <8 x i64> @llvm.smax.v8i64(<8 x i64>, <8 x i64>)93 94declare i32 @llvm.smax.i32(i32, i32)95declare <2 x i32> @llvm.smax.v2i32(<2 x i32>, <2 x i32>)96declare <4 x i32> @llvm.smax.v4i32(<4 x i32>, <4 x i32>)97declare <8 x i32> @llvm.smax.v8i32(<8 x i32>, <8 x i32>)98declare <16 x i32> @llvm.smax.v16i32(<16 x i32>, <16 x i32>)99 100declare i16 @llvm.smax.i16(i16, i16)101declare <2 x i16> @llvm.smax.v2i16(<2 x i16>, <2 x i16>)102declare <4 x i16> @llvm.smax.v4i16(<4 x i16>, <4 x i16>)103declare <8 x i16> @llvm.smax.v8i16(<8 x i16>, <8 x i16>)104declare <16 x i16> @llvm.smax.v16i16(<16 x i16>, <16 x i16>)105declare <32 x i16> @llvm.smax.v32i16(<32 x i16>, <32 x i16>)106 107declare i8 @llvm.smax.i8(i8, i8)108declare <2 x i8> @llvm.smax.v2i8(<2 x i8>, <2 x i8>)109declare <4 x i8> @llvm.smax.v4i8(<4 x i8>, <4 x i8>)110declare <8 x i8> @llvm.smax.v8i8(<8 x i8>, <8 x i8>)111declare <16 x i8> @llvm.smax.v16i8(<16 x i8>, <16 x i8>)112declare <32 x i8> @llvm.smax.v32i8(<32 x i8>, <32 x i8>)113declare <64 x i8> @llvm.smax.v64i8(<64 x i8>, <64 x i8>)114 115define i32 @smax(i32 %arg) {116; MVE-LABEL: 'smax'117; MVE-NEXT: Cost Model: Found costs of RThru:3 CodeSize:4 Lat:3 SizeLat:3 for: %I64 = call i64 @llvm.smax.i64(i64 undef, i64 undef)118; MVE-NEXT: Cost Model: Found costs of RThru:38 CodeSize:19 Lat:38 SizeLat:38 for: %V2I64 = call <2 x i64> @llvm.smax.v2i64(<2 x i64> undef, <2 x i64> undef)119; MVE-NEXT: Cost Model: Found costs of RThru:76 CodeSize:38 Lat:76 SizeLat:76 for: %V4I64 = call <4 x i64> @llvm.smax.v4i64(<4 x i64> undef, <4 x i64> undef)120; MVE-NEXT: Cost Model: Found costs of RThru:152 CodeSize:76 Lat:152 SizeLat:152 for: %V8I64 = call <8 x i64> @llvm.smax.v8i64(<8 x i64> undef, <8 x i64> undef)121; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I32 = call i32 @llvm.smax.i32(i32 undef, i32 undef)122; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I32 = call <2 x i32> @llvm.smax.v2i32(<2 x i32> undef, <2 x i32> undef)123; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I32 = call <4 x i32> @llvm.smax.v4i32(<4 x i32> undef, <4 x i32> undef)124; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.smax.v8i32(<8 x i32> undef, <8 x i32> undef)125; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16I32 = call <16 x i32> @llvm.smax.v16i32(<16 x i32> undef, <16 x i32> undef)126; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I16 = call i16 @llvm.smax.i16(i16 undef, i16 undef)127; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I16 = call <2 x i16> @llvm.smax.v2i16(<2 x i16> undef, <2 x i16> undef)128; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I16 = call <4 x i16> @llvm.smax.v4i16(<4 x i16> undef, <4 x i16> undef)129; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I16 = call <8 x i16> @llvm.smax.v8i16(<8 x i16> undef, <8 x i16> undef)130; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.smax.v16i16(<16 x i16> undef, <16 x i16> undef)131; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32I16 = call <32 x i16> @llvm.smax.v32i16(<32 x i16> undef, <32 x i16> undef)132; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I8 = call i8 @llvm.smax.i8(i8 undef, i8 undef)133; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I8 = call <2 x i8> @llvm.smax.v2i8(<2 x i8> undef, <2 x i8> undef)134; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I8 = call <4 x i8> @llvm.smax.v4i8(<4 x i8> undef, <4 x i8> undef)135; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I8 = call <8 x i8> @llvm.smax.v8i8(<8 x i8> undef, <8 x i8> undef)136; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V16I8 = call <16 x i8> @llvm.smax.v16i8(<16 x i8> undef, <16 x i8> undef)137; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V32I8 = call <32 x i8> @llvm.smax.v32i8(<32 x i8> undef, <32 x i8> undef)138; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V64I8 = call <64 x i8> @llvm.smax.v64i8(<64 x i8> undef, <64 x i8> undef)139; MVE-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 undef140;141 %I64 = call i64 @llvm.smax.i64(i64 undef, i64 undef)142 %V2I64 = call <2 x i64> @llvm.smax.v2i64(<2 x i64> undef, <2 x i64> undef)143 %V4I64 = call <4 x i64> @llvm.smax.v4i64(<4 x i64> undef, <4 x i64> undef)144 %V8I64 = call <8 x i64> @llvm.smax.v8i64(<8 x i64> undef, <8 x i64> undef)145 146 %I32 = call i32 @llvm.smax.i32(i32 undef, i32 undef)147 %V2I32 = call <2 x i32> @llvm.smax.v2i32(<2 x i32> undef, <2 x i32> undef)148 %V4I32 = call <4 x i32> @llvm.smax.v4i32(<4 x i32> undef, <4 x i32> undef)149 %V8I32 = call <8 x i32> @llvm.smax.v8i32(<8 x i32> undef, <8 x i32> undef)150 %V16I32 = call <16 x i32> @llvm.smax.v16i32(<16 x i32> undef, <16 x i32> undef)151 152 %I16 = call i16 @llvm.smax.i16(i16 undef, i16 undef)153 %V2I16 = call <2 x i16> @llvm.smax.v2i16(<2 x i16> undef, <2 x i16> undef)154 %V4I16 = call <4 x i16> @llvm.smax.v4i16(<4 x i16> undef, <4 x i16> undef)155 %V8I16 = call <8 x i16> @llvm.smax.v8i16(<8 x i16> undef, <8 x i16> undef)156 %V16I16 = call <16 x i16> @llvm.smax.v16i16(<16 x i16> undef, <16 x i16> undef)157 %V32I16 = call <32 x i16> @llvm.smax.v32i16(<32 x i16> undef, <32 x i16> undef)158 159 %I8 = call i8 @llvm.smax.i8(i8 undef, i8 undef)160 %V2I8 = call <2 x i8> @llvm.smax.v2i8(<2 x i8> undef, <2 x i8> undef)161 %V4I8 = call <4 x i8> @llvm.smax.v4i8(<4 x i8> undef, <4 x i8> undef)162 %V8I8 = call <8 x i8> @llvm.smax.v8i8(<8 x i8> undef, <8 x i8> undef)163 %V16I8 = call <16 x i8> @llvm.smax.v16i8(<16 x i8> undef, <16 x i8> undef)164 %V32I8 = call <32 x i8> @llvm.smax.v32i8(<32 x i8> undef, <32 x i8> undef)165 %V64I8 = call <64 x i8> @llvm.smax.v64i8(<64 x i8> undef, <64 x i8> undef)166 167 ret i32 undef168}169 170 171 172declare i64 @llvm.umin.i64(i64, i64)173declare <2 x i64> @llvm.umin.v2i64(<2 x i64>, <2 x i64>)174declare <4 x i64> @llvm.umin.v4i64(<4 x i64>, <4 x i64>)175declare <8 x i64> @llvm.umin.v8i64(<8 x i64>, <8 x i64>)176 177declare i32 @llvm.umin.i32(i32, i32)178declare <2 x i32> @llvm.umin.v2i32(<2 x i32>, <2 x i32>)179declare <4 x i32> @llvm.umin.v4i32(<4 x i32>, <4 x i32>)180declare <8 x i32> @llvm.umin.v8i32(<8 x i32>, <8 x i32>)181declare <16 x i32> @llvm.umin.v16i32(<16 x i32>, <16 x i32>)182 183declare i16 @llvm.umin.i16(i16, i16)184declare <2 x i16> @llvm.umin.v2i16(<2 x i16>, <2 x i16>)185declare <4 x i16> @llvm.umin.v4i16(<4 x i16>, <4 x i16>)186declare <8 x i16> @llvm.umin.v8i16(<8 x i16>, <8 x i16>)187declare <16 x i16> @llvm.umin.v16i16(<16 x i16>, <16 x i16>)188declare <32 x i16> @llvm.umin.v32i16(<32 x i16>, <32 x i16>)189 190declare i8 @llvm.umin.i8(i8, i8)191declare <2 x i8> @llvm.umin.v2i8(<2 x i8>, <2 x i8>)192declare <4 x i8> @llvm.umin.v4i8(<4 x i8>, <4 x i8>)193declare <8 x i8> @llvm.umin.v8i8(<8 x i8>, <8 x i8>)194declare <16 x i8> @llvm.umin.v16i8(<16 x i8>, <16 x i8>)195declare <32 x i8> @llvm.umin.v32i8(<32 x i8>, <32 x i8>)196declare <64 x i8> @llvm.umin.v64i8(<64 x i8>, <64 x i8>)197 198define i32 @umin(i32 %arg) {199; MVE-LABEL: 'umin'200; MVE-NEXT: Cost Model: Found costs of RThru:3 CodeSize:4 Lat:3 SizeLat:3 for: %I64 = call i64 @llvm.umin.i64(i64 undef, i64 undef)201; MVE-NEXT: Cost Model: Found costs of RThru:38 CodeSize:19 Lat:38 SizeLat:38 for: %V2I64 = call <2 x i64> @llvm.umin.v2i64(<2 x i64> undef, <2 x i64> undef)202; MVE-NEXT: Cost Model: Found costs of RThru:76 CodeSize:38 Lat:76 SizeLat:76 for: %V4I64 = call <4 x i64> @llvm.umin.v4i64(<4 x i64> undef, <4 x i64> undef)203; MVE-NEXT: Cost Model: Found costs of RThru:152 CodeSize:76 Lat:152 SizeLat:152 for: %V8I64 = call <8 x i64> @llvm.umin.v8i64(<8 x i64> undef, <8 x i64> undef)204; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I32 = call i32 @llvm.umin.i32(i32 undef, i32 undef)205; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I32 = call <2 x i32> @llvm.umin.v2i32(<2 x i32> undef, <2 x i32> undef)206; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I32 = call <4 x i32> @llvm.umin.v4i32(<4 x i32> undef, <4 x i32> undef)207; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.umin.v8i32(<8 x i32> undef, <8 x i32> undef)208; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16I32 = call <16 x i32> @llvm.umin.v16i32(<16 x i32> undef, <16 x i32> undef)209; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I16 = call i16 @llvm.umin.i16(i16 undef, i16 undef)210; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I16 = call <2 x i16> @llvm.umin.v2i16(<2 x i16> undef, <2 x i16> undef)211; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I16 = call <4 x i16> @llvm.umin.v4i16(<4 x i16> undef, <4 x i16> undef)212; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I16 = call <8 x i16> @llvm.umin.v8i16(<8 x i16> undef, <8 x i16> undef)213; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.umin.v16i16(<16 x i16> undef, <16 x i16> undef)214; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32I16 = call <32 x i16> @llvm.umin.v32i16(<32 x i16> undef, <32 x i16> undef)215; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I8 = call i8 @llvm.umin.i8(i8 undef, i8 undef)216; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I8 = call <2 x i8> @llvm.umin.v2i8(<2 x i8> undef, <2 x i8> undef)217; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I8 = call <4 x i8> @llvm.umin.v4i8(<4 x i8> undef, <4 x i8> undef)218; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I8 = call <8 x i8> @llvm.umin.v8i8(<8 x i8> undef, <8 x i8> undef)219; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V16I8 = call <16 x i8> @llvm.umin.v16i8(<16 x i8> undef, <16 x i8> undef)220; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V32I8 = call <32 x i8> @llvm.umin.v32i8(<32 x i8> undef, <32 x i8> undef)221; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V64I8 = call <64 x i8> @llvm.umin.v64i8(<64 x i8> undef, <64 x i8> undef)222; MVE-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 undef223;224 %I64 = call i64 @llvm.umin.i64(i64 undef, i64 undef)225 %V2I64 = call <2 x i64> @llvm.umin.v2i64(<2 x i64> undef, <2 x i64> undef)226 %V4I64 = call <4 x i64> @llvm.umin.v4i64(<4 x i64> undef, <4 x i64> undef)227 %V8I64 = call <8 x i64> @llvm.umin.v8i64(<8 x i64> undef, <8 x i64> undef)228 229 %I32 = call i32 @llvm.umin.i32(i32 undef, i32 undef)230 %V2I32 = call <2 x i32> @llvm.umin.v2i32(<2 x i32> undef, <2 x i32> undef)231 %V4I32 = call <4 x i32> @llvm.umin.v4i32(<4 x i32> undef, <4 x i32> undef)232 %V8I32 = call <8 x i32> @llvm.umin.v8i32(<8 x i32> undef, <8 x i32> undef)233 %V16I32 = call <16 x i32> @llvm.umin.v16i32(<16 x i32> undef, <16 x i32> undef)234 235 %I16 = call i16 @llvm.umin.i16(i16 undef, i16 undef)236 %V2I16 = call <2 x i16> @llvm.umin.v2i16(<2 x i16> undef, <2 x i16> undef)237 %V4I16 = call <4 x i16> @llvm.umin.v4i16(<4 x i16> undef, <4 x i16> undef)238 %V8I16 = call <8 x i16> @llvm.umin.v8i16(<8 x i16> undef, <8 x i16> undef)239 %V16I16 = call <16 x i16> @llvm.umin.v16i16(<16 x i16> undef, <16 x i16> undef)240 %V32I16 = call <32 x i16> @llvm.umin.v32i16(<32 x i16> undef, <32 x i16> undef)241 242 %I8 = call i8 @llvm.umin.i8(i8 undef, i8 undef)243 %V2I8 = call <2 x i8> @llvm.umin.v2i8(<2 x i8> undef, <2 x i8> undef)244 %V4I8 = call <4 x i8> @llvm.umin.v4i8(<4 x i8> undef, <4 x i8> undef)245 %V8I8 = call <8 x i8> @llvm.umin.v8i8(<8 x i8> undef, <8 x i8> undef)246 %V16I8 = call <16 x i8> @llvm.umin.v16i8(<16 x i8> undef, <16 x i8> undef)247 %V32I8 = call <32 x i8> @llvm.umin.v32i8(<32 x i8> undef, <32 x i8> undef)248 %V64I8 = call <64 x i8> @llvm.umin.v64i8(<64 x i8> undef, <64 x i8> undef)249 250 ret i32 undef251}252 253 254declare i64 @llvm.umax.i64(i64, i64)255declare <2 x i64> @llvm.umax.v2i64(<2 x i64>, <2 x i64>)256declare <4 x i64> @llvm.umax.v4i64(<4 x i64>, <4 x i64>)257declare <8 x i64> @llvm.umax.v8i64(<8 x i64>, <8 x i64>)258 259declare i32 @llvm.umax.i32(i32, i32)260declare <2 x i32> @llvm.umax.v2i32(<2 x i32>, <2 x i32>)261declare <4 x i32> @llvm.umax.v4i32(<4 x i32>, <4 x i32>)262declare <8 x i32> @llvm.umax.v8i32(<8 x i32>, <8 x i32>)263declare <16 x i32> @llvm.umax.v16i32(<16 x i32>, <16 x i32>)264 265declare i16 @llvm.umax.i16(i16, i16)266declare <2 x i16> @llvm.umax.v2i16(<2 x i16>, <2 x i16>)267declare <4 x i16> @llvm.umax.v4i16(<4 x i16>, <4 x i16>)268declare <8 x i16> @llvm.umax.v8i16(<8 x i16>, <8 x i16>)269declare <16 x i16> @llvm.umax.v16i16(<16 x i16>, <16 x i16>)270declare <32 x i16> @llvm.umax.v32i16(<32 x i16>, <32 x i16>)271 272declare i8 @llvm.umax.i8(i8, i8)273declare <2 x i8> @llvm.umax.v2i8(<2 x i8>, <2 x i8>)274declare <4 x i8> @llvm.umax.v4i8(<4 x i8>, <4 x i8>)275declare <8 x i8> @llvm.umax.v8i8(<8 x i8>, <8 x i8>)276declare <16 x i8> @llvm.umax.v16i8(<16 x i8>, <16 x i8>)277declare <32 x i8> @llvm.umax.v32i8(<32 x i8>, <32 x i8>)278declare <64 x i8> @llvm.umax.v64i8(<64 x i8>, <64 x i8>)279 280define i32 @umax(i32 %arg) {281; MVE-LABEL: 'umax'282; MVE-NEXT: Cost Model: Found costs of RThru:3 CodeSize:4 Lat:3 SizeLat:3 for: %I64 = call i64 @llvm.umax.i64(i64 undef, i64 undef)283; MVE-NEXT: Cost Model: Found costs of RThru:38 CodeSize:19 Lat:38 SizeLat:38 for: %V2I64 = call <2 x i64> @llvm.umax.v2i64(<2 x i64> undef, <2 x i64> undef)284; MVE-NEXT: Cost Model: Found costs of RThru:76 CodeSize:38 Lat:76 SizeLat:76 for: %V4I64 = call <4 x i64> @llvm.umax.v4i64(<4 x i64> undef, <4 x i64> undef)285; MVE-NEXT: Cost Model: Found costs of RThru:152 CodeSize:76 Lat:152 SizeLat:152 for: %V8I64 = call <8 x i64> @llvm.umax.v8i64(<8 x i64> undef, <8 x i64> undef)286; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I32 = call i32 @llvm.umax.i32(i32 undef, i32 undef)287; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I32 = call <2 x i32> @llvm.umax.v2i32(<2 x i32> undef, <2 x i32> undef)288; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I32 = call <4 x i32> @llvm.umax.v4i32(<4 x i32> undef, <4 x i32> undef)289; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8I32 = call <8 x i32> @llvm.umax.v8i32(<8 x i32> undef, <8 x i32> undef)290; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16I32 = call <16 x i32> @llvm.umax.v16i32(<16 x i32> undef, <16 x i32> undef)291; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I16 = call i16 @llvm.umax.i16(i16 undef, i16 undef)292; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I16 = call <2 x i16> @llvm.umax.v2i16(<2 x i16> undef, <2 x i16> undef)293; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I16 = call <4 x i16> @llvm.umax.v4i16(<4 x i16> undef, <4 x i16> undef)294; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I16 = call <8 x i16> @llvm.umax.v8i16(<8 x i16> undef, <8 x i16> undef)295; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16I16 = call <16 x i16> @llvm.umax.v16i16(<16 x i16> undef, <16 x i16> undef)296; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32I16 = call <32 x i16> @llvm.umax.v32i16(<32 x i16> undef, <32 x i16> undef)297; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:3 Lat:2 SizeLat:2 for: %I8 = call i8 @llvm.umax.i8(i8 undef, i8 undef)298; MVE-NEXT: Cost Model: Found costs of RThru:22 CodeSize:11 Lat:22 SizeLat:22 for: %V2I8 = call <2 x i8> @llvm.umax.v2i8(<2 x i8> undef, <2 x i8> undef)299; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4I8 = call <4 x i8> @llvm.umax.v4i8(<4 x i8> undef, <4 x i8> undef)300; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8I8 = call <8 x i8> @llvm.umax.v8i8(<8 x i8> undef, <8 x i8> undef)301; MVE-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V16I8 = call <16 x i8> @llvm.umax.v16i8(<16 x i8> undef, <16 x i8> undef)302; MVE-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V32I8 = call <32 x i8> @llvm.umax.v32i8(<32 x i8> undef, <32 x i8> undef)303; MVE-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V64I8 = call <64 x i8> @llvm.umax.v64i8(<64 x i8> undef, <64 x i8> undef)304; MVE-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 undef305;306 %I64 = call i64 @llvm.umax.i64(i64 undef, i64 undef)307 %V2I64 = call <2 x i64> @llvm.umax.v2i64(<2 x i64> undef, <2 x i64> undef)308 %V4I64 = call <4 x i64> @llvm.umax.v4i64(<4 x i64> undef, <4 x i64> undef)309 %V8I64 = call <8 x i64> @llvm.umax.v8i64(<8 x i64> undef, <8 x i64> undef)310 311 %I32 = call i32 @llvm.umax.i32(i32 undef, i32 undef)312 %V2I32 = call <2 x i32> @llvm.umax.v2i32(<2 x i32> undef, <2 x i32> undef)313 %V4I32 = call <4 x i32> @llvm.umax.v4i32(<4 x i32> undef, <4 x i32> undef)314 %V8I32 = call <8 x i32> @llvm.umax.v8i32(<8 x i32> undef, <8 x i32> undef)315 %V16I32 = call <16 x i32> @llvm.umax.v16i32(<16 x i32> undef, <16 x i32> undef)316 317 %I16 = call i16 @llvm.umax.i16(i16 undef, i16 undef)318 %V2I16 = call <2 x i16> @llvm.umax.v2i16(<2 x i16> undef, <2 x i16> undef)319 %V4I16 = call <4 x i16> @llvm.umax.v4i16(<4 x i16> undef, <4 x i16> undef)320 %V8I16 = call <8 x i16> @llvm.umax.v8i16(<8 x i16> undef, <8 x i16> undef)321 %V16I16 = call <16 x i16> @llvm.umax.v16i16(<16 x i16> undef, <16 x i16> undef)322 %V32I16 = call <32 x i16> @llvm.umax.v32i16(<32 x i16> undef, <32 x i16> undef)323 324 %I8 = call i8 @llvm.umax.i8(i8 undef, i8 undef)325 %V2I8 = call <2 x i8> @llvm.umax.v2i8(<2 x i8> undef, <2 x i8> undef)326 %V4I8 = call <4 x i8> @llvm.umax.v4i8(<4 x i8> undef, <4 x i8> undef)327 %V8I8 = call <8 x i8> @llvm.umax.v8i8(<8 x i8> undef, <8 x i8> undef)328 %V16I8 = call <16 x i8> @llvm.umax.v16i8(<16 x i8> undef, <16 x i8> undef)329 %V32I8 = call <32 x i8> @llvm.umax.v32i8(<32 x i8> undef, <32 x i8> undef)330 %V64I8 = call <64 x i8> @llvm.umax.v64i8(<64 x i8> undef, <64 x i8> undef)331 332 ret i32 undef333}334 335 336 337declare double @llvm.minnum.f64(double, double)338declare <2 x double> @llvm.minnum.v2f64(<2 x double>, <2 x double>)339declare <4 x double> @llvm.minnum.v4f64(<4 x double>, <4 x double>)340declare <8 x double> @llvm.minnum.v8f64(<8 x double>, <8 x double>)341 342declare float @llvm.minnum.f32(float, float)343declare <2 x float> @llvm.minnum.v2f32(<2 x float>, <2 x float>)344declare <4 x float> @llvm.minnum.v4f32(<4 x float>, <4 x float>)345declare <8 x float> @llvm.minnum.v8f32(<8 x float>, <8 x float>)346declare <16 x float> @llvm.minnum.v16f32(<16 x float>, <16 x float>)347 348declare half @llvm.minnum.f16(half, half)349declare <2 x half> @llvm.minnum.v2f16(<2 x half>, <2 x half>)350declare <4 x half> @llvm.minnum.v4f16(<4 x half>, <4 x half>)351declare <8 x half> @llvm.minnum.v8f16(<8 x half>, <8 x half>)352declare <16 x half> @llvm.minnum.v16f16(<16 x half>, <16 x half>)353declare <32 x half> @llvm.minnum.v32f16(<32 x half>, <32 x half>)354 355define float @minnum(float %arg) {356; MVEI-LABEL: 'minnum'357; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F64 = call double @llvm.minnum.f64(double undef, double undef)358; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F64 = call <2 x double> @llvm.minnum.v2f64(<2 x double> undef, <2 x double> undef)359; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F64 = call <4 x double> @llvm.minnum.v4f64(<4 x double> undef, <4 x double> undef)360; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F64 = call <8 x double> @llvm.minnum.v8f64(<8 x double> undef, <8 x double> undef)361; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F32 = call float @llvm.minnum.f32(float undef, float undef)362; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F32 = call <2 x float> @llvm.minnum.v2f32(<2 x float> undef, <2 x float> undef)363; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F32 = call <4 x float> @llvm.minnum.v4f32(<4 x float> undef, <4 x float> undef)364; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F32 = call <8 x float> @llvm.minnum.v8f32(<8 x float> undef, <8 x float> undef)365; MVEI-NEXT: Cost Model: Found costs of RThru:176 CodeSize:32 Lat:176 SizeLat:176 for: %V16F32 = call <16 x float> @llvm.minnum.v16f32(<16 x float> undef, <16 x float> undef)366; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F16 = call half @llvm.minnum.f16(half undef, half undef)367; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F16 = call <2 x half> @llvm.minnum.v2f16(<2 x half> undef, <2 x half> undef)368; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F16 = call <4 x half> @llvm.minnum.v4f16(<4 x half> undef, <4 x half> undef)369; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F16 = call <8 x half> @llvm.minnum.v8f16(<8 x half> undef, <8 x half> undef)370; MVEI-NEXT: Cost Model: Found costs of RThru:176 CodeSize:32 Lat:176 SizeLat:176 for: %V16F16 = call <16 x half> @llvm.minnum.v16f16(<16 x half> undef, <16 x half> undef)371; MVEI-NEXT: Cost Model: Found costs of RThru:352 CodeSize:64 Lat:352 SizeLat:352 for: %V32F16 = call <32 x half> @llvm.minnum.v32f16(<32 x half> undef, <32 x half> undef)372; MVEI-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret float undef373;374; MVEF-LABEL: 'minnum'375; MVEF-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F64 = call double @llvm.minnum.f64(double undef, double undef)376; MVEF-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F64 = call <2 x double> @llvm.minnum.v2f64(<2 x double> undef, <2 x double> undef)377; MVEF-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F64 = call <4 x double> @llvm.minnum.v4f64(<4 x double> undef, <4 x double> undef)378; MVEF-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F64 = call <8 x double> @llvm.minnum.v8f64(<8 x double> undef, <8 x double> undef)379; MVEF-NEXT: Cost Model: Found costs of 1 for: %F32 = call float @llvm.minnum.f32(float undef, float undef)380; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V2F32 = call <2 x float> @llvm.minnum.v2f32(<2 x float> undef, <2 x float> undef)381; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4F32 = call <4 x float> @llvm.minnum.v4f32(<4 x float> undef, <4 x float> undef)382; MVEF-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8F32 = call <8 x float> @llvm.minnum.v8f32(<8 x float> undef, <8 x float> undef)383; MVEF-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16F32 = call <16 x float> @llvm.minnum.v16f32(<16 x float> undef, <16 x float> undef)384; MVEF-NEXT: Cost Model: Found costs of 1 for: %F16 = call half @llvm.minnum.f16(half undef, half undef)385; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V2F16 = call <2 x half> @llvm.minnum.v2f16(<2 x half> undef, <2 x half> undef)386; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4F16 = call <4 x half> @llvm.minnum.v4f16(<4 x half> undef, <4 x half> undef)387; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8F16 = call <8 x half> @llvm.minnum.v8f16(<8 x half> undef, <8 x half> undef)388; MVEF-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16F16 = call <16 x half> @llvm.minnum.v16f16(<16 x half> undef, <16 x half> undef)389; MVEF-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32F16 = call <32 x half> @llvm.minnum.v32f16(<32 x half> undef, <32 x half> undef)390; MVEF-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret float undef391;392 %F64 = call double @llvm.minnum.f64(double undef, double undef)393 %V2F64 = call <2 x double> @llvm.minnum.v2f64(<2 x double> undef, <2 x double> undef)394 %V4F64 = call <4 x double> @llvm.minnum.v4f64(<4 x double> undef, <4 x double> undef)395 %V8F64 = call <8 x double> @llvm.minnum.v8f64(<8 x double> undef, <8 x double> undef)396 397 %F32 = call float @llvm.minnum.f32(float undef, float undef)398 %V2F32 = call <2 x float> @llvm.minnum.v2f32(<2 x float> undef, <2 x float> undef)399 %V4F32 = call <4 x float> @llvm.minnum.v4f32(<4 x float> undef, <4 x float> undef)400 %V8F32 = call <8 x float> @llvm.minnum.v8f32(<8 x float> undef, <8 x float> undef)401 %V16F32 = call <16 x float> @llvm.minnum.v16f32(<16 x float> undef, <16 x float> undef)402 403 %F16 = call half @llvm.minnum.f16(half undef, half undef)404 %V2F16 = call <2 x half> @llvm.minnum.v2f16(<2 x half> undef, <2 x half> undef)405 %V4F16 = call <4 x half> @llvm.minnum.v4f16(<4 x half> undef, <4 x half> undef)406 %V8F16 = call <8 x half> @llvm.minnum.v8f16(<8 x half> undef, <8 x half> undef)407 %V16F16 = call <16 x half> @llvm.minnum.v16f16(<16 x half> undef, <16 x half> undef)408 %V32F16 = call <32 x half> @llvm.minnum.v32f16(<32 x half> undef, <32 x half> undef)409 410 ret float undef411}412 413declare double @llvm.maxnum.f64(double, double)414declare <2 x double> @llvm.maxnum.v2f64(<2 x double>, <2 x double>)415declare <4 x double> @llvm.maxnum.v4f64(<4 x double>, <4 x double>)416declare <8 x double> @llvm.maxnum.v8f64(<8 x double>, <8 x double>)417 418declare float @llvm.maxnum.f32(float, float)419declare <2 x float> @llvm.maxnum.v2f32(<2 x float>, <2 x float>)420declare <4 x float> @llvm.maxnum.v4f32(<4 x float>, <4 x float>)421declare <8 x float> @llvm.maxnum.v8f32(<8 x float>, <8 x float>)422declare <16 x float> @llvm.maxnum.v16f32(<16 x float>, <16 x float>)423 424declare half @llvm.maxnum.f16(half, half)425declare <2 x half> @llvm.maxnum.v2f16(<2 x half>, <2 x half>)426declare <4 x half> @llvm.maxnum.v4f16(<4 x half>, <4 x half>)427declare <8 x half> @llvm.maxnum.v8f16(<8 x half>, <8 x half>)428declare <16 x half> @llvm.maxnum.v16f16(<16 x half>, <16 x half>)429declare <32 x half> @llvm.maxnum.v32f16(<32 x half>, <32 x half>)430 431define float @maxnum(float %arg) {432; MVEI-LABEL: 'maxnum'433; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F64 = call double @llvm.maxnum.f64(double undef, double undef)434; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F64 = call <2 x double> @llvm.maxnum.v2f64(<2 x double> undef, <2 x double> undef)435; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F64 = call <4 x double> @llvm.maxnum.v4f64(<4 x double> undef, <4 x double> undef)436; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F64 = call <8 x double> @llvm.maxnum.v8f64(<8 x double> undef, <8 x double> undef)437; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F32 = call float @llvm.maxnum.f32(float undef, float undef)438; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F32 = call <2 x float> @llvm.maxnum.v2f32(<2 x float> undef, <2 x float> undef)439; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F32 = call <4 x float> @llvm.maxnum.v4f32(<4 x float> undef, <4 x float> undef)440; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F32 = call <8 x float> @llvm.maxnum.v8f32(<8 x float> undef, <8 x float> undef)441; MVEI-NEXT: Cost Model: Found costs of RThru:176 CodeSize:32 Lat:176 SizeLat:176 for: %V16F32 = call <16 x float> @llvm.maxnum.v16f32(<16 x float> undef, <16 x float> undef)442; MVEI-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F16 = call half @llvm.maxnum.f16(half undef, half undef)443; MVEI-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F16 = call <2 x half> @llvm.maxnum.v2f16(<2 x half> undef, <2 x half> undef)444; MVEI-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F16 = call <4 x half> @llvm.maxnum.v4f16(<4 x half> undef, <4 x half> undef)445; MVEI-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F16 = call <8 x half> @llvm.maxnum.v8f16(<8 x half> undef, <8 x half> undef)446; MVEI-NEXT: Cost Model: Found costs of RThru:176 CodeSize:32 Lat:176 SizeLat:176 for: %V16F16 = call <16 x half> @llvm.maxnum.v16f16(<16 x half> undef, <16 x half> undef)447; MVEI-NEXT: Cost Model: Found costs of RThru:352 CodeSize:64 Lat:352 SizeLat:352 for: %V32F16 = call <32 x half> @llvm.maxnum.v32f16(<32 x half> undef, <32 x half> undef)448; MVEI-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret float undef449;450; MVEF-LABEL: 'maxnum'451; MVEF-NEXT: Cost Model: Found costs of RThru:10 CodeSize:1 Lat:10 SizeLat:10 for: %F64 = call double @llvm.maxnum.f64(double undef, double undef)452; MVEF-NEXT: Cost Model: Found costs of RThru:22 CodeSize:4 Lat:22 SizeLat:22 for: %V2F64 = call <2 x double> @llvm.maxnum.v2f64(<2 x double> undef, <2 x double> undef)453; MVEF-NEXT: Cost Model: Found costs of RThru:44 CodeSize:8 Lat:44 SizeLat:44 for: %V4F64 = call <4 x double> @llvm.maxnum.v4f64(<4 x double> undef, <4 x double> undef)454; MVEF-NEXT: Cost Model: Found costs of RThru:88 CodeSize:16 Lat:88 SizeLat:88 for: %V8F64 = call <8 x double> @llvm.maxnum.v8f64(<8 x double> undef, <8 x double> undef)455; MVEF-NEXT: Cost Model: Found costs of 1 for: %F32 = call float @llvm.maxnum.f32(float undef, float undef)456; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V2F32 = call <2 x float> @llvm.maxnum.v2f32(<2 x float> undef, <2 x float> undef)457; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4F32 = call <4 x float> @llvm.maxnum.v4f32(<4 x float> undef, <4 x float> undef)458; MVEF-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V8F32 = call <8 x float> @llvm.maxnum.v8f32(<8 x float> undef, <8 x float> undef)459; MVEF-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V16F32 = call <16 x float> @llvm.maxnum.v16f32(<16 x float> undef, <16 x float> undef)460; MVEF-NEXT: Cost Model: Found costs of 1 for: %F16 = call half @llvm.maxnum.f16(half undef, half undef)461; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V2F16 = call <2 x half> @llvm.maxnum.v2f16(<2 x half> undef, <2 x half> undef)462; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V4F16 = call <4 x half> @llvm.maxnum.v4f16(<4 x half> undef, <4 x half> undef)463; MVEF-NEXT: Cost Model: Found costs of RThru:2 CodeSize:1 Lat:2 SizeLat:2 for: %V8F16 = call <8 x half> @llvm.maxnum.v8f16(<8 x half> undef, <8 x half> undef)464; MVEF-NEXT: Cost Model: Found costs of RThru:4 CodeSize:2 Lat:4 SizeLat:4 for: %V16F16 = call <16 x half> @llvm.maxnum.v16f16(<16 x half> undef, <16 x half> undef)465; MVEF-NEXT: Cost Model: Found costs of RThru:8 CodeSize:4 Lat:8 SizeLat:8 for: %V32F16 = call <32 x half> @llvm.maxnum.v32f16(<32 x half> undef, <32 x half> undef)466; MVEF-NEXT: Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret float undef467;468 %F64 = call double @llvm.maxnum.f64(double undef, double undef)469 %V2F64 = call <2 x double> @llvm.maxnum.v2f64(<2 x double> undef, <2 x double> undef)470 %V4F64 = call <4 x double> @llvm.maxnum.v4f64(<4 x double> undef, <4 x double> undef)471 %V8F64 = call <8 x double> @llvm.maxnum.v8f64(<8 x double> undef, <8 x double> undef)472 473 %F32 = call float @llvm.maxnum.f32(float undef, float undef)474 %V2F32 = call <2 x float> @llvm.maxnum.v2f32(<2 x float> undef, <2 x float> undef)475 %V4F32 = call <4 x float> @llvm.maxnum.v4f32(<4 x float> undef, <4 x float> undef)476 %V8F32 = call <8 x float> @llvm.maxnum.v8f32(<8 x float> undef, <8 x float> undef)477 %V16F32 = call <16 x float> @llvm.maxnum.v16f32(<16 x float> undef, <16 x float> undef)478 479 %F16 = call half @llvm.maxnum.f16(half undef, half undef)480 %V2F16 = call <2 x half> @llvm.maxnum.v2f16(<2 x half> undef, <2 x half> undef)481 %V4F16 = call <4 x half> @llvm.maxnum.v4f16(<4 x half> undef, <4 x half> undef)482 %V8F16 = call <8 x half> @llvm.maxnum.v8f16(<8 x half> undef, <8 x half> undef)483 %V16F16 = call <16 x half> @llvm.maxnum.v16f16(<16 x half> undef, <16 x half> undef)484 %V32F16 = call <32 x half> @llvm.maxnum.v32f16(<32 x half> undef, <32 x half> undef)485 486 ret float undef487}488