]> granicus.if.org Git - clang/commit
[CUDA] Add option to generate relocatable device code
authorJonas Hahnfeld <hahnjo@hahnjo.de>
Mon, 12 Feb 2018 10:46:45 +0000 (10:46 +0000)
committerJonas Hahnfeld <hahnjo@hahnjo.de>
Mon, 12 Feb 2018 10:46:45 +0000 (10:46 +0000)
commit323eab799c2633e8d820d6edd58698287470be53
treebff3a3d176734be116cd5236f2b1e74b64ab5898
parent39066f21f0102a53206598d87e83b6acfdf9bee4
[CUDA] Add option to generate relocatable device code

As a first step, pass '-c/--compile-only' to ptxas so that it
doesn't complain about references to external function. This
will successfully generate object files, but they won't work
at runtime because the registration routines need to adapted.

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

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@324878 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Basic/LangOptions.def
include/clang/Driver/Options.td
lib/Driver/ToolChains/Clang.cpp
lib/Driver/ToolChains/Cuda.cpp
lib/Frontend/CompilerInvocation.cpp
test/Driver/cuda-external-tools.cu