summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudio10TargetGenerator.cxx
diff options
context:
space:
mode:
authorRobert Maynard <robert.maynard@kitware.com>2017-12-21 22:30:40 (GMT)
committerRobert Maynard <robert.maynard@kitware.com>2018-01-11 18:33:00 (GMT)
commitdcc606ad47d61ab37e7ab520aafabc9731f088f1 (patch)
tree2de36ef6d107b2a11987a9bf7968769b3eae2dc8 /Source/cmVisualStudio10TargetGenerator.cxx
parent1f29bc4092edf57cfb61882d7d7358db7e53ebe6 (diff)
downloadCMake-dcc606ad47d61ab37e7ab520aafabc9731f088f1.zip
CMake-dcc606ad47d61ab37e7ab520aafabc9731f088f1.tar.gz
CMake-dcc606ad47d61ab37e7ab520aafabc9731f088f1.tar.bz2
CUDA: Allow -G to control device debuging on MSVC.
Fixes #17551
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r--Source/cmVisualStudio10TargetGenerator.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index 9154dca..1faff4e 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -2680,6 +2680,12 @@ bool cmVisualStudio10TargetGenerator::ComputeCudaOptions(
cudaOptions.Parse(defineFlags.c_str());
cudaOptions.ParseFinish();
+ // If we haven't explicitly enabled GPU debug information
+ // explicitly disable it
+ if (!cudaOptions.HasFlag("GPUDebugInfo")) {
+ cudaOptions.AddFlag("GPUDebugInfo", "false");
+ }
+
if (this->GeneratorTarget->GetPropertyAsBool("CUDA_SEPARABLE_COMPILATION")) {
cudaOptions.AddFlag("GenerateRelocatableDeviceCode", "true");
} else if (this->GeneratorTarget->GetPropertyAsBool(