diff options
author | Eric Christopher <echristo@gmail.com> | 2015-04-29 23:32:17 +0000 |
---|---|---|
committer | Eric Christopher <echristo@gmail.com> | 2015-04-29 23:32:17 +0000 |
commit | fb481a40544adc6a06ef3594f13ce818e7ad50f8 (patch) | |
tree | e42a88c50ca18112cd81836a7025dfbf9ae8f443 /clang/test/CodeGen/function-target-features.c | |
parent | 3d5925b0e4c86a4f808dcd1061984e2165a54a9d (diff) | |
download | bcm5719-llvm-fb481a40544adc6a06ef3594f13ce818e7ad50f8.tar.gz bcm5719-llvm-fb481a40544adc6a06ef3594f13ce818e7ad50f8.zip |
Propagate a terrible hack to the sparc target feature handling code
by erasing the soft-float target feature if the rest of the front
end added it because of defaults or the soft float option.
Add some testing for some of the targets that implement this hack.
llvm-svn: 236179
Diffstat (limited to 'clang/test/CodeGen/function-target-features.c')
-rw-r--r-- | clang/test/CodeGen/function-target-features.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/test/CodeGen/function-target-features.c b/clang/test/CodeGen/function-target-features.c index 4f8265d7343..b6cd4ca7a6d 100644 --- a/clang/test/CodeGen/function-target-features.c +++ b/clang/test/CodeGen/function-target-features.c @@ -9,6 +9,9 @@ // RUN: %clang_cc1 -triple x86_64-unknown-unknown -emit-llvm -o - %s -target-cpu corei7 -target-feature +avx | FileCheck %s -check-prefix=CORE-CPU-AND-FEATURES // RUN: %clang_cc1 -triple x86_64-unknown-unknown -emit-llvm -o - %s -target-cpu x86-64 | FileCheck %s -check-prefix=X86-64-CPU // RUN: %clang_cc1 -triple x86_64-unknown-unknown -emit-llvm -o - %s -target-cpu corei7-avx -target-feature -avx | FileCheck %s -check-prefix=AVX-MINUS-FEATURE +// RUN: %clang_cc1 -triple sparc-unknown-unknown -emit-llvm -o - %s -target-feature +soft-float | FileCheck %s -check-prefix=SOFT-FLOAT +// RUN: %clang_cc1 -triple arm-unknown-unknown -emit-llvm -o - %s -target-feature +soft-float | FileCheck %s -check-prefix=SOFT-FLOAT +// RUN: %clang_cc1 -triple mips-unknown-unknown -emit-llvm -o - %s -target-feature +soft-float | FileCheck %s -check-prefix=SOFT-FLOAT void foo() {} @@ -19,3 +22,4 @@ void foo() {} // CORE-CPU-AND-FEATURES: "target-cpu"="corei7" "target-features"={{.*}}+avx // X86-64-CPU: "target-cpu"="x86-64" // AVX-MINUS-FEATURE: "target-features"={{.*}}-avx +// SOFT-FLOAT-NOT: "target-features"={{.*}}+soft-float |