[CMake] oversubscribing OpenMPI in tests

Zaak Beekman zbeekman at gmail.com
Thu Jun 16 20:31:55 EDT 2016


Excellent, this is far better than any of the approaches I had thought
of... cheers!

On Thu, Jun 16, 2016 at 4:45 PM Thompson, KT <kgt at lanl.gov> wrote:

> Zaak,
>
>
>
> I use ‘execute_process (${MPIEXEC} --version)’ and match the output to a
> string (Open MPI, ALPS, MPICH).  This isn’t the most elegant solution, but
> it seems fairly robust.
>
>
>
> -kt
>
>
>
> *From:* CMake [mailto:cmake-bounces at cmake.org] *On Behalf Of *Zaak Beekman
> *Sent:* Thursday, June 16, 2016 9:14 AM
> *To:* cmake at cmake.org
> *Subject:* [CMake] oversubscribing OpenMPI in tests
>
>
>
> Does anyone know a good way to determine if `find_package(MPI REQUIRED)`
> is returning OpenMPI? I need to know, because OpenMPI does not handle
> oversubscribed (more ranks than cores) tests well without explicitly
> telling OpenMPI that you are oversubscribing. This can be done by creating
> a hosts file, and passing some flags to `mpirun` to tell it to use the
> hosts file, or can be accomplished by passing the `--oversubscribe` flag.
> The problem is that MPICH has different flags/host-file syntax.
>
>
>
> (I am oversubscribing some of the project's tests because this will often
> find correctness problems due to race conditions or other parallel
> programming errors that are not always exposed otherwise.)
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20160617/25cb662a/attachment.html>


More information about the CMake mailing list