added back cuda.h includes to fix missing CUDA_VERSION
authorSzilard Pall <pszilard@cbr.su.se>
Thu, 24 Jan 2013 01:27:09 +0000 (02:27 +0100)
committerSzilard Pall <pszilard@cbr.su.se>
Thu, 24 Jan 2013 18:49:11 +0000 (19:49 +0100)
nvcc doesn't define its version identity macro, CUDA_VERSION, by default,
but this needs to be pulled in through cuda.h. Quite weird and
non-standard behavior, but as swithing to legacy kernels and certain
kernel optimizations are broken now, to fix these we need to include
cuda.h.

Change-Id: I4836335e97a287e18e595c160819db2e46a8d798

src/mdlib/nbnxn_cuda/nbnxn_cuda.cu
src/mdlib/nbnxn_cuda/nbnxn_cuda_data_mgmt.cu

index f36104a618b3c2099812c74ba15669cd07bb101c..6d27e77486abd8a082103a34c634e609eeb52f49 100644 (file)
@@ -43,6 +43,8 @@
 #include <limits>
 #endif
 
+#include <cuda.h>
+
 #include "types/simple.h" 
 #include "types/nbnxn_pairlist.h"
 #include "types/nb_verlet.h"
index f9f9bfa2c386304d116109e1a5b687573f7879ee..d5074d2f38ae6120d2b337cd3c4f1f01876639c9 100644 (file)
@@ -43,6 +43,8 @@
 #include <stdio.h>
 #include <assert.h>
 
+#include <cuda.h>
+
 #include "gmx_fatal.h"
 #include "smalloc.h"
 #include "tables.h"