[mpich-discuss] RE: Buggy code - return status is an Integer array for fort pgms
Jayesh Krishna
jayesh at mcs.anl.gov
Tue May 6 10:55:09 CDT 2008
Hi,
The return status in MPI calls is an Integer array for fortran programs.
After the change your code works for me.
######### orig code #########
...
integer :: x, y, z, count, k, status, ierr
...
CALL MPI_RECV(count, 1, MPI_INTEGER, source, OCNT_TAG, MPI_COMM_WORLD,
status, ierr)
######### modify to ##########
...
integer :: x, y, z, count, k, status(MPI_STATUS_SIZE), ierr
...
CALL MPI_RECV(count, 1, MPI_INTEGER, source, OCNT_TAG, MPI_COMM_WORLD,
status, ierr)
##############################
Let us know if you have any other problems.
Regards,
Jayesh
-----Original Message-----
From: Gib Bogle [mailto:g.bogle at auckland.ac.nz]
Sent: Monday, May 05, 2008 2:16 AM
To: Jayesh Krishna
Subject: Buggy code
Hi Jayesh,
After a lot of trial and error, and some luck, I've managed to create a
small program that shows the problem I referred to with
MPICH2/Fortran/Windows.
I've put the source code and the associated Intel project files into a zip
file (attached).
The failure mode is different with 'No optimization' and 'Optimize for
maximum speed'.
This test program runs if I turn off runtime error checking (All), but
that isn't true for the real program. In general changing the compile
and/or run flags changes the behaviour.
By the way, if the write statement at line 29 in etransfer.f90 is
commented out, the program runs.
My guess is that there is a problem with the stack.
I hope this code is useful to you, and wish you luck. I'm exhausted :-(
Cheers
Gib
--
Dr. Gib Bogle
Research Scientist
Auckland Bioengineering Institute
University of Auckland
New Zealand
http://www.bioeng.auckland.ac.nz
g.bogle at auckland.ac.nz
(64-9) 373-7599 Ext. 87030
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20080506/c03113ca/attachment.htm>
More information about the mpich-discuss
mailing list