Home | History | Annotate | Download | only in CodeGen
      1 // RUN: %clang_cc1 -triple x86_64-linux-gnu -target-cpu x86-64 -emit-llvm %s -o - | FileCheck %s -check-prefix=CHECK -check-prefix=HARD
      2 // RUN: %clang_cc1 -msoft-float -triple x86_64-linux-gnu -target-cpu x86-64 -emit-llvm %s -o - | FileCheck %s -check-prefix=CHECK -check-prefix=SOFT
      3 
      4 int __attribute__((target("x87"))) foo(int a) { return 4; }
      5 int __attribute__((target("no-x87"))) bar(int a) { return 4; }
      6 
      7 // CHECK: foo{{.*}} #0
      8 // CHECK: bar{{.*}} #1
      9 
     10 // CHECK: #0 = {{.*}}"target-cpu"="x86-64" "target-features"="+fxsr,+mmx,+sse,+sse2,+x87"
     11 // HARD: "use-soft-float"="false"
     12 // SOFT: "use-soft-float"="true"
     13 
     14 // CHECK: #1 = {{.*}}"target-cpu"="x86-64" "target-features"="+fxsr,+mmx,+sse,+sse2,-x87"
     15 // HARD: "use-soft-float"="false"
     16 // SOFT: "use-soft-float"="true"
     17