]> granicus.if.org Git - clang/commit
[cuda] Driver changes to compile and stitch together host and device-side CUDA code.
authorArtem Belevich <tra@google.com>
Mon, 13 Jul 2015 23:27:56 +0000 (23:27 +0000)
committerArtem Belevich <tra@google.com>
Mon, 13 Jul 2015 23:27:56 +0000 (23:27 +0000)
commitda2d19c6cd6314c73ae2049e3db03b443f01b190
tree7c50941e21c235ef8cbb9695c8337dea572b5c61
parentfcf87ff162da88cda1d2db3cbbfed4efa35f4f9c
[cuda] Driver changes to compile and stitch together host and device-side CUDA code.

  NOTE: reverts r242077 to reinstate r242058, r242065, 242067
        and includes fix for OS X test failures.

  - Changed driver pipeline to compile host and device side of CUDA
    files and incorporate results of device-side compilation into host
    object file.

  - Added a test for cuda pipeline creation in clang driver.

  New clang options:
  --cuda-host-only   - Do host-side compilation only.
  --cuda-device-only - Do device-side compilation only.

  --cuda-gpu-arch=<ARCH> - specify GPU architecture for device-side
    compilation. E.g. sm_35, sm_30. Default is sm_20. May be used more
    than once in which case one device-compilation will be done per
    unique specified GPU architecture.

  Differential Revision: http://reviews.llvm.org/D9509

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@242085 91177308-0d34-0410-b5e6-96231b3b80d8
17 files changed:
include/clang/Driver/Action.h
include/clang/Driver/Options.td
include/clang/Driver/Types.def
include/clang/Driver/Types.h
lib/Driver/Action.cpp
lib/Driver/Driver.cpp
lib/Driver/ToolChain.cpp
lib/Driver/ToolChains.cpp
lib/Driver/ToolChains.h
lib/Driver/Tools.cpp
lib/Driver/Types.cpp
lib/Frontend/CreateInvocationFromCommandLine.cpp
test/Driver/cuda-options.cu [new file with mode: 0644]
test/Index/attributes-cuda.cu
test/Index/index-file.cu [new file with mode: 0644]
tools/libclang/CIndex.cpp
unittests/ASTMatchers/ASTMatchersTest.h