summaryrefslogtreecommitdiffstats
path: root/clang/test
diff options
context:
space:
mode:
authorJustin Lebar <jlebar@google.com>2016-12-15 18:44:57 +0000
committerJustin Lebar <jlebar@google.com>2016-12-15 18:44:57 +0000
commit3cf25461e05dcbbb3ef5d2df1e0cbdeb46c31f47 (patch)
tree679fd04c636a4ce2952c2e81a8d225186c879528 /clang/test
parenta97358bc8e8c9a98438d0bae0f863cf8b16c8e2b (diff)
downloadbcm5719-llvm-3cf25461e05dcbbb3ef5d2df1e0cbdeb46c31f47.tar.gz
bcm5719-llvm-3cf25461e05dcbbb3ef5d2df1e0cbdeb46c31f47.zip
[CUDA] Add --ptxas-path= flag.
Summary: This lets you build with one CUDA installation but use ptxas from another install. This is useful e.g. if you want to avoid bugs in an old ptxas without actually upgrading wholesale to a newer CUDA version. Reviewers: tra Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D27788 llvm-svn: 289847
Diffstat (limited to 'clang/test')
-rw-r--r--clang/test/Driver/cuda-ptxas-path.cu12
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/test/Driver/cuda-ptxas-path.cu b/clang/test/Driver/cuda-ptxas-path.cu
new file mode 100644
index 00000000000..3ac5932b067
--- /dev/null
+++ b/clang/test/Driver/cuda-ptxas-path.cu
@@ -0,0 +1,12 @@
+// REQUIRES: clang-driver
+// REQUIRES: x86-registered-target
+// REQUIRES: nvptx-registered-target
+
+// RUN: %clang -### --target=i386-unknown-linux \
+// RUN: --cuda-path=%S/Inputs/CUDA_80/usr/local/cuda \
+// RUN: --ptxas-path=/some/path/to/ptxas %s 2>&1 \
+// RUN: | FileCheck %s
+
+// CHECK-NOT: "ptxas"
+// CHECK: "/some/path/to/ptxas"
+// CHECK-SAME: "--gpu-name" "sm_20"
OpenPOWER on IntegriCloud