[Llvm-bgq-discuss] pulling in mpi using clang

Jeff Hammond jhammond at alcf.anl.gov
Fri Feb 1 00:21:42 CST 2013


> What's the proper way to get mpi when using /home/projects/llvm/current/bin/bgclang++?

I thought Hal made wrappers at some point.  Maybe on another machine.

> Previously, I stole the flags from the gcc mpi wrapper (I unfortunately do not remember how I
> did this), and then manually specifiied

You can use mpicxx wrapper with MPICH_CXX=bgclang++ instead to get the
same thing with less typing.

>     -I/bgsys/drivers/V1R1M2/ppc64/comm/sys/include
> -I/bgsys/drivers/V1R1M2/ppc64
> -I/bgsys/drivers/V1R1M2/ppc64/spi/include
> -I/bgsys/drivers/V1R1M2/ppc64/spi/include/kernel/cnk
> -I/bgsys/drivers/V1R1M2/ppc64/comm/gcc/include
>     -Wl,-rpath=/bgsys/drivers/V1R1M2/ppc64/comm/gcc/lib
> -Wl,-rpath=/bgsys/drivers/V1R1M2/ppc64/comm/sys/lib
> -Wl,-rpath=/bgsys/drivers/V1R1M2/ppc64/spi/lib
> -L/bgsys/drivers/V1R1M2/ppc64/comm/gcc/lib
> -L/bgsys/drivers/V1R1M2/ppc64/comm/sys/lib
> -L/bgsys/drivers/V1R1M2/ppc64/spi/lib -lmpich -lopa -lmpl -lrt -ldl
> -lpami -lSPI -lSPI_cnk -lpthread
>
> This seems fairly sketchy, so I'd like to do it the right way if such exists, especially if the driver versions are going to change soon.

I don't think it is sketchy.  It's what I've been doing for all my
LLVM codes.  LAMMPS (C++ molecular dynamics code using MPI C
interface) had no issues with this recipe.

> Are there wrapper compilers set up?

As noted above, I don't know.

I can build you a bona fide LLVM MPICH though if you think it would
help.  I did this a long time ago and just need to update it.

> If I do the above manual way, and qsub a job, it errors out during launch with

> VST-20400-31511-32:14558:ibm.runjob.client.Job: Load failed on
> Q02-I4-J04: Application executable ELF header contains invalid value,
> errno 8 Exec format error

> It's possible this is unrelated, of course.

Looks like an LLVM-related issue but not an MPI one, at least not directly.

Jeff

-- 
Jeff Hammond
Argonne Leadership Computing Facility
University of Chicago Computation Institute
jhammond at alcf.anl.gov / (630) 252-5381
http://www.linkedin.com/in/jeffhammond
https://wiki.alcf.anl.gov/parts/index.php/User:Jhammond


More information about the llvm-bgq-discuss mailing list