Commit f1bb8063 authored by Allison Vacanti's avatar Allison Vacanti Committed by Kitware Robot
Browse files

Merge topic 'use_thrust_swap'

cc631650

 Use thrust::swap for vtkm::Swap in CUDA device code.
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Acked-by: default avatarRobert Maynard <robert.maynard@kitware.com>
Merge-request: !1260
parents 7158d56c cc631650
......@@ -23,7 +23,11 @@
#include <vtkm/internal/ExportMacros.h>
#ifdef __CUDACC__
#include <thrust/swap.h>
#else
#include <algorithm>
#endif
namespace vtkm
{
......@@ -33,9 +37,8 @@ namespace vtkm
template <typename T>
VTKM_EXEC_CONT void Swap(T& a, T& b)
{
T tmp = a;
a = b;
b = tmp;
using namespace thrust;
swap(a, b);
}
#else
template <typename T>
......
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