Home | History | Annotate | Download | only in X86
      1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
      2 ; RUN: llc < %s -mtriple=x86_64-darwin | FileCheck %s
      3 
      4 ; CHECK-LABEL: LCPI0_0:
      5 ; CHECK-NEXT: .long 4286578688
      6 ; CHECK-LABEL: LCPI0_1:
      7 ; CHECK-NEXT: .long 2139095040
      8 
      9 define x86_fp80 @foo(x86_fp80 %a) {
     10 ; CHECK-LABEL: foo:
     11 ; CHECK:       ## %bb.0:
     12 ; CHECK-NEXT:    fldt {{[0-9]+}}(%rsp)
     13 ; CHECK-NEXT:    fstpt -{{[0-9]+}}(%rsp)
     14 ; CHECK-NEXT:    testb $-128, -{{[0-9]+}}(%rsp)
     15 ; CHECK-NEXT:    flds {{.*}}(%rip)
     16 ; CHECK-NEXT:    flds {{.*}}(%rip)
     17 ; CHECK-NEXT:    fcmovne %st(1), %st(0)
     18 ; CHECK-NEXT:    fstp %st(1)
     19 ; CHECK-NEXT:    retq
     20   %1 = tail call x86_fp80 @copysignl(x86_fp80 0xK7FFF8000000000000000, x86_fp80 %a) nounwind readnone
     21   ret x86_fp80 %1
     22 }
     23 
     24 declare x86_fp80 @copysignl(x86_fp80, x86_fp80) nounwind readnone
     25 
     26 ; This would crash:
     27 ; https://llvm.org/bugs/show_bug.cgi?id=26070
     28 
     29 define float @pr26070() {
     30 ; CHECK-LABEL: pr26070:
     31 ; CHECK:       ## %bb.0:
     32 ; CHECK-NEXT:    movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
     33 ; CHECK-NEXT:    shufps {{.*#+}} xmm0 = xmm0[0,0,0,0]
     34 ; CHECK-NEXT:    retq
     35   %c = call float @copysignf(float 1.0, float undef) readnone
     36   ret float %c
     37 }
     38 
     39 declare float @copysignf(float, float)
     40 
     41