Re: [AMBER] MPI cuda compilation error

From: Ross Walker <ross.rosswalker.co.uk>
Date: Sat, 2 Jul 2011 11:31:34 -0700

Hi Fabricio,

> I have taken your advice and set MPI_HOME=/usr/lib/openmpi . It seems
> to have worked partially since now the error comes at a later stage of
> the "make" process. The error comes out as described below. Sorry for
> the size of the paste below, but I wasn't sure where the error began.
> Any suggestions? Thank you in advance

Ah ha... Here in lies your problem I think. Your MPI installation would seem
to be in an unusual place. Here you have /usr/lib/openmpi. I assume this
contains the mpi library files and then you also have /usr/bin/openmpi and
/usr/include/openmpi. This unfortunately will cause all sorts of problems
since the configure script expects the paths to be of the form:

$MPI_HOME/bin
$MPI_HOME/include
$MPI_HOME/lib

In most cases your mpif90 / mpicc scripts will just take care of this but in
the cuda compilation you have to use NVCC which means the MPI include
directory needs to be manually specified.

You will have something like the following in your config.h

PMEMD_CU_INCLUDES=-I$(CUDA_HOME)/include -IB40C -IB40C/KernelCommon
-I/usr/lib/openmpi/include

Which I suspect is NOT where your mpi.h resides. You can edit config.h and
change the -I to -I/usr/include/openmpi and it will probably work.

The other option is to install MPI in a more 'normal' location. Ultimately
though I guess we need to update the configure script to properly deal with
these situations. There probably needs to be an MPI_INCLUDE environment
variable or some kind of more advanced passing of mpif90 -show to deal with
this situation since it is not compatible with the MPI_HOME approach or
simply looking for the location of mpif90 which is what is currently used.

On another note, if you are running on more than one node over IB I strongly
recommend you use MVAPICH2 instead of openmpi since you will likely get much
better performance.

All the best
Ross

/\
\/
|\oss Walker

---------------------------------------------------------
| Assistant Research Professor |
| San Diego Supercomputer Center |
| Adjunct Assistant Professor |
| Dept. of Chemistry and Biochemistry |
| University of California San Diego |
| NVIDIA Fellow |
| http://www.rosswalker.co.uk | http://www.wmd-lab.org/ |
| Tel: +1 858 822 0854 | EMail:- ross.rosswalker.co.uk |
---------------------------------------------------------

Note: Electronic Mail is not secure, has no guarantee of delivery, may not
be read every day, and should not be used for urgent or sensitive issues.




_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Sat Jul 02 2011 - 12:00:03 PDT
Custom Search