From: Daniel Arndt Date: Wed, 24 Apr 2019 22:54:12 +0000 (+0200) Subject: Add more assertions X-Git-Tag: v9.1.0-rc1~33^2~8 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7347d1d42059ba5720ca3af1a0f19272683fd3fc;p=dealii.git Add more assertions --- diff --git a/include/deal.II/lac/vector_operations_internal.h b/include/deal.II/lac/vector_operations_internal.h index d7ff76dd36..0c43a4aef3 100644 --- a/include/deal.II/lac/vector_operations_internal.h +++ b/include/deal.II/lac/vector_operations_internal.h @@ -2389,6 +2389,13 @@ namespace internal static_cast( size)); +# ifdef DEBUG + // Check that the kernel was launched correctly + AssertCuda(cudaGetLastError()); + // Check that there was no problem during the execution of the kernel + AssertCuda(cudaDeviceSynchronize()); +# endif + // Copy the result back to the host Number result; error_code = cudaMemcpy(&result,