[MPICH] Linking difficulty

Jon Huntley Jon.Huntley at cbo.gov
Mon Jun 20 10:44:29 CDT 2005


I apologize if this is a really stupid question, but I am quite the novice programmer.

So I have a simulation that I'm compiling with Compaq Visual Fortran 6.6.0 in Windows XP, and I've been asked to see if I can make it run faster with parallel processing.  So I've installed MPICH2, followed all of the instructions in the readme, and made a nice little test run of my program in Windows on a single processor machine where I bounce messages back and forth between processes.  To me, this is really nifty.

The problem is that this only works in the Debug mode.  If I use the Release mode (which is about twice as fast for this program without MPI, so this is a serious concern), I get all manner of linker errors, although compiling always seems to go through error free.  For example, I get:
LINK : warning LNK4089: all references to "fmpich2.dll" discarded by /OPT:REF

So I choose /OPT:NOREF and I get the following error upon execution:
FATAL ERROR 1 from MPI_INIT.  A CALL was executed using the IMSL dummy routine.  Parallel performance needs a functioning MPI library.

Furthermore, if I include calls to the subroutines MPI_SEND and MPI_RECV, I unavoidably get the error (/OPT:NOREF doesn't get me past this):
Model.obj : error LNK2001: unresolved external symbol _MPI_SEND at 32
Model.obj : error LNK2001: unresolved external symbol _MPI_RECV at 36

I've tried copying all of the libraries I know about into the program directories, I've tried all of the switches and options I know about (going through and comparing diligently the options under the Debug and Release modes), and I can't seem to find anything.  Does anybody have any suggestions on some things to try, or any ideas on what I'm doing wrong?  

Thanks,
Jon





More information about the mpich-discuss mailing list