Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem using OpenMP and MPI at the same time

Status
Not open for further replies.

smithpd

Programmer
Jul 8, 2002
20
US
I would like some advice on how to track down what seems to be a compiler bug in Microsoft Visual Studio (VS) 2008, but I am not sure. It could be something I could fix, but I have no idea how to approach it.

I have a hybrid parallel code that uses both MPI, for control of tasks, and OpenMP, which provides for running multi-threaded loops within an MPI task. The code successfully compiles and runs in hybrid mode using Visual Studio 2003 and the Intel compiler 9.1. The Intel compiler was needed for initial development because VS 2003 does not support OpenMP.

I have just ported the code to Visual Sudio 2008 Professional, which supports OpenMP natively through the compiler flag /openmp and #include <omp.h>. Initially I am running this without the Intel compiler.

I have several build configurations:
Release - neither OpenMP nor MPI. no parallelism.
openmp - OpenMP loop pragmas but no MPI
mpi - MPI parallism but no OpenMP
hybrid - both MPI and OpenMP.

With the previous VS 2003 / Intel 9.1 compiler combination, all build configurations compiled, linked, and ran perfectly. Now, after conversion to VS 2008 with no Intel compiler, all configurations compile and link without errors, and all configurations other than hybrid run perfectly.

I know that the OpenMP and MPI calls and libraries are being properly handled because nothing about the code or the project files have changed other than conversion to 2008. The previous compiler worked with all configurations, and MPI and OpenMP work individually in 2008. So why not together in 2008?

The specific problem with the 2008 hybrid EXE is that the instant I invoke the EXE, before any parallel computing of either kind occurs, I get the following message in a dialogue box:
"The application failed to initialize properly (0xc0000142). Click OK to terminate the application." I get this when running the EXE either directly or under control of mpiexec.

Running the hybrid EXE under the debugger, the code stops before it gets to the first instruction in main(). It seems to me that this cannot be related to my source code but the operating system is objecting to some header information in the EXE, before my code starts running.

Any ideas how to sort this out other than to blame Microsoft?

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top