<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="gmail_quote"><div>if you want to get the new native gpu feature you need no special cmake flags so </div>
<div>cmake .</div><div>should work. But I got confused when claiming you should get release-4-6. Instead you need to get:</div>
<div>git fetch <a href="https://gerrit.gromacs.org/gromacs" target="_blank">https://gerrit.gromacs.org/gromacs</a> refs/changes/84/1284/14 && git checkout FETCH_HEAD</div><div>(for other download options see <a href="https://gerrit.gromacs.org/#/c/1284/" target="_blank">https://gerrit.gromacs.org/#/c/1284/</a>)</div>
<div>It will be in 4.6 but is not (quite) in it yet.</div><div>As far as I know the OpenMM GPU option hasn't been updated for 4.6 and thus for OpenMM you could as well use the 4.5 version.</div><br></div></blockquote>
<div><br>OK, here's what I did:<br><br>$git clone <a href="https://gerrit.gromacs.org/gromacs">https://gerrit.gromacs.org/gromacs</a><br>$cd gromacs<br>$git fetch <a href="https://gerrit.gromacs.org/gromacs">https://gerrit.gromacs.org/gromacs</a> refs/changes/84/1284/14 && git checkout FETCH_HEAD<br>
$cd ../<br>$mkdir gromacs_cuda_build<br>$cd gromacs_cuda_build<br>$cmake ../gromacs<br>-- The C compiler identification is GNU 4.7.0<br>-- The CXX compiler identification is GNU 4.7.0<br>.....<br>.....<br>-- checking for module 'fftw3f'<br>
-- package 'fftw3f' not found<br>Could not find fftw3f library named libfftw3f, please specify its location in FFTW_LIBRARY by hand (e.g. -DFFTW_LIBRARY='/path/to/libfftw3f.so')<br>CMake Error at CMakeLists.txt:863 (MESSAGE):<br>
Cannot find FFTW3 (with correct precision - libfftw3f for single precision<br> GROMACS or libfftw3 for double precision GROMACS). Fix it, choose another<br> FFT library, or use the Gromacs built-in fftpack (slower)! <br>
<br>These are the only files that match the pattern "libfftw3f.so":<br>/usr/lib64/libfftw3f.so.3<br>/usr/lib64/libfftw3f.so.3.3.1<br><br>So I reran cmake using:<br><br>$cmake ../gromacs -DFFTW_LIBRARY='/usr/lib64/libfftw3f.so.3'<br>
Could not the fftw3f header fftw3.h, please specify its path in FFTW_INCLUDE_DIR by hand (e.g. -DFFTW_INCLUDE_DIR='/path/to/include')<br>CMake Error at CMakeLists.txt:863 (MESSAGE):<br> Cannot find FFTW3 (with correct precision - libfftw3f for single precision<br>
GROMACS or libfftw3 for double precision GROMACS). Fix it, choose another<br> FFT library, or use the Gromacs built-in fftpack (slower)!<br><br>Finally I added another flag to designate the FFTW include folder:<br><br>
$ cmake ../gromacs -DFFTW_LIBRARY='/usr/lib64/libfftw3f.so.3' -DFFTW_INCLUDE_DIR='/home/thomas/Programs/fftw-3.3.2/single_precision_installation_dir/include'<br>-- Looking for fftwf_plan_r2r_1d in /usr/lib64/libfftw3f.so.3<br>
-- Looking for fftwf_plan_r2r_1d in /usr/lib64/libfftw3f.so.3 - found<br>-- Looking for fftwf_have_simd_sse2 in /usr/lib64/libfftw3f.so.3<br>-- Looking for fftwf_have_simd_sse2 in /usr/lib64/libfftw3f.so.3 - not found<br>
-- Looking for fftw_have_simd_sse2 in /usr/lib64/libfftw3f.so.3<br>-- Looking for fftw_have_simd_sse2 in /usr/lib64/libfftw3f.so.3 - not found<br>-- Looking for fftwf_have_sse in /usr/lib64/libfftw3f.so.3<br>-- Looking for fftwf_have_sse in /usr/lib64/libfftw3f.so.3 - not found<br>
-- Looking for fftw_have_sse2 in /usr/lib64/libfftw3f.so.3<br>-- Looking for fftw_have_sse2 in /usr/lib64/libfftw3f.so.3 - not found<br>-- Using internal BLAS library<br>-- LAPACK requires BLAS<br>-- Using internal LAPACK library<br>
-- Checking for dlopen<br>-- Performing Test HAVE_DLOPEN<br>-- Performing Test HAVE_DLOPEN - Success<br>-- Checking for dlopen - found<br>-- Found the ability to use plug-ins when building shared libaries, so will compile to use plug-ins (e.g. to read VMD-supported file formats).<br>
-- Checking for suitable VMD version<br>-- VMD plugins not found. Path to VMD can be set with VMDDIR.<br>-- Configuring done<br>-- Generating done<br>-- Build files have been written to: /home/thomas/Programs/gromacs_cuda_build<br>
<br>Then I did:<br><br>$ make mdrun<br>[ 0%] Building NVCC (Device) object src/mdlib/nbnxn_cuda/CMakeFiles/nbnxn_cuda.dir//./nbnxn_cuda_generated_nbnxn_cuda_data_mgmt.cu.o<br>cc1plus: error: invalid option `avx'<br>cc1plus: error: unrecognized command line option "-fexcess-precision=fast"<br>
CMake Error at nbnxn_cuda_generated_nbnxn_cuda_data_mgmt.cu.o.cmake:198 (message):<br> Error generating<br> /home/thomas/Programs/gromacs_cuda_build/src/mdlib/nbnxn_cuda/CMakeFiles/nbnxn_cuda.dir//./nbnxn_cuda_generated_nbnxn_cuda_data_mgmt.cu.o<br>
<br><br>make[3]: *** [src/mdlib/nbnxn_cuda/CMakeFiles/nbnxn_cuda.dir/./nbnxn_cuda_generated_nbnxn_cuda_data_mgmt.cu.o] Error 1<br>make[2]: *** [src/mdlib/nbnxn_cuda/CMakeFiles/nbnxn_cuda.dir/all] Error 2<br>make[1]: *** [src/kernel/CMakeFiles/mdrun.dir/rule] Error 2<br>
make: *** [mdrun] Error 2<br><br>I corrected them both by doing:<br><br>$for fname in $(grep -lR "\-fexcess\-precision=fast" *); do perl -pi -e "s/\-fexcess\-precision=fast//g" $fname; done<br>$for fname in $(grep -lR "\-mavx" *); do perl -pi -e "s/\-mavx//g" $fname; done<br>
<br>And after that hell was unleashed again:<br><br>$ make mdrun<br>-- Configuring done<br>-- Generating done<br>-- Build files have been written to: /home/thomas/Programs/gromacs_cuda_build<br>[ 0%] Building NVCC (Device) object src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//./gpu_utils_generated_gpu_utils.cu.o<br>
[ 0%] Building NVCC (Device) object src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//./gpu_utils_generated_memtestG80_core.cu.o<br>Scanning dependencies of target gpu_utils<br>Linking CXX static library libgpu_utils.a<br>[ 0%] Built target gpu_utils<br>
Scanning dependencies of target gmx_version<br>[ 0%] Generating version information<br>[ 0%] Built target gmx_version<br>[ 0%] Building NVCC (Device) object src/gmxlib/cuda_tools/CMakeFiles/cuda_tools.dir//./cuda_tools_generated_cudautils.cu.o<br>
/home/thomas/Programs/gromacs/src/gmxlib/cuda_tools/<a href="http://cudautils.cu">cudautils.cu</a>: In function `void cu_realloc_buffered(void**, void*, size_t, int*, int*, int, CUstream_st*, gmx_bool)':<br>/home/thomas/Programs/gromacs/src/gmxlib/cuda_tools/<a href="http://cudautils.cu:293">cudautils.cu:293</a>: warning: converting to `int' from `double'<br>
[ 0%] Building NVCC (Device) object src/gmxlib/cuda_tools/CMakeFiles/cuda_tools.dir//./cuda_tools_generated_pmalloc_cuda.cu.o<br>Scanning dependencies of target cuda_tools<br>Linking CXX static library libcuda_tools.a<br>
[ 0%] Built target cuda_tools<br>Scanning dependencies of target gmx<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/txtdump.c.o<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/tcontrol.c.o<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/sighandler.c.o<br>
[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/random.c.o<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/trnio.c.o<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/gmx_arpack.c.o<br>[ 0%] Building C object src/gmxlib/CMakeFiles/gmx.dir/sparsematrix.c.o<br>
[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/gmx_random.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/sortwater.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/string2.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/matio.c.o<br>
[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/writeps.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/names.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/xdrd.c.o<br>[ 1%] Building C object src/gmxlib/CMakeFiles/gmx.dir/bondfree.c.o<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:27:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_x86_avx_256.h:136:37: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_x86_avx_256.h:145:40: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_x86_avx_256.h:155:37: error: unknown type name __m256d<br>/home/thomas/Programs/gromacs/include/gmx_x86_avx_256.h:164:40: error: unknown type name __m256d<br>
/home/thomas/Programs/gromacs/include/gmx_x86_avx_256.h:175:40: error: unknown type name __m256i<br>In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:41:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:41:22: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:66:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:66:19: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:97:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:97:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:119:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:119:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:136:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:136:18: error: unknown type name __m256<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:330:1: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:330:19: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_exp2_ps:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:412:5: warning: implicit declaration of function _mm_round_ps [-Wimplicit-function-declaration]<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:412:30: error: _MM_FROUND_TO_NEAREST_INT undeclared (first use in this function)<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:412:30: note: each undeclared identifier is reported only once for each function it appears in<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:448:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:448:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_exp_ps:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:546:30: error: _MM_FROUND_TO_NEAREST_INT undeclared (first use in this function)<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:581:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:581:18: error: unknown type name __m256<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_erf_ps:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:894:5: warning: implicit declaration of function _mm_blendv_ps [-Wimplicit-function-declaration]<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:894:14: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:899:14: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:903:9: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:913:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:913:19: error: unknown type name __m256<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_erfc_ps:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1224:14: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1229:14: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1233:9: error: incompatible types when assigning to type __m128 from type int<br>In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br>
from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1309:1: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1309:23: error: unknown type name __m256<br>In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1438:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1438:23: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1532:21: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1533:21: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1534:21: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_sincos_ps:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1677:24: error: _MM_FROUND_TO_ZERO undeclared (first use in this function)<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1710:13: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1711:13: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1719:13: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1720:13: error: incompatible types when assigning to type __m128 from type int<br>
In file included from /home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:28:0,<br> from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1733:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1733:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1754:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1754:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1771:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1771:18: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1798:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1798:19: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1934:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1934:19: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_acos_ps:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1990:7: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1997:7: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:1998:7: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2005:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2005:19: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: In function gmx_mm_atan_ps:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2090:7: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2092:7: error: incompatible types when assigning to type __m128 from type int<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2093:7: error: incompatible types when assigning to type __m128 from type int<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h: At top level:<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2117:1: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2117:20: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_math_x86_avx_256_single.h:2117:30: error: unknown type name __m256<br>In file included from /home/thomas/Programs/gromacs/src/gmxlib/bondfree.c:60:0:<br>/home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:61:1: error: unknown type name __m256<br>
/home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:61:23: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:61:34: error: unknown type name __m256<br>/home/thomas/Programs/gromacs/include/gmx_x86_simd_single.h:61:45: error: unknown type name __m256<br>
make[3]: *** [src/gmxlib/CMakeFiles/gmx.dir/bondfree.c.o] Error 1<br>make[2]: *** [src/gmxlib/CMakeFiles/gmx.dir/all] Error 2<br>make[1]: *** [src/kernel/CMakeFiles/mdrun.dir/rule] Error 2<br>make: *** [mdrun] Error 2<br>
</div></div>