brintos

brintos / llvm-project-archived public Read only

0
0
Text · 57.1 KiB · 0f69dba Raw
830 lines · c
1// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py2// RUN: %clang_cc1 -triple arm64-none-linux-gnu -target-feature +v8.2a -target-feature +neon -target-feature +fp16fml \3// RUN: -disable-O0-optnone -emit-llvm -o - %s | opt -S -passes=mem2reg,sroa | FileCheck %s4 5// REQUIRES: aarch64-registered-target6 7// Test AArch64 Armv8.2-A FP16 Fused Multiply-Add Long intrinsics8 9#include <arm_neon.h>10 11// Vector form12 13// CHECK-LABEL: @test_vfmlal_low_f16(14// CHECK-NEXT:  entry:15// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>16// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>17// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>18// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <2 x i32> [[TMP0]] to <8 x i8>19// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x i16> [[TMP1]] to <8 x i8>20// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <4 x i16> [[TMP2]] to <8 x i8>21// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP3]] to <2 x float>22// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP4]] to <4 x half>23// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP5]] to <4 x half>24// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal.v2f32.v4f16(<2 x float> [[VFMLAL_LOW_I]], <4 x half> [[VFMLAL_LOW1_I]], <4 x half> [[VFMLAL_LOW2_I]])25// CHECK-NEXT:    ret <2 x float> [[VFMLAL_LOW3_I]]26//27float32x2_t test_vfmlal_low_f16(float32x2_t a, float16x4_t b, float16x4_t c) {28  return vfmlal_low_f16(a, b, c);29}30 31// CHECK-LABEL: @test_vfmlsl_low_f16(32// CHECK-NEXT:  entry:33// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>34// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>35// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>36// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <2 x i32> [[TMP0]] to <8 x i8>37// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x i16> [[TMP1]] to <8 x i8>38// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <4 x i16> [[TMP2]] to <8 x i8>39// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP3]] to <2 x float>40// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP4]] to <4 x half>41// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP5]] to <4 x half>42// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl.v2f32.v4f16(<2 x float> [[VFMLSL_LOW_I]], <4 x half> [[VFMLSL_LOW1_I]], <4 x half> [[VFMLSL_LOW2_I]])43// CHECK-NEXT:    ret <2 x float> [[VFMLSL_LOW3_I]]44//45float32x2_t test_vfmlsl_low_f16(float32x2_t a, float16x4_t b, float16x4_t c) {46  return vfmlsl_low_f16(a, b, c);47}48 49// CHECK-LABEL: @test_vfmlal_high_f16(50// CHECK-NEXT:  entry:51// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>52// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>53// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>54// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <2 x i32> [[TMP0]] to <8 x i8>55// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x i16> [[TMP1]] to <8 x i8>56// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <4 x i16> [[TMP2]] to <8 x i8>57// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP3]] to <2 x float>58// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP4]] to <4 x half>59// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP5]] to <4 x half>60// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal2.v2f32.v4f16(<2 x float> [[VFMLAL_HIGH_I]], <4 x half> [[VFMLAL_HIGH1_I]], <4 x half> [[VFMLAL_HIGH2_I]])61// CHECK-NEXT:    ret <2 x float> [[VFMLAL_HIGH3_I]]62//63float32x2_t test_vfmlal_high_f16(float32x2_t a, float16x4_t b, float16x4_t c) {64  return vfmlal_high_f16(a, b, c);65}66 67// CHECK-LABEL: @test_vfmlsl_high_f16(68// CHECK-NEXT:  entry:69// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>70// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>71// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>72// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <2 x i32> [[TMP0]] to <8 x i8>73// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x i16> [[TMP1]] to <8 x i8>74// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <4 x i16> [[TMP2]] to <8 x i8>75// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP3]] to <2 x float>76// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP4]] to <4 x half>77// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP5]] to <4 x half>78// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl2.v2f32.v4f16(<2 x float> [[VFMLSL_HIGH_I]], <4 x half> [[VFMLSL_HIGH1_I]], <4 x half> [[VFMLSL_HIGH2_I]])79// CHECK-NEXT:    ret <2 x float> [[VFMLSL_HIGH3_I]]80//81float32x2_t test_vfmlsl_high_f16(float32x2_t a, float16x4_t b, float16x4_t c) {82  return vfmlsl_high_f16(a, b, c);83}84 85// CHECK-LABEL: @test_vfmlalq_low_f16(86// CHECK-NEXT:  entry:87// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>88// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>89// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>90// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <4 x i32> [[TMP0]] to <16 x i8>91// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x i16> [[TMP1]] to <16 x i8>92// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <8 x i16> [[TMP2]] to <16 x i8>93// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP3]] to <4 x float>94// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP4]] to <8 x half>95// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP5]] to <8 x half>96// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal.v4f32.v8f16(<4 x float> [[VFMLAL_LOW_I]], <8 x half> [[VFMLAL_LOW1_I]], <8 x half> [[VFMLAL_LOW2_I]])97// CHECK-NEXT:    ret <4 x float> [[VFMLAL_LOW3_I]]98//99float32x4_t test_vfmlalq_low_f16(float32x4_t a, float16x8_t b, float16x8_t c) {100  return vfmlalq_low_f16(a, b, c);101}102 103// CHECK-LABEL: @test_vfmlslq_low_f16(104// CHECK-NEXT:  entry:105// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>106// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>107// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>108// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <4 x i32> [[TMP0]] to <16 x i8>109// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x i16> [[TMP1]] to <16 x i8>110// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <8 x i16> [[TMP2]] to <16 x i8>111// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP3]] to <4 x float>112// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP4]] to <8 x half>113// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP5]] to <8 x half>114// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl.v4f32.v8f16(<4 x float> [[VFMLSL_LOW_I]], <8 x half> [[VFMLSL_LOW1_I]], <8 x half> [[VFMLSL_LOW2_I]])115// CHECK-NEXT:    ret <4 x float> [[VFMLSL_LOW3_I]]116//117float32x4_t test_vfmlslq_low_f16(float32x4_t a, float16x8_t b, float16x8_t c) {118  return vfmlslq_low_f16(a, b, c);119}120 121// CHECK-LABEL: @test_vfmlalq_high_f16(122// CHECK-NEXT:  entry:123// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>124// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>125// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>126// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <4 x i32> [[TMP0]] to <16 x i8>127// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x i16> [[TMP1]] to <16 x i8>128// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <8 x i16> [[TMP2]] to <16 x i8>129// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP3]] to <4 x float>130// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP4]] to <8 x half>131// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP5]] to <8 x half>132// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal2.v4f32.v8f16(<4 x float> [[VFMLAL_HIGH_I]], <8 x half> [[VFMLAL_HIGH1_I]], <8 x half> [[VFMLAL_HIGH2_I]])133// CHECK-NEXT:    ret <4 x float> [[VFMLAL_HIGH3_I]]134//135float32x4_t test_vfmlalq_high_f16(float32x4_t a, float16x8_t b, float16x8_t c) {136  return vfmlalq_high_f16(a, b, c);137}138 139// CHECK-LABEL: @test_vfmlslq_high_f16(140// CHECK-NEXT:  entry:141// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>142// CHECK-NEXT:    [[TMP1:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>143// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>144// CHECK-NEXT:    [[TMP3:%.*]] = bitcast <4 x i32> [[TMP0]] to <16 x i8>145// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x i16> [[TMP1]] to <16 x i8>146// CHECK-NEXT:    [[TMP5:%.*]] = bitcast <8 x i16> [[TMP2]] to <16 x i8>147// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP3]] to <4 x float>148// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP4]] to <8 x half>149// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP5]] to <8 x half>150// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl2.v4f32.v8f16(<4 x float> [[VFMLSL_HIGH_I]], <8 x half> [[VFMLSL_HIGH1_I]], <8 x half> [[VFMLSL_HIGH2_I]])151// CHECK-NEXT:    ret <4 x float> [[VFMLSL_HIGH3_I]]152//153float32x4_t test_vfmlslq_high_f16(float32x4_t a, float16x8_t b, float16x8_t c) {154  return vfmlslq_high_f16(a, b, c);155}156 157// Indexed form158 159// CHECK-LABEL: @test_vfmlal_lane_low_f16(160// CHECK-NEXT:  entry:161// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>162// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 0163// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half164// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0165// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>166// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 0167// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half168// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1169// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>170// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 0171// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half172// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2173// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>174// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 0175// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half176// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3177// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>178// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>179// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>180// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>181// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>182// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>183// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>184// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>185// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>186// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal.v2f32.v4f16(<2 x float> [[VFMLAL_LOW_I]], <4 x half> [[VFMLAL_LOW1_I]], <4 x half> [[VFMLAL_LOW2_I]])187// CHECK-NEXT:    ret <2 x float> [[VFMLAL_LOW3_I]]188//189float32x2_t test_vfmlal_lane_low_f16(float32x2_t a, float16x4_t b, float16x4_t c) {190  return vfmlal_lane_low_f16(a, b, c, 0);191}192 193// CHECK-LABEL: @test_vfmlal_lane_high_f16(194// CHECK-NEXT:  entry:195// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>196// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 1197// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half198// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0199// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>200// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 1201// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half202// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1203// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>204// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 1205// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half206// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2207// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>208// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 1209// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half210// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3211// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>212// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>213// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>214// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>215// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>216// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>217// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>218// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>219// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>220// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal2.v2f32.v4f16(<2 x float> [[VFMLAL_HIGH_I]], <4 x half> [[VFMLAL_HIGH1_I]], <4 x half> [[VFMLAL_HIGH2_I]])221// CHECK-NEXT:    ret <2 x float> [[VFMLAL_HIGH3_I]]222//223float32x2_t test_vfmlal_lane_high_f16(float32x2_t a, float16x4_t b, float16x4_t c) {224  return vfmlal_lane_high_f16(a, b, c, 1);225}226 227// CHECK-LABEL: @test_vfmlalq_lane_low_f16(228// CHECK-NEXT:  entry:229// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>230// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 2231// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half232// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0233// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>234// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 2235// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half236// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1237// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>238// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 2239// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half240// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2241// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>242// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 2243// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half244// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3245// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>246// CHECK-NEXT:    [[VGET_LANE39:%.*]] = extractelement <4 x i16> [[TMP8]], i32 2247// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGET_LANE39]] to half248// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4249// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>250// CHECK-NEXT:    [[VGET_LANE49:%.*]] = extractelement <4 x i16> [[TMP10]], i32 2251// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGET_LANE49]] to half252// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5253// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>254// CHECK-NEXT:    [[VGET_LANE59:%.*]] = extractelement <4 x i16> [[TMP12]], i32 2255// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGET_LANE59]] to half256// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6257// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>258// CHECK-NEXT:    [[VGET_LANE69:%.*]] = extractelement <4 x i16> [[TMP14]], i32 2259// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGET_LANE69]] to half260// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7261// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>262// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>263// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>264// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>265// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>266// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>267// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>268// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>269// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>270// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal.v4f32.v8f16(<4 x float> [[VFMLAL_LOW_I]], <8 x half> [[VFMLAL_LOW1_I]], <8 x half> [[VFMLAL_LOW2_I]])271// CHECK-NEXT:    ret <4 x float> [[VFMLAL_LOW3_I]]272//273float32x4_t test_vfmlalq_lane_low_f16(float32x4_t a, float16x8_t b, float16x4_t c) {274  return vfmlalq_lane_low_f16(a, b, c, 2);275}276 277// CHECK-LABEL: @test_vfmlalq_lane_high_f16(278// CHECK-NEXT:  entry:279// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>280// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 3281// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half282// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0283// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>284// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 3285// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half286// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1287// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>288// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 3289// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half290// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2291// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>292// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 3293// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half294// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3295// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>296// CHECK-NEXT:    [[VGET_LANE39:%.*]] = extractelement <4 x i16> [[TMP8]], i32 3297// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGET_LANE39]] to half298// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4299// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>300// CHECK-NEXT:    [[VGET_LANE49:%.*]] = extractelement <4 x i16> [[TMP10]], i32 3301// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGET_LANE49]] to half302// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5303// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>304// CHECK-NEXT:    [[VGET_LANE59:%.*]] = extractelement <4 x i16> [[TMP12]], i32 3305// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGET_LANE59]] to half306// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6307// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>308// CHECK-NEXT:    [[VGET_LANE69:%.*]] = extractelement <4 x i16> [[TMP14]], i32 3309// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGET_LANE69]] to half310// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7311// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>312// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>313// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>314// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>315// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>316// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>317// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>318// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>319// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>320// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal2.v4f32.v8f16(<4 x float> [[VFMLAL_HIGH_I]], <8 x half> [[VFMLAL_HIGH1_I]], <8 x half> [[VFMLAL_HIGH2_I]])321// CHECK-NEXT:    ret <4 x float> [[VFMLAL_HIGH3_I]]322//323float32x4_t test_vfmlalq_lane_high_f16(float32x4_t a, float16x8_t b, float16x4_t c) {324  return vfmlalq_lane_high_f16(a, b, c, 3);325}326 327// CHECK-LABEL: @test_vfmlal_laneq_low_f16(328// CHECK-NEXT:  entry:329// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>330// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 4331// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half332// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0333// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>334// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 4335// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half336// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1337// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>338// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 4339// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half340// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2341// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>342// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 4343// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half344// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3345// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>346// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>347// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>348// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>349// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>350// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>351// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>352// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>353// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>354// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal.v2f32.v4f16(<2 x float> [[VFMLAL_LOW_I]], <4 x half> [[VFMLAL_LOW1_I]], <4 x half> [[VFMLAL_LOW2_I]])355// CHECK-NEXT:    ret <2 x float> [[VFMLAL_LOW3_I]]356//357float32x2_t test_vfmlal_laneq_low_f16(float32x2_t a, float16x4_t b, float16x8_t c) {358  return vfmlal_laneq_low_f16(a, b, c, 4);359}360 361// CHECK-LABEL: @test_vfmlal_laneq_high_f16(362// CHECK-NEXT:  entry:363// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>364// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 5365// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half366// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0367// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>368// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 5369// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half370// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1371// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>372// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 5373// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half374// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2375// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>376// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 5377// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half378// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3379// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>380// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>381// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>382// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>383// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>384// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>385// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>386// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>387// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>388// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlal2.v2f32.v4f16(<2 x float> [[VFMLAL_HIGH_I]], <4 x half> [[VFMLAL_HIGH1_I]], <4 x half> [[VFMLAL_HIGH2_I]])389// CHECK-NEXT:    ret <2 x float> [[VFMLAL_HIGH3_I]]390//391float32x2_t test_vfmlal_laneq_high_f16(float32x2_t a, float16x4_t b, float16x8_t c) {392  return vfmlal_laneq_high_f16(a, b, c, 5);393}394 395// CHECK-LABEL: @test_vfmlalq_laneq_low_f16(396// CHECK-NEXT:  entry:397// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>398// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 6399// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half400// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0401// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>402// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 6403// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half404// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1405// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>406// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 6407// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half408// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2409// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>410// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 6411// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half412// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3413// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>414// CHECK-NEXT:    [[VGETQ_LANE39:%.*]] = extractelement <8 x i16> [[TMP8]], i32 6415// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGETQ_LANE39]] to half416// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4417// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>418// CHECK-NEXT:    [[VGETQ_LANE49:%.*]] = extractelement <8 x i16> [[TMP10]], i32 6419// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGETQ_LANE49]] to half420// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5421// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>422// CHECK-NEXT:    [[VGETQ_LANE59:%.*]] = extractelement <8 x i16> [[TMP12]], i32 6423// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGETQ_LANE59]] to half424// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6425// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>426// CHECK-NEXT:    [[VGETQ_LANE69:%.*]] = extractelement <8 x i16> [[TMP14]], i32 6427// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGETQ_LANE69]] to half428// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7429// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>430// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>431// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>432// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>433// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>434// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>435// CHECK-NEXT:    [[VFMLAL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>436// CHECK-NEXT:    [[VFMLAL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>437// CHECK-NEXT:    [[VFMLAL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>438// CHECK-NEXT:    [[VFMLAL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal.v4f32.v8f16(<4 x float> [[VFMLAL_LOW_I]], <8 x half> [[VFMLAL_LOW1_I]], <8 x half> [[VFMLAL_LOW2_I]])439// CHECK-NEXT:    ret <4 x float> [[VFMLAL_LOW3_I]]440//441float32x4_t test_vfmlalq_laneq_low_f16(float32x4_t a, float16x8_t b, float16x8_t c) {442  return vfmlalq_laneq_low_f16(a, b, c, 6);443}444 445// CHECK-LABEL: @test_vfmlalq_laneq_high_f16(446// CHECK-NEXT:  entry:447// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>448// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 7449// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half450// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0451// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>452// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 7453// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half454// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1455// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>456// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 7457// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half458// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2459// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>460// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 7461// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half462// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3463// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>464// CHECK-NEXT:    [[VGETQ_LANE39:%.*]] = extractelement <8 x i16> [[TMP8]], i32 7465// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGETQ_LANE39]] to half466// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4467// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>468// CHECK-NEXT:    [[VGETQ_LANE49:%.*]] = extractelement <8 x i16> [[TMP10]], i32 7469// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGETQ_LANE49]] to half470// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5471// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>472// CHECK-NEXT:    [[VGETQ_LANE59:%.*]] = extractelement <8 x i16> [[TMP12]], i32 7473// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGETQ_LANE59]] to half474// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6475// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>476// CHECK-NEXT:    [[VGETQ_LANE69:%.*]] = extractelement <8 x i16> [[TMP14]], i32 7477// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGETQ_LANE69]] to half478// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7479// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>480// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>481// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>482// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>483// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>484// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>485// CHECK-NEXT:    [[VFMLAL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>486// CHECK-NEXT:    [[VFMLAL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>487// CHECK-NEXT:    [[VFMLAL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>488// CHECK-NEXT:    [[VFMLAL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlal2.v4f32.v8f16(<4 x float> [[VFMLAL_HIGH_I]], <8 x half> [[VFMLAL_HIGH1_I]], <8 x half> [[VFMLAL_HIGH2_I]])489// CHECK-NEXT:    ret <4 x float> [[VFMLAL_HIGH3_I]]490//491float32x4_t test_vfmlalq_laneq_high_f16(float32x4_t a, float16x8_t b, float16x8_t c) {492  return vfmlalq_laneq_high_f16(a, b, c, 7);493}494 495// CHECK-LABEL: @test_vfmlsl_lane_low_f16(496// CHECK-NEXT:  entry:497// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>498// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 0499// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half500// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0501// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>502// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 0503// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half504// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1505// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>506// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 0507// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half508// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2509// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>510// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 0511// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half512// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3513// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>514// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>515// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>516// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>517// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>518// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>519// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>520// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>521// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>522// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl.v2f32.v4f16(<2 x float> [[VFMLSL_LOW_I]], <4 x half> [[VFMLSL_LOW1_I]], <4 x half> [[VFMLSL_LOW2_I]])523// CHECK-NEXT:    ret <2 x float> [[VFMLSL_LOW3_I]]524//525float32x2_t test_vfmlsl_lane_low_f16(float32x2_t a, float16x4_t b, float16x4_t c) {526  return vfmlsl_lane_low_f16(a, b, c, 0);527}528 529// CHECK-LABEL: @test_vfmlsl_lane_high_f16(530// CHECK-NEXT:  entry:531// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>532// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 1533// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half534// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0535// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>536// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 1537// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half538// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1539// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>540// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 1541// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half542// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2543// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>544// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 1545// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half546// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3547// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>548// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>549// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>550// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>551// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>552// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>553// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>554// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>555// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>556// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl2.v2f32.v4f16(<2 x float> [[VFMLSL_HIGH_I]], <4 x half> [[VFMLSL_HIGH1_I]], <4 x half> [[VFMLSL_HIGH2_I]])557// CHECK-NEXT:    ret <2 x float> [[VFMLSL_HIGH3_I]]558//559float32x2_t test_vfmlsl_lane_high_f16(float32x2_t a, float16x4_t b, float16x4_t c) {560  return vfmlsl_lane_high_f16(a, b, c, 1);561}562 563// CHECK-LABEL: @test_vfmlslq_lane_low_f16(564// CHECK-NEXT:  entry:565// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>566// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 2567// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half568// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0569// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>570// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 2571// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half572// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1573// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>574// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 2575// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half576// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2577// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>578// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 2579// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half580// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3581// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>582// CHECK-NEXT:    [[VGET_LANE39:%.*]] = extractelement <4 x i16> [[TMP8]], i32 2583// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGET_LANE39]] to half584// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4585// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>586// CHECK-NEXT:    [[VGET_LANE49:%.*]] = extractelement <4 x i16> [[TMP10]], i32 2587// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGET_LANE49]] to half588// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5589// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>590// CHECK-NEXT:    [[VGET_LANE59:%.*]] = extractelement <4 x i16> [[TMP12]], i32 2591// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGET_LANE59]] to half592// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6593// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>594// CHECK-NEXT:    [[VGET_LANE69:%.*]] = extractelement <4 x i16> [[TMP14]], i32 2595// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGET_LANE69]] to half596// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7597// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>598// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>599// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>600// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>601// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>602// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>603// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>604// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>605// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>606// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl.v4f32.v8f16(<4 x float> [[VFMLSL_LOW_I]], <8 x half> [[VFMLSL_LOW1_I]], <8 x half> [[VFMLSL_LOW2_I]])607// CHECK-NEXT:    ret <4 x float> [[VFMLSL_LOW3_I]]608//609float32x4_t test_vfmlslq_lane_low_f16(float32x4_t a, float16x8_t b, float16x4_t c) {610  return vfmlslq_lane_low_f16(a, b, c, 2);611}612 613// CHECK-LABEL: @test_vfmlslq_lane_high_f16(614// CHECK-NEXT:  entry:615// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <4 x half> [[C:%.*]] to <4 x i16>616// CHECK-NEXT:    [[VGET_LANE:%.*]] = extractelement <4 x i16> [[TMP0]], i32 3617// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGET_LANE]] to half618// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0619// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>620// CHECK-NEXT:    [[VGET_LANE9:%.*]] = extractelement <4 x i16> [[TMP2]], i32 3621// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGET_LANE9]] to half622// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1623// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>624// CHECK-NEXT:    [[VGET_LANE19:%.*]] = extractelement <4 x i16> [[TMP4]], i32 3625// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGET_LANE19]] to half626// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2627// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>628// CHECK-NEXT:    [[VGET_LANE29:%.*]] = extractelement <4 x i16> [[TMP6]], i32 3629// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGET_LANE29]] to half630// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3631// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>632// CHECK-NEXT:    [[VGET_LANE39:%.*]] = extractelement <4 x i16> [[TMP8]], i32 3633// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGET_LANE39]] to half634// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4635// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>636// CHECK-NEXT:    [[VGET_LANE49:%.*]] = extractelement <4 x i16> [[TMP10]], i32 3637// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGET_LANE49]] to half638// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5639// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>640// CHECK-NEXT:    [[VGET_LANE59:%.*]] = extractelement <4 x i16> [[TMP12]], i32 3641// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGET_LANE59]] to half642// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6643// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <4 x half> [[C]] to <4 x i16>644// CHECK-NEXT:    [[VGET_LANE69:%.*]] = extractelement <4 x i16> [[TMP14]], i32 3645// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGET_LANE69]] to half646// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7647// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>648// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>649// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>650// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>651// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>652// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>653// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>654// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>655// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>656// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl2.v4f32.v8f16(<4 x float> [[VFMLSL_HIGH_I]], <8 x half> [[VFMLSL_HIGH1_I]], <8 x half> [[VFMLSL_HIGH2_I]])657// CHECK-NEXT:    ret <4 x float> [[VFMLSL_HIGH3_I]]658//659float32x4_t test_vfmlslq_lane_high_f16(float32x4_t a, float16x8_t b, float16x4_t c) {660  return vfmlslq_lane_high_f16(a, b, c, 3);661}662 663// CHECK-LABEL: @test_vfmlsl_laneq_low_f16(664// CHECK-NEXT:  entry:665// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>666// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 4667// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half668// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0669// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>670// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 4671// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half672// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1673// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>674// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 4675// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half676// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2677// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>678// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 4679// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half680// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3681// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>682// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>683// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>684// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>685// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>686// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>687// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>688// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>689// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>690// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl.v2f32.v4f16(<2 x float> [[VFMLSL_LOW_I]], <4 x half> [[VFMLSL_LOW1_I]], <4 x half> [[VFMLSL_LOW2_I]])691// CHECK-NEXT:    ret <2 x float> [[VFMLSL_LOW3_I]]692//693float32x2_t test_vfmlsl_laneq_low_f16(float32x2_t a, float16x4_t b, float16x8_t c) {694  return vfmlsl_laneq_low_f16(a, b, c, 4);695}696 697// CHECK-LABEL: @test_vfmlsl_laneq_high_f16(698// CHECK-NEXT:  entry:699// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>700// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 5701// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half702// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <4 x half> poison, half [[TMP1]], i32 0703// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>704// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 5705// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half706// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <4 x half> [[VECINIT]], half [[TMP3]], i32 1707// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>708// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 5709// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half710// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <4 x half> [[VECINIT12]], half [[TMP5]], i32 2711// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>712// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 5713// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half714// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <4 x half> [[VECINIT22]], half [[TMP7]], i32 3715// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <2 x float> [[A:%.*]] to <2 x i32>716// CHECK-NEXT:    [[TMP9:%.*]] = bitcast <4 x half> [[B:%.*]] to <4 x i16>717// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <4 x half> [[VECINIT32]] to <4 x i16>718// CHECK-NEXT:    [[TMP11:%.*]] = bitcast <2 x i32> [[TMP8]] to <8 x i8>719// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <4 x i16> [[TMP9]] to <8 x i8>720// CHECK-NEXT:    [[TMP13:%.*]] = bitcast <4 x i16> [[TMP10]] to <8 x i8>721// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <8 x i8> [[TMP11]] to <2 x float>722// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <8 x i8> [[TMP12]] to <4 x half>723// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <8 x i8> [[TMP13]] to <4 x half>724// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <2 x float> @llvm.aarch64.neon.fmlsl2.v2f32.v4f16(<2 x float> [[VFMLSL_HIGH_I]], <4 x half> [[VFMLSL_HIGH1_I]], <4 x half> [[VFMLSL_HIGH2_I]])725// CHECK-NEXT:    ret <2 x float> [[VFMLSL_HIGH3_I]]726//727float32x2_t test_vfmlsl_laneq_high_f16(float32x2_t a, float16x4_t b, float16x8_t c) {728  return vfmlsl_laneq_high_f16(a, b, c, 5);729}730 731// CHECK-LABEL: @test_vfmlslq_laneq_low_f16(732// CHECK-NEXT:  entry:733// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>734// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 6735// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half736// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0737// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>738// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 6739// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half740// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1741// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>742// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 6743// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half744// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2745// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>746// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 6747// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half748// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3749// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>750// CHECK-NEXT:    [[VGETQ_LANE39:%.*]] = extractelement <8 x i16> [[TMP8]], i32 6751// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGETQ_LANE39]] to half752// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4753// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>754// CHECK-NEXT:    [[VGETQ_LANE49:%.*]] = extractelement <8 x i16> [[TMP10]], i32 6755// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGETQ_LANE49]] to half756// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5757// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>758// CHECK-NEXT:    [[VGETQ_LANE59:%.*]] = extractelement <8 x i16> [[TMP12]], i32 6759// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGETQ_LANE59]] to half760// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6761// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>762// CHECK-NEXT:    [[VGETQ_LANE69:%.*]] = extractelement <8 x i16> [[TMP14]], i32 6763// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGETQ_LANE69]] to half764// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7765// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>766// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>767// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>768// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>769// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>770// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>771// CHECK-NEXT:    [[VFMLSL_LOW_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>772// CHECK-NEXT:    [[VFMLSL_LOW1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>773// CHECK-NEXT:    [[VFMLSL_LOW2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>774// CHECK-NEXT:    [[VFMLSL_LOW3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl.v4f32.v8f16(<4 x float> [[VFMLSL_LOW_I]], <8 x half> [[VFMLSL_LOW1_I]], <8 x half> [[VFMLSL_LOW2_I]])775// CHECK-NEXT:    ret <4 x float> [[VFMLSL_LOW3_I]]776//777float32x4_t test_vfmlslq_laneq_low_f16(float32x4_t a, float16x8_t b, float16x8_t c) {778  return vfmlslq_laneq_low_f16(a, b, c, 6);779}780 781// CHECK-LABEL: @test_vfmlslq_laneq_high_f16(782// CHECK-NEXT:  entry:783// CHECK-NEXT:    [[TMP0:%.*]] = bitcast <8 x half> [[C:%.*]] to <8 x i16>784// CHECK-NEXT:    [[VGETQ_LANE:%.*]] = extractelement <8 x i16> [[TMP0]], i32 7785// CHECK-NEXT:    [[TMP1:%.*]] = bitcast i16 [[VGETQ_LANE]] to half786// CHECK-NEXT:    [[VECINIT:%.*]] = insertelement <8 x half> poison, half [[TMP1]], i32 0787// CHECK-NEXT:    [[TMP2:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>788// CHECK-NEXT:    [[VGETQ_LANE9:%.*]] = extractelement <8 x i16> [[TMP2]], i32 7789// CHECK-NEXT:    [[TMP3:%.*]] = bitcast i16 [[VGETQ_LANE9]] to half790// CHECK-NEXT:    [[VECINIT12:%.*]] = insertelement <8 x half> [[VECINIT]], half [[TMP3]], i32 1791// CHECK-NEXT:    [[TMP4:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>792// CHECK-NEXT:    [[VGETQ_LANE19:%.*]] = extractelement <8 x i16> [[TMP4]], i32 7793// CHECK-NEXT:    [[TMP5:%.*]] = bitcast i16 [[VGETQ_LANE19]] to half794// CHECK-NEXT:    [[VECINIT22:%.*]] = insertelement <8 x half> [[VECINIT12]], half [[TMP5]], i32 2795// CHECK-NEXT:    [[TMP6:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>796// CHECK-NEXT:    [[VGETQ_LANE29:%.*]] = extractelement <8 x i16> [[TMP6]], i32 7797// CHECK-NEXT:    [[TMP7:%.*]] = bitcast i16 [[VGETQ_LANE29]] to half798// CHECK-NEXT:    [[VECINIT32:%.*]] = insertelement <8 x half> [[VECINIT22]], half [[TMP7]], i32 3799// CHECK-NEXT:    [[TMP8:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>800// CHECK-NEXT:    [[VGETQ_LANE39:%.*]] = extractelement <8 x i16> [[TMP8]], i32 7801// CHECK-NEXT:    [[TMP9:%.*]] = bitcast i16 [[VGETQ_LANE39]] to half802// CHECK-NEXT:    [[VECINIT42:%.*]] = insertelement <8 x half> [[VECINIT32]], half [[TMP9]], i32 4803// CHECK-NEXT:    [[TMP10:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>804// CHECK-NEXT:    [[VGETQ_LANE49:%.*]] = extractelement <8 x i16> [[TMP10]], i32 7805// CHECK-NEXT:    [[TMP11:%.*]] = bitcast i16 [[VGETQ_LANE49]] to half806// CHECK-NEXT:    [[VECINIT52:%.*]] = insertelement <8 x half> [[VECINIT42]], half [[TMP11]], i32 5807// CHECK-NEXT:    [[TMP12:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>808// CHECK-NEXT:    [[VGETQ_LANE59:%.*]] = extractelement <8 x i16> [[TMP12]], i32 7809// CHECK-NEXT:    [[TMP13:%.*]] = bitcast i16 [[VGETQ_LANE59]] to half810// CHECK-NEXT:    [[VECINIT62:%.*]] = insertelement <8 x half> [[VECINIT52]], half [[TMP13]], i32 6811// CHECK-NEXT:    [[TMP14:%.*]] = bitcast <8 x half> [[C]] to <8 x i16>812// CHECK-NEXT:    [[VGETQ_LANE69:%.*]] = extractelement <8 x i16> [[TMP14]], i32 7813// CHECK-NEXT:    [[TMP15:%.*]] = bitcast i16 [[VGETQ_LANE69]] to half814// CHECK-NEXT:    [[VECINIT72:%.*]] = insertelement <8 x half> [[VECINIT62]], half [[TMP15]], i32 7815// CHECK-NEXT:    [[TMP16:%.*]] = bitcast <4 x float> [[A:%.*]] to <4 x i32>816// CHECK-NEXT:    [[TMP17:%.*]] = bitcast <8 x half> [[B:%.*]] to <8 x i16>817// CHECK-NEXT:    [[TMP18:%.*]] = bitcast <8 x half> [[VECINIT72]] to <8 x i16>818// CHECK-NEXT:    [[TMP19:%.*]] = bitcast <4 x i32> [[TMP16]] to <16 x i8>819// CHECK-NEXT:    [[TMP20:%.*]] = bitcast <8 x i16> [[TMP17]] to <16 x i8>820// CHECK-NEXT:    [[TMP21:%.*]] = bitcast <8 x i16> [[TMP18]] to <16 x i8>821// CHECK-NEXT:    [[VFMLSL_HIGH_I:%.*]] = bitcast <16 x i8> [[TMP19]] to <4 x float>822// CHECK-NEXT:    [[VFMLSL_HIGH1_I:%.*]] = bitcast <16 x i8> [[TMP20]] to <8 x half>823// CHECK-NEXT:    [[VFMLSL_HIGH2_I:%.*]] = bitcast <16 x i8> [[TMP21]] to <8 x half>824// CHECK-NEXT:    [[VFMLSL_HIGH3_I:%.*]] = call <4 x float> @llvm.aarch64.neon.fmlsl2.v4f32.v8f16(<4 x float> [[VFMLSL_HIGH_I]], <8 x half> [[VFMLSL_HIGH1_I]], <8 x half> [[VFMLSL_HIGH2_I]])825// CHECK-NEXT:    ret <4 x float> [[VFMLSL_HIGH3_I]]826//827float32x4_t test_vfmlslq_laneq_high_f16(float32x4_t a, float16x8_t b, float16x8_t c) {828  return vfmlslq_laneq_high_f16(a, b, c, 7);829}830