diff options
author | svnmir <svnmir@FreeBSD.org> | 2015-08-07 23:02:56 +0000 |
---|---|---|
committer | svnmir <svnmir@FreeBSD.org> | 2015-08-07 23:02:56 +0000 |
commit | 6416b56f5a3923c6c264b46365e16718ccabf081 (patch) | |
tree | ca13cf9e2e8c2499f61f1246e455efd2804abd36 /lib/Driver/Action.cpp | |
parent | e7bcad327814a78ecb8d5f5545d2e3df84c67a5c (diff) | |
download | FreeBSD-src-6416b56f5a3923c6c264b46365e16718ccabf081.zip FreeBSD-src-6416b56f5a3923c6c264b46365e16718ccabf081.tar.gz |
Vendor import of clang trunk r242221:
https://llvm.org/svn/llvm-project/cfe/trunk@242221
Diffstat (limited to 'lib/Driver/Action.cpp')
-rw-r--r-- | lib/Driver/Action.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/lib/Driver/Action.cpp b/lib/Driver/Action.cpp index 360dbee..3219dc1 100644 --- a/lib/Driver/Action.cpp +++ b/lib/Driver/Action.cpp @@ -24,6 +24,8 @@ const char *Action::getClassName(ActionClass AC) { switch (AC) { case InputClass: return "input"; case BindArchClass: return "bind-arch"; + case CudaDeviceClass: return "cuda-device"; + case CudaHostClass: return "cuda-host"; case PreprocessJobClass: return "preprocessor"; case PrecompileJobClass: return "precompiler"; case AnalyzeJobClass: return "analyzer"; @@ -53,6 +55,25 @@ BindArchAction::BindArchAction(std::unique_ptr<Action> Input, const char *_ArchName) : Action(BindArchClass, std::move(Input)), ArchName(_ArchName) {} +void CudaDeviceAction::anchor() {} + +CudaDeviceAction::CudaDeviceAction(std::unique_ptr<Action> Input, + const char *ArchName, bool AtTopLevel) + : Action(CudaDeviceClass, std::move(Input)), GpuArchName(ArchName), + AtTopLevel(AtTopLevel) {} + +void CudaHostAction::anchor() {} + +CudaHostAction::CudaHostAction(std::unique_ptr<Action> Input, + const ActionList &_DeviceActions) + : Action(CudaHostClass, std::move(Input)), DeviceActions(_DeviceActions) {} + +CudaHostAction::~CudaHostAction() { + for (iterator it = DeviceActions.begin(), ie = DeviceActions.end(); it != ie; + ++it) + delete *it; +} + void JobAction::anchor() {} JobAction::JobAction(ActionClass Kind, std::unique_ptr<Action> Input, |