llvm.org GIT mirror llvm / release_38 test / CodeGen / X86 / floor-soft-float.ll
release_38

Tree @release_38 (Download .tar.gz)

floor-soft-float.ll @release_38raw · history · blame

; RUN: llc < %s -march=x86-64 -mattr=+sse4.1,-avx | FileCheck %s --check-prefix=CHECK-HARD-FLOAT
; RUN: llc < %s -march=x86-64 -mattr=+sse4.1,-avx,+soft-float | FileCheck %s --check-prefix=CHECK-SOFT-FLOAT

target triple = "x86_64-unknown-linux-gnu"

declare float @llvm.floor.f32(float)

; CHECK-SOFT-FLOAT: callq floorf
; CHECK-HARD-FLOAT: roundss $9, %xmm0, %xmm0
define float @myfloor(float %a) {
  %val = tail call float @llvm.floor.f32(float %a)
  ret float %val
}