diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2011-10-06 18:29:46 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2011-10-06 18:29:46 +0000 |
commit | d51e43af0b3a6897b971f316c4de2035ec82d1f2 (patch) | |
tree | 2e2a505064edf95a02eda45e47a11be94903f993 /include/clang/Frontend/CodeGenOptions.h | |
parent | 6c0aa5ff6e6253db0f993053599e2a52b5b93b2d (diff) |
CUDA: add -fcuda-is-device flag
This frontend-only flag is used by the IR generator to determine
whether to filter CUDA declarations for the host or for the device.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141301 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Frontend/CodeGenOptions.h')
-rw-r--r-- | include/clang/Frontend/CodeGenOptions.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/clang/Frontend/CodeGenOptions.h b/include/clang/Frontend/CodeGenOptions.h index 5f824f2d71..4874c17c79 100644 --- a/include/clang/Frontend/CodeGenOptions.h +++ b/include/clang/Frontend/CodeGenOptions.h @@ -37,6 +37,7 @@ public: unsigned AsmVerbose : 1; /// -dA, -fverbose-asm. unsigned ObjCAutoRefCountExceptions : 1; /// Whether ARC should be EH-safe. + unsigned CUDAIsDevice : 1; /// Set when compiling for CUDA device. unsigned CXAAtExit : 1; /// Use __cxa_atexit for calling destructors. unsigned CXXCtorDtorAliases: 1; /// Emit complete ctors/dtors as linker /// aliases to base ctors when possible. @@ -143,6 +144,7 @@ public: public: CodeGenOptions() { AsmVerbose = 0; + CUDAIsDevice = 0; CXAAtExit = 1; CXXCtorDtorAliases = 0; DataSections = 0; |