diff options
author | Craig Topper <craig.topper@gmail.com> | 2017-02-09 06:10:14 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2017-02-09 06:10:14 +0000 |
commit | 4574226c3fb431865165a574d69fecd6f254d105 (patch) | |
tree | 1b028ffc087914db815d52f9000559bc6ba6b5b1 /clang/test/CodeGen/builtins-x86.c | |
parent | 50f3d1452c2adc16af219879fa1ff2ad8a514af0 (diff) | |
download | bcm5719-llvm-4574226c3fb431865165a574d69fecd6f254d105.tar.gz bcm5719-llvm-4574226c3fb431865165a574d69fecd6f254d105.zip |
[X86] Clzero flag addition and inclusion under znver1
1. Adds the command line flag for clzero.
2. Includes the clzero flag under znver1.
3. Defines the macro for clzero.
4. Adds a new file which has the intrinsic definition for clzero instruction.
Patch by Ganesh Gopalasubramanian with some additional tests from me.
Differential revision: https://reviews.llvm.org/D29386
llvm-svn: 294559
Diffstat (limited to 'clang/test/CodeGen/builtins-x86.c')
-rw-r--r-- | clang/test/CodeGen/builtins-x86.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/test/CodeGen/builtins-x86.c b/clang/test/CodeGen/builtins-x86.c index ec8a8bf868c..0086f7079dd 100644 --- a/clang/test/CodeGen/builtins-x86.c +++ b/clang/test/CodeGen/builtins-x86.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -DUSE_64 -triple x86_64-unknown-unknown -target-feature +fxsr -target-feature +avx -target-feature +xsaveopt -target-feature +xsaves -target-feature +xsavec -target-feature +mwaitx -emit-llvm -o %t %s -// RUN: %clang_cc1 -DUSE_ALL -triple x86_64-unknown-unknown -target-feature +fxsr -target-feature +avx -target-feature +xsaveopt -target-feature +xsaves -target-feature +xsavec -target-feature +mwaitx -fsyntax-only -o %t %s +// RUN: %clang_cc1 -DUSE_64 -triple x86_64-unknown-unknown -target-feature +fxsr -target-feature +avx -target-feature +xsaveopt -target-feature +xsaves -target-feature +xsavec -target-feature +mwaitx -target-feature +clzero -emit-llvm -o %t %s +// RUN: %clang_cc1 -DUSE_ALL -triple x86_64-unknown-unknown -target-feature +fxsr -target-feature +avx -target-feature +xsaveopt -target-feature +xsaves -target-feature +xsavec -target-feature +mwaitx -target-feature +clzero -fsyntax-only -o %t %s #ifdef USE_ALL #define USE_3DNOW @@ -285,6 +285,7 @@ void f0() { (void) __builtin_ia32_monitorx(tmp_vp, tmp_Ui, tmp_Ui); (void) __builtin_ia32_mwaitx(tmp_Ui, tmp_Ui, tmp_Ui); + (void) __builtin_ia32_clzero(tmp_vp); tmp_V4f = __builtin_ia32_cvtpi2ps(tmp_V4f, tmp_V2i); tmp_V2i = __builtin_ia32_cvtps2pi(tmp_V4f); |