[Dune] error running code with MPI

Christian Engwer christi at uni-hd.de
Fri Sep 3 15:15:27 CEST 2010


Hi Florian,

> no, I did not use this kind of flag :-)
> 
> I'm using an opts file to compile dune. Do I have to include it into
> the CXXFLAGS or somewhere else as well?

OK, this _might_ be the reason for your strange bugs. The problem is,
that DUNE does break strict aliasing.

> dune.opts.file:
> 
> CONFIGURE_FLAGS="CXX='mpicxx' CC='mpicc' LD='mpicxx'
> CXXFLAGS='-DMPICH_IGNORE_CXX_SEEK -O2'
> CPPFLAGS='-DMPICH_IGNORE_CXX_SEEK -O2'
> LDFLAGS=' '
>           --disable-documentation
>           --enable-parallel
>           --enable-debug-output
>           --with-boost='$HOME/extlib-scratch3-felsim/boost-trunk'
>           --with-metis='$HOME/extlib-scratch3-felsim/metis-4.0'
>           --with-rlog='$HOME/extlib-scratch3-felsim/rlog-1.4'
>           --with-alugrid='$HOME/extlib-scratch3-felsim/ALUGrid-1.22'"

Yes, you have to add it to the CXXFLAGS listed in the CONFIGURE_FLAGS.

Btw. DUNE tries to support MPI without the need to invoke the mpi
compiler directly. It detects quite a range of MPI compilers and
extract the CXXFLAGS and the LDFLAGS. In this case it would be
sufficient to use CXX='g++-4.3' or what ever compiler you want to use
and specify the mpi compiler as MPICC=/path-to-mpi/mpicc. If DUNE
doesn't detect your MPI compiler correctly, it would be great if you
could help us adding support for this mpi version.

Hope it works now :-)
Christian




More information about the Dune mailing list