[CUDA] Fix two failed test cases using --cuda-path-ignore-env
authorJiading Gai <jiading.gai@gmail.com>
Wed, 26 Sep 2018 07:07:48 +0000 (07:07 +0000)
committerJiading Gai <jiading.gai@gmail.com>
Wed, 26 Sep 2018 07:07:48 +0000 (07:07 +0000)
Add --cuda-path-ignore-env option to those test cases to ensure the clang
driver always pick the CUDA path specified by --sysroot.

Reviewers: tra, Hahnfeld

Differential Revision: https://reviews.llvm.org/D52259

llvm-svn: 343075

clang/test/Driver/cuda-detect.cu
clang/test/Driver/cuda-macosx.cu

index 9d5a47a2ecaad14ce3788e28ba0fd10028e559cb..e5dfe36571a79f9578b8fabb47c13d8f02d6d131 100644 (file)
@@ -14,9 +14,9 @@
 
 
 // RUN: %clang -v --target=i386-unknown-linux \
-// RUN:   --sysroot=%S/Inputs/CUDA 2>&1 | FileCheck %s
+// RUN:   --sysroot=%S/Inputs/CUDA --cuda-path-ignore-env 2>&1 | FileCheck %s
 // RUN: %clang -v --target=i386-apple-macosx \
-// RUN:   --sysroot=%S/Inputs/CUDA 2>&1 | FileCheck %s
+// RUN:   --sysroot=%S/Inputs/CUDA --cuda-path-ignore-env 2>&1 | FileCheck %s
 
 // RUN: %clang -v --target=i386-unknown-linux \
 // RUN:   --cuda-path=%S/Inputs/CUDA/usr/local/cuda 2>&1 | FileCheck %s
index ad0bcf756e31cc2582c788bcee4e72b6910f31bf..a4700a3b81d820a524c0cf031325665bafafe5c0 100644 (file)
@@ -3,6 +3,6 @@
 // REQUIRES: nvptx-registered-target
 //
 // RUN: %clang -v --target=i386-apple-macosx \
-// RUN:   --sysroot=%S/Inputs/CUDA-macosx 2>&1 | FileCheck %s
+// RUN:   --sysroot=%S/Inputs/CUDA-macosx --cuda-path-ignore-env 2>&1 | FileCheck %s
 
 // CHECK: Found CUDA installation: {{.*}}/Inputs/CUDA-macosx/usr/local/cuda