1*f4a2713aSLionel Sambuc // REQUIRES: arm-registered-target
2*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -triple thumbv7-none-linux-gnueabihf \
3*f4a2713aSLionel Sambuc // RUN: -target-abi aapcs \
4*f4a2713aSLionel Sambuc // RUN: -target-cpu cortex-a8 \
5*f4a2713aSLionel Sambuc // RUN: -mfloat-abi hard \
6*f4a2713aSLionel Sambuc // RUN: -ffreestanding \
7*f4a2713aSLionel Sambuc // RUN: -O3 -S -emit-llvm -o - %s | FileCheck %s
8*f4a2713aSLionel Sambuc
9*f4a2713aSLionel Sambuc #include <arm_neon.h>
10*f4a2713aSLionel Sambuc
test_fma_order(float32x2_t accum,float32x2_t lhs,float32x2_t rhs)11*f4a2713aSLionel Sambuc float32x2_t test_fma_order(float32x2_t accum, float32x2_t lhs, float32x2_t rhs) {
12*f4a2713aSLionel Sambuc return vfma_f32(accum, lhs, rhs);
13*f4a2713aSLionel Sambuc // CHECK: call <2 x float> @llvm.fma.v2f32(<2 x float> %lhs, <2 x float> %rhs, <2 x float> %accum)
14*f4a2713aSLionel Sambuc }
15*f4a2713aSLionel Sambuc
test_fmaq_order(float32x4_t accum,float32x4_t lhs,float32x4_t rhs)16*f4a2713aSLionel Sambuc float32x4_t test_fmaq_order(float32x4_t accum, float32x4_t lhs, float32x4_t rhs) {
17*f4a2713aSLionel Sambuc return vfmaq_f32(accum, lhs, rhs);
18*f4a2713aSLionel Sambuc // CHECK: call <4 x float> @llvm.fma.v4f32(<4 x float> %lhs, <4 x float> %rhs, <4 x float> %accum)
19*f4a2713aSLionel Sambuc }
20