summaryrefslogtreecommitdiffstats
path: root/clang/test/Driver/Inputs/CUDA-macosx/usr
diff options
context:
space:
mode:
authorJustin Lebar <jlebar@google.com>2016-11-18 00:41:22 +0000
committerJustin Lebar <jlebar@google.com>2016-11-18 00:41:22 +0000
commit66c4fd7987d216e91d219e5e8437673a7b0167f8 (patch)
treee5db1f8f7dd6d58a09a36a0b8b12363c79371919 /clang/test/Driver/Inputs/CUDA-macosx/usr
parent25a41c1f630c5ad29ce7180a06d737118cead85a (diff)
downloadbcm5719-llvm-66c4fd7987d216e91d219e5e8437673a7b0167f8.tar.gz
bcm5719-llvm-66c4fd7987d216e91d219e5e8437673a7b0167f8.zip
[CUDA] Driver changes to support CUDA compilation on MacOS.
Summary: Compiling CUDA device code requires us to know the host toolchain, because CUDA device-side compiles pull in e.g. host headers. When we only supported Linux compilation, this worked because CudaToolChain, which is responsible for device-side CUDA compilation, inherited from the Linux toolchain. But in order to support MacOS, CudaToolChain needs to take a HostToolChain pointer. Because a CUDA toolchain now requires a host TC, we no longer will create a CUDA toolchain from Driver::getToolChain -- you have to go through CreateOffloadingDeviceToolChains. I am *pretty* sure this is correct, and that previously any attempt to create a CUDA toolchain through getToolChain() would eventually have resulted in us throwing "error: unsupported use of NVPTX for host compilation". In any case hacking getToolChain to create a CUDA+host toolchain would be wrong, because a Driver can be reused for multiple compilations, potentially with different host TCs, and getToolChain will cache the result, causing us to potentially use a stale host TC. So that's the main change in this patch. In addition, we have to pull CudaInstallationDetector out of Generic_GCC and into a top-level class. It's now used by the Generic_GCC and MachO toolchains. Reviewers: tra Subscribers: rryan, hfinkel, sfantao Differential Revision: https://reviews.llvm.org/D26774 llvm-svn: 287285
Diffstat (limited to 'clang/test/Driver/Inputs/CUDA-macosx/usr')
-rw-r--r--clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/bin/.keep0
-rw-r--r--clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/include/.keep0
-rw-r--r--clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/lib/.keep0
-rw-r--r--clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_30.10.bc0
-rw-r--r--clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_35.10.bc0
5 files changed, 0 insertions, 0 deletions
diff --git a/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/bin/.keep b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/bin/.keep
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/bin/.keep
diff --git a/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/include/.keep b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/include/.keep
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/include/.keep
diff --git a/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/lib/.keep b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/lib/.keep
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/lib/.keep
diff --git a/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_30.10.bc b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_30.10.bc
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_30.10.bc
diff --git a/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_35.10.bc b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_35.10.bc
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/clang/test/Driver/Inputs/CUDA-macosx/usr/local/cuda/nvvm/libdevice/libdevice.compute_35.10.bc
OpenPOWER on IntegriCloud