mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-25 14:32:53 +00:00
b34d3aa35b
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157594 91177308-0d34-0410-b5e6-96231b3b80d8
22 lines
605 B
LLVM
22 lines
605 B
LLVM
; RUN: llc < %s -march=nvptx -mcpu=sm_10 | FileCheck %s
|
|
; RUN: llc < %s -march=nvptx64 -mcpu=sm_10 | FileCheck %s
|
|
; RUN: llc < %s -march=nvptx -mcpu=sm_20 | FileCheck %s
|
|
; RUN: llc < %s -march=nvptx64 -mcpu=sm_20 | FileCheck %s
|
|
|
|
define ptx_device float @test_fabsf(float %f) {
|
|
; CHECK: abs.f32 %f0, %f0;
|
|
; CHECK: ret;
|
|
%x = call float @llvm.fabs.f32(float %f)
|
|
ret float %x
|
|
}
|
|
|
|
define ptx_device double @test_fabs(double %d) {
|
|
; CHECK: abs.f64 %fl0, %fl0;
|
|
; CHECK: ret;
|
|
%x = call double @llvm.fabs.f64(double %d)
|
|
ret double %x
|
|
}
|
|
|
|
declare float @llvm.fabs.f32(float)
|
|
declare double @llvm.fabs.f64(double)
|