Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.
7939 Discussions

Regarding gromacs 4.6.5 build failure (mpi compilers)

psing51
New Contributor I
463 Views

Hi,
I am trying to build gromacs 4.6.5 on centos 6.5 (i managed to build gromacs5.x.x with intel) and i am facing compilation issue.
The gromacs team hovewer recommends gnu/openmpi compilers instead of intel!! :
 

-- Generating dependency file: /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//gpu_utils_generated_memtestG80_core.cu.o.NVCC-depend
/home/soft/cuda-6.0/bin/nvcc -M -D__CUDACC__ /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils/memtestG80_core.cu -o /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//gpu_utils_generated_memtestG80_core.cu.o.NVCC-depend -ccbin /home/soft/intel2015/impi/5.0.3.048/intel64/bin/mpiicc -m64 -DHAVE_CONFIG_H -DHAVE_RDTSCP -Xcompiler ,\"-mavx\",\"-Wall\",\"-fPIC\",\"-openmp\",\"-ip\",\"-funroll-all-loops\",\"-O3\",\"-DNDEBUG\" -gencode arch=compute_20,code=sm_20 -gencode arch=compute_20,code=sm_21 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_35,code=compute_35 -use_fast_math -DLINUX -DNVCC -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils -I/home/soft/cuda-6.0/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib -I/home/soft/cuda-6.0/include
icc: command line warning #10006: ignoring unknown option '-dumpspecs'
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../lib64/crt1.o: In function `_start':
(.text+0x20): undefined reference to `main'
CMake Error at gpu_utils_generated_memtestG80_core.cu.o.cmake:206 (message):
  Error generating
  /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//./gpu_utils_generated_memtestG80_core.cu.o


make[2]: *** [src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir/./gpu_utils_generated_memtestG80_core.cu.o] Error 1
make[2]: Leaving directory `/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build'
make[1]: *** [src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir/all] Error 2
make[1]: Leaving directory `/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build'
make: *** [all] Error 2


when i manually executed :

/home/soft/cuda-6.0/bin/nvcc -M -D__CUDACC__ /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils/memtestG80_core.cu -o /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//gpu_utils_generated_memtestG80_core.cu.o.NVCC-depend  -gencode arch=compute_20,code=sm_20 -gencode arch=compute_20,code=sm_21 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_35,code=compute_35 -use_fast_math -DLINUX -DNVCC -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils -I/home/soft/cuda-6.0/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib -I/home/soft/cuda-6.0/include


It worked,
also: replacing mpiicc with gcc worked!!

/home/soft/cuda-6.0/bin/nvcc -M -D__CUDACC__ /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils/memtestG80_core.cu -o /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src/gmxlib/gpu_utils/CMakeFiles/gpu_utils.dir//gpu_utils_generated_memtestG80_core.cu.o.NVCC-depend -ccbin /usr/bin/gcc -m64 -DHAVE_CONFIG_H -DHAVE_RDTSCP -Xcompiler ,\"-mavx\",\"-Wall\",\"-fPIC\",\"-fopenmp\",\"-funroll-all-loops\",\"-O3\",\"-DNDEBUG\" -gencode arch=compute_20,code=sm_20 -gencode arch=compute_20,code=sm_21 -gencode arch=compute_30,code=sm_30 -gencode arch=compute_35,code=sm_35 -gencode arch=compute_35,code=compute_35 -use_fast_math -DLINUX -DNVCC -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils -I/home/soft/cuda-6.0/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/src -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/build/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib -I/home/soft/cuda-6.0/include



seems some issue with mpiicc , is there something i am missing (config flags?), if i replace mpiicc with icc  i get:
 

In file included from /home/soft/cuda-6.0/include/cuda_runtime.h(59),
                 from /home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib/gpu_utils/memtestG80_core.cu(0):
/home/soft/cuda-6.0/include/host_config.h(72): error: #error directive: -- unsupported ICC configuration! Only ICC 13.1 on Linux x86_64 is supported!
  #error -- unsupported ICC configuration! Only ICC 13.1 on Linux x86_64 is supported!
   ^


