thliebig / openEMS

openEMS is a free and open-source electromagnetic field solver using the EC-FDTD method.
http://openEMS.de
GNU General Public License v3.0
430 stars 150 forks source link

A few fixes for MPI #23

Closed georgmichel closed 7 years ago

georgmichel commented 7 years ago

main.cpp:

  1. Check return value of ParseFDTDSetup and exit if false
  2. Use exit instead of return. These are almost identical. But in my OpenMPI installation the process with teh highes rank segfaults at the end when using return. This is not the case with exit. Probably some C++ cleanup problem (destructors). openems.cpp: Give Parse_XML_FDTDSetup a deterministic return value (return true). Please omit the other changes. They are due to a not up-to-date local repository. openems_fdtd_mpi.cpp:
  3. Remove the word "only" in an error message because there can also be too many processes.
  4. Fix the indexing variables for SetSplitPos in SetupMPI. Otherwise more than one split results in an out-of-range exception and unexpected behavior. RunOpenEMS_MPI.m: Apply Settings.MPI.GlobalArgs also to multi-host scenarios.
thliebig commented 7 years ago

Hi, two thinks, your username and email in the commit are a bit wired, but ok. I cannot pull the first change in "openems.cpp" about the dual time/mesh for the probes. That is a bug fix I recently made and that would be rerverted. Please remove it from the commit... Everything else looks fine. But I will have a closer look/test. But since I'm not really using MPI I will leave the testing for that with you ;)

thliebig commented 7 years ago

See #25