summaryrefslogtreecommitdiffstats
path: root/Tests/Cuda/Complex/dynamic.cu
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/Cuda/Complex/dynamic.cu')
-rw-r--r--Tests/Cuda/Complex/dynamic.cu12
1 files changed, 5 insertions, 7 deletions
diff --git a/Tests/Cuda/Complex/dynamic.cu b/Tests/Cuda/Complex/dynamic.cu
index 9540e86..ea52acb 100644
--- a/Tests/Cuda/Complex/dynamic.cu
+++ b/Tests/Cuda/Complex/dynamic.cu
@@ -1,6 +1,7 @@
#include <string>
#include <cuda.h>
+#include <iostream>
int dynamic_base_func(int);
@@ -15,15 +16,12 @@ void DetermineIfValidCudaDevice()
{
}
-void cuda_dynamic_lib_func(std::string& contents )
+void cuda_dynamic_lib_func()
{
DetermineIfValidCudaDevice <<<1,1>>> ();
- if(cudaSuccess == cudaGetLastError())
+ cudaError_t err = cudaGetLastError();
+ if(err == cudaSuccess)
{
- contents = "ran a cuda kernel";
- }
- else
- {
- contents = "cant run a cuda kernel";
+ std::cerr << cudaGetErrorString(err) << std::endl;
}
}