Commit 7fd9950c authored by Robert Maynard's avatar Robert Maynard Committed by Kitware Robot
Browse files

Merge topic 'disable_assert_cuda_75'

a75c6ae4

 Automatically disable assert for CUDA 7.5 as they don't work in device code
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Acked-by: Matt Larsen's avatarMatt Larsen <mlarsen@cs.uoregon.edu>
Merge-request: !1105
parents 65077ad1 a75c6ae4
......@@ -38,7 +38,11 @@
///
/// The VTKM_NO_ASSERT cmake and preprocessor option allows debugging builds
/// to remove assertions for performance reasons.
#if !defined(NDEBUG) && !defined(VTKM_NO_ASSERT)
#if defined(VTKM_CUDA_VERSION_MAJOR) && VTKM_CUDA_VERSION_MAJOR == 7
//CUDA 7.5 doesn't support assert in device code
#define VTKM_ASSERT(condition) (void)(condition)
#elif !defined(NDEBUG) && !defined(VTKM_NO_ASSERT)
//Only assert if we are in debug mode and don't have VTKM_NO_ASSERT defined
#define VTKM_ASSERT(condition) assert(condition)
#else
#define VTKM_ASSERT(condition) (void)(condition)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment