diff options
| author | Artem Belevich <tra@google.com> | 2017-09-21 18:44:49 +0000 |
|---|---|---|
| committer | Artem Belevich <tra@google.com> | 2017-09-21 18:44:49 +0000 |
| commit | 42960b41883a9cc0aed6d1e42c851914893f5600 (patch) | |
| tree | 26f7d407689f505269483c2486e8b9545336ad2c /clang/test/CodeGen/builtins-nvptx.c | |
| parent | ddf524c031947ffd495ff4fda9f78be28b05959f (diff) | |
| download | bcm5719-llvm-42960b41883a9cc0aed6d1e42c851914893f5600.tar.gz bcm5719-llvm-42960b41883a9cc0aed6d1e42c851914893f5600.zip | |
[NVPTX] Implemented bar.warp.sync, barrier.sync, and vote{.sync} instructions/intrinsics/builtins.
Differential Revision: https://reviews.llvm.org/D38148
llvm-svn: 313898
Diffstat (limited to 'clang/test/CodeGen/builtins-nvptx.c')
| -rw-r--r-- | clang/test/CodeGen/builtins-nvptx.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/CodeGen/builtins-nvptx.c b/clang/test/CodeGen/builtins-nvptx.c index c97b549cbe0..89a982377ad 100644 --- a/clang/test/CodeGen/builtins-nvptx.c +++ b/clang/test/CodeGen/builtins-nvptx.c @@ -657,3 +657,15 @@ __device__ void nvvm_shfl(int i, float f, int a, int b) { __nvvm_shfl_idx_f32(f, a, b); // CHECK: ret void } + +__device__ void nvvm_vote(int pred) { + // CHECK: call i1 @llvm.nvvm.vote.all(i1 + __nvvm_vote_all(pred); + // CHECK: call i1 @llvm.nvvm.vote.any(i1 + __nvvm_vote_any(pred); + // CHECK: call i1 @llvm.nvvm.vote.uni(i1 + __nvvm_vote_uni(pred); + // CHECK: call i32 @llvm.nvvm.vote.ballot(i1 + __nvvm_vote_ballot(pred); + // CHECK: ret void +} |