so i reconfigured gromacs using intel 2013 compilers (icc version 13.0.1 (gcc version 4.4.7 compatibility)
even then i get the same error :

vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/include -I/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/gromacs-4.6.5/src/gmxlib -I/home/soft/cuda-6.0/include
icc: command line warning #10006: ignoring unknown option '-dumpspecs'
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../lib64/crt1.o: In function `_start':
(.text+0x20): undefined reference to `main'
CMake Error at cuda_tools_generated_cudautils.cu.o.cmake:206 (message):




Any help/hint/suggestion will be very useful.
config logs are attached!
 

0 Kudos
3 Replies
Kittur_G_Intel
Employee
463 Views

Hi Puneet,
Based on the error it looks like your configuration is looking for a specific icc compiler with a particular build date and it's failing that condition.
Look at the host_config.h file under the cuda include directory and see what build date is specified? And if you do %icc -V it should give you the version and the build date. Then, make sure you use the correct version of icc that satisfies the build date and it hopefully should then work.

_Kittur

0 Kudos
psing51
New Contributor I
463 Views

Ok , the previous build was fine when i used -ccbin as intel's mpicc,
Now , I am trying to build gromacs 4.6.2 on CentOS 6.5 (with cuda - 6.0 & intel compilers + avx) and i am facing avx intrinsics related errors :
 

 file included from /home/cc/vfaculty/puneets.vfaculty/GromacsNonPlumed/gromacs-4.6.2/include/gmx_x86_simd_single.h(46),
                 from /home/cc/vfaculty/puneets.vfaculty/GromacsNonPlumed/gromacs-4.6.2/include/gmx_simd_macros.h(177),
                 from /home/cc/vfaculty/puneets.vfaculty/GromacsNonPlumed/gromacs-4.6.2/src/gmxlib/bondfree.c(64):
/home/cc/vfaculty/puneets.vfaculty/GromacsNonPlumed/gromacs-4.6.2/include/gmx_math_x86_avx_128_fma_single.h(429): error: a value of type "int" cannot be assigned to an entity of type "__m128"
      pC0  = _mm_macc_ps(pC0, t2, CC0);
           ^

CC="$MPIC_COMP" CFLAGS="-fPIC" CXX="$MPICXX_COMP" CXXFLAGS="-fPIC" cmake -DCMAKE_INSTALL_PREFIX:PATH="/home/cc/vfaculty/puneets.vfaculty/GromacsNonPlumed/gromacsnonplumed/"  -DCMAKE_C_COMPILER=$MPIC_COMP -DCMAKE_C_FLAGS="-fPIC" -DCMAKE_CXX_COMPILER=$MPICXX_COMP  -DCMAKE_CXX_FLAGS="-fPIC" -DGMX_OPENMP="ON" -DGMX_THREAD_MPI="ON"  -DGMX_MPI="ON" -DGMX_GPU="ON" -DCUDA_TOOLKIT_ROOT_DIR="/home/soft/cuda-6.0/" -DGMX_PREFER_STATIC_LIBS="ON" -DREGRESSIONTEST_PATH="/home/cc/vfaculty/puneets.vfaculty/GromacsPlumed/regressiontests-4.6.2" -DREGRESSIONTEST_DOWNLOAD="NO" -DGMX_EXTERNAL_BLAS="ON" -DGMX_EXTERNAL_LAPACK="ON" -DGMX_FFT_LIBRARY="mkl" -DMKL_LIBRARIES="/home/soft/intel2015/mkl/lib/intel64/libfftw3x_cdft_lp64.a;/home/soft/intel2015/mkl/lib/intel64/libfftw2xc_double_intel.a;/home/soft/intel2015/mkl/lib/intel64/libfftw2xf_double_intel.a" -DMKL_INCLUDE_DIR="/home/soft/intel2015/mkl/include"  -DCUDA_HOST_COMPILER="/home/soft/intel2015/impi/5.0.3.048/intel64/bin/mpicc" -DCUDA_PROPAGATE_HOST_FLAGS="OFF" -DGMX_CPU_ACCELERATION="AVX_128_FMA" -DCMAKE_SKIP_RPATH="YES" --enable-sse2 .. |tee Gromax_config.log

 
where
export CC=icc
export CXX=icpc
export FC=ifort

export MPIC_COMP=mpiicc
export MPIF_COMP=mpiifort
export MPICXX_COMP=mpiicpc

 I am getting same error on both processors:
model name    : Intel(R) Xeon(R) CPU E5-2680 v3 @ 2.50GHz
flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good xtopology nonstop_tsc aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm arat epb xsaveopt pln pts dts tpr_shadow vnmi flexpriority ept vpid fsgsbase bmi1 avx2 smep bmi2 erms invpcid

model name    : Intel(R) Xeon(R) CPU E5-2670 0 @ 2.60GHz
 flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good xtopology nonstop_tsc aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx lahf_lm ida arat epb xsaveopt pln pts dts tpr_shadow vnmi flexpriority ept vpid

i have attached cmakeconfig log & make log.
Is there anything i can do here ? it does not seem that that intel compilers at fault here , but since intel compilers are involved here , hence i am putting this up here. Any help/hint will be very useful

(I tried to post this as a new topic but i was getting error that was prompting me to fill up subject again & again, so i am putting up this question here )
 

 

0 Kudos
Kittur_G_Intel
Employee
463 Views

Hi Puneet,
The error seems to be a mismatch on the __m128 intrinsic call inteface and from the log I couldn't find out which version of GCC you're using? AVX is supported only from GCC 4.6.X upwards and I'd recommend using GCC 4.7 to ensure the correct asm is used. Reason, Intel Compilers use th GNU tools on the system such as the header files, linker and libraries for ensuring compatibility with GNU version as well.

Can you see if that's the case? 

_Kittur

 

0 Kudos
Reply