aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/X86/pr13577.ll
blob: a6b721a7a6f17ed2611e4b24e21c53dc7bcb5581 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
; RUN: llc < %s -mtriple=x86_64-darwin | FileCheck %s

; CHECK-LABEL: LCPI0_0:
; CHECK-NEXT: .long 4286578688
; CHECK-LABEL: LCPI0_1:
; CHECK-NEXT: .long 2139095040

; CHECK-LABEL: foo:
; CHECK: movq {{.*}}, %rax
; CHECK: shlq $48, %rax
; CHECK: sets %al
; CHECK: testb %al, %al
; CHECK: flds LCPI0_0(%rip)
; CHECK: flds LCPI0_1(%rip)
; CHECK: fcmovne %st(1), %st(0)
; CHECK: fstp %st(1)
; CHECK: retq
define x86_fp80 @foo(x86_fp80 %a) {
  %1 = tail call x86_fp80 @copysignl(x86_fp80 0xK7FFF8000000000000000, x86_fp80 %a) nounwind readnone
  ret x86_fp80 %1
}

declare x86_fp80 @copysignl(x86_fp80, x86_fp80) nounwind readnone