• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llc -mtriple=armv7-linux-gnueabihf %s -o - | FileCheck %s --check-prefix=CHECK-HARD
2; RUN: llc -mtriple=armv7-linux-musleabihf %s -o - | FileCheck %s --check-prefix=CHECK-HARD
3; RUN: llc -mtriple=armv7-linux-eabihf %s -o - | FileCheck %s --check-prefix=CHECK-HARD
4; RUN: llc -mtriple=armv7-linux-gnueabihf -float-abi=soft %s -o - | FileCheck %s --check-prefix=CHECK-SOFT
5; RUN: llc -mtriple=armv7-linux-musleabihf -float-abi=soft %s -o - | FileCheck %s --check-prefix=CHECK-SOFT
6; RUN: llc -mtriple=armv7-linux-gnueabi %s -o - | FileCheck %s --check-prefix=CHECK-SOFT
7; RUN: llc -mtriple=armv7-linux-musleabi %s -o - | FileCheck %s --check-prefix=CHECK-SOFT
8; RUN: llc -mtriple=armv7-linux-eabi -float-abi=hard %s -o - | FileCheck %s --check-prefix=CHECK-HARD
9; RUN: llc -mtriple=thumbv7-apple-ios6.0 %s -o - | FileCheck %s --check-prefix=CHECK-SOFT
10
11define float @test_abi(float %lhs, float %rhs) {
12  %sum = fadd float %lhs, %rhs
13  ret float %sum
14
15; CHECK-HARD-LABEL: test_abi:
16; CHECK-HARD-NOT: vmov
17; CHECK-HARD: vadd.f32 s0, s0, s1
18; CHECK-HARD-NOT: vmov
19
20; CHECK-SOFT-LABEL: test_abi:
21; CHECK-SOFT-DAG: vmov [[LHS:s[0-9]+]], r0
22; CHECK-SOFT-DAG: vmov [[RHS:s[0-9]+]], r1
23; CHECK-SOFT: vadd.f32 [[DEST:s[0-9]+]], [[LHS]], [[RHS]]
24; CHECK-SOFT: vmov r0, [[DEST]]
25}
26