mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-26 05:32:25 +00:00
11ae250ec9
We now consider the FPOpFusion flag when determining whether to fuse ops. We also explicitly emit add.rn when fusion is disabled to prevent ptxas from fusing the operations on its own. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@213287 91177308-0d34-0410-b5e6-96231b3b80d8
22 lines
690 B
LLVM
22 lines
690 B
LLVM
; RUN: llc < %s -march=nvptx -mcpu=sm_20 -fp-contract=fast | FileCheck %s
|
|
|
|
target triple = "nvptx64-unknown-cuda"
|
|
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v16:16:16-v32:32:32-v64:64:64-v128:128:128-n16:32:64"
|
|
|
|
; Make sure we can properly differentiate between single-precision and
|
|
; double-precision FP literals.
|
|
|
|
; CHECK: myaddf
|
|
; CHECK: add.f32 %f{{[0-9]+}}, %f{{[0-9]+}}, 0f3F800000
|
|
define float @myaddf(float %a) {
|
|
%ret = fadd float %a, 1.0
|
|
ret float %ret
|
|
}
|
|
|
|
; CHECK: myaddd
|
|
; CHECK: add.f64 %fd{{[0-9]+}}, %fd{{[0-9]+}}, 0d3FF0000000000000
|
|
define double @myaddd(double %a) {
|
|
%ret = fadd double %a, 1.0
|
|
ret double %ret
|
|
}
|