[mpich-discuss] Strange error

Dave Goodell goodell at mcs.anl.gov
Wed Oct 10 10:45:03 CDT 2012


This info is all basic/intermediate MPI usage.  I recommend obtaining a good book on MPI, such as "Using MPI": http://www.amazon.com/Using-MPI-2-Scientific-Engineering-Computation/dp/026257134X/

-Dave

On Oct 10, 2012, at 6:38 AM CDT, Alejandro Allievi wrote:

> No I did not change the error handler for MPI_COMM_WORLD. How could I do
> that??
> 
> Also, what do you mean by "performing multiple completions in the same
> call"??
> 
> (sorry for all the silly question)
> 
> On Tue, Oct 9, 2012 at 4:25 PM, Dave Goodell <goodell at mcs.anl.gov> wrote:
> 
>> IIRC, the MPI_ERROR field of the status structure is not used when
>> performing an MPI_Recv.  It is only used when performing multiple
>> completions in the same call, such as with MPI_Waitall/Testsome/etc.
>> 
>> Did you change the error handler for MPI_COMM_WORLD?  If not, then it
>> defaults to MPI_ERRORS_ARE_FATAL, which will cause the MPI job to abort if
>> an error is encountered.  If you change it to MPI_ERRORS_RETURN then you
>> need to capture the return value from MPI_Recv.  For example:
>> 
>> ----8<----
>> int mpi_errno;
>>>> mpi_errno = MPI_Recv(greeting,…);
>> if (mpi_errno != MPI_SUCCESS) {
>>    /* inspect mpi_errno here */
>> }
>> ----8<----
>> 
>> -Dave
>> 
>> On Oct 9, 2012, at 1:36 PM CDT, Alejandro Allievi wrote:
>> 
>>> Thanks for the reply.
>>> 
>>> Here goes a code snippet containing the part that generates the error
>>> 
>>>              MPI_Recv(greeting, MAX_STRING, MPI_CHAR, MPI_ANY_SOURCE,
>> MPI_ANY_TAG , MPI_COMM_WORLD, &status);
>>> 
>>> //These are fine
>>>              printf("\nSource of this message is process: %d\n",
>> status.MPI_SOURCE);
>>>              printf("Tag of this message is: %d\n", status.MPI_TAG);
>>> 
>>> //This is the problem. Not quite sure if correct though.
>>>              MPI_Error_string( status.MPI_ERROR , mystring , &len );
>>>              printf("Tag of this message is: %d %s\n", status.MPI_ERROR
>> , mystring );
>>> 
>>> //These are fine too
>>>              MPI_Get_count(&status , MPI_CHAR , &count);
>>>              printf("Size of this message is: %d MPI_CHAR", count);
>>> 
>>> Alejandro
>>> 
>>> 
>>> On Tue, Oct 9, 2012 at 3:38 PM, Dave Goodell <goodell at mcs.anl.gov>
>> wrote:
>>> Can you post some example code showing how you are calling MPI_Recv and
>> how you are processing the error code/class/message?  It's easy to get
>> confused by the error handling conventions of the MPI standard, and this
>> sounds like either user error or memory corruption, depending on what code
>> you post.
>>> 
>>> -Dave
>>> 
>>> On Oct 9, 2012, at 11:55 AM CDT, Alejandro Allievi wrote:
>>> 
>>>> Hi,
>>>> 
>>>> I'm getting the following error: "No MPI error, error stack:
>> (unknown)(): No MPI error"
>>>> returned by "status.MPI_ERROR" in "status" variable  in MPI_Recv.
>> However, there seems
>>>> to be no error. Does anybody know why the "error stack: (unknown)():
>> No MPI error"
>>>> 
>>>> Thanks for any help.
>>>> 
>>>> Alejandro
>>>> _______________________________________________
>>>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>>>> To manage subscription options or unsubscribe:
>>>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>> 
>>> _______________________________________________
>>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>>> To manage subscription options or unsubscribe:
>>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>> 
>>> 
>>> 
>>> --
>>> Alejandro Allievi
>>> http://www.ace-net.ca/wiki/Alejandro_Allievi
>>> 
>>> "Tenez, mon ami, si vous y pensez bien, vous trouverez qu'en tout, notre
>> véritable sentiment n'est pas celui dans lequel nous n'avons jamais
>> vacillé; mais celui auquel nous sommes le plus habituellement revenus".
>> Denis Diderot.
>>> 
>>> Este e-mail esta consignado sólo para el destinatario designado en el
>> mismo y puede contener información confidencial y privilegiada. Su
>> distribución o copiado está prohibido. Si Usted no fuera el destinatario
>> designado, por favor notifíquenos de inmediato y destruya este e-mail en
>> forma permanente así como todas las copias del mismo. Ce courriel peut
>> renfermer des renseignements confidentiels et privilégiés et s'adresse au
>> destinataire désigné seulement. La distribution ou la copie de ce courriel
>> est interdit. Si vous n'êtes pas le destinataire désigné, veuillez nous en
>> aviser immédiatement et détruire de façon permanente ce courriel ainsi que
>> toute copie de celui-ci. This e-mail may contain confidential information,
>> and is intended only for the named recipient and may be privileged.
>> Distribution or copying of this email is prohibited. If you are not the
>> named recipient, please notify us immediately and permanently destroy this
>> email and all copies of it.
>>> 
>>> _______________________________________________
>>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>>> To manage subscription options or unsubscribe:
>>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>> 
>> _______________________________________________
>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>> To manage subscription options or unsubscribe:
>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>> 
> _______________________________________________
> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
> To manage subscription options or unsubscribe:
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss



More information about the mpich-discuss mailing list