Skip to content

Commit

Permalink
[CUDA] Enable existing builtins for PTX7.0 as well.
Browse files Browse the repository at this point in the history
Differential Revision: https://reviews.llvm.org/D79515
  • Loading branch information
Artem-B committed May 6, 2020
1 parent 9bb9ff0 commit 314f99e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 4 additions & 1 deletion clang/include/clang/Basic/BuiltinsNVPTX.def
Expand Up @@ -34,7 +34,9 @@
#pragma push_macro("PTX63")
#pragma push_macro("PTX64")
#pragma push_macro("PTX65")
#define PTX65 "ptx65"
#pragma push_macro("PTX70")
#define PTX70 "ptx70"
#define PTX65 "ptx65|" PTX70
#define PTX64 "ptx64|" PTX65
#define PTX63 "ptx63|" PTX64
#define PTX61 "ptx61|" PTX63
Expand Down Expand Up @@ -731,3 +733,4 @@ TARGET_BUILTIN(__imma_m8n8k32_st_c_i32, "vi*iC*UiIi", "", AND(SM_75,PTX63))
#pragma pop_macro("PTX63")
#pragma pop_macro("PTX64")
#pragma pop_macro("PTX65")
#pragma pop_macro("PTX70")
4 changes: 4 additions & 0 deletions clang/test/CodeGen/builtins-nvptx-ptx60.cu
Expand Up @@ -6,6 +6,10 @@
// RUN: -fcuda-is-device -target-feature +ptx65 \
// RUN: -S -emit-llvm -o - -x cuda %s \
// RUN: | FileCheck -check-prefix=CHECK %s
// RUN: %clang_cc1 -triple nvptx64-unknown-unknown -target-cpu sm_80 \
// RUN: -fcuda-is-device -target-feature +ptx70 \
// RUN: -S -emit-llvm -o - -x cuda %s \
// RUN: | FileCheck -check-prefix=CHECK %s
// RUN: %clang_cc1 -triple nvptx-unknown-unknown -target-cpu sm_60 \
// RUN: -fcuda-is-device -S -o /dev/null -x cuda -verify %s

Expand Down

0 comments on commit 314f99e

Please sign in to comment.