Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

From: Harald Forbert (Harald.Forbert_at_[hidden])
Date: 2006-09-06 10:39:16


I think I traced a bug found by blacs testers with various versions
of openmpi in ompi/datatype/datatype_unpack.c (ompi/datatype/dt_unpack.c
in 1.0.x). This might be related to ticket #65. At least after
applying the following patch (for 1.1.[01]), the blacs reduce amax seems
to work correctly:

--- openmpi-1.1/ompi/datatype/datatype_unpack.c.orig
+++ openmpi-1.1/ompi/datatype/datatype_unpack.c
@@ -221,6 +221,8 @@

             length = pConv->bConverted / pData->size; /* already done */
             length = pConv->bConverted - length * pData->size; /* still left on the last element */
+ length = pData->size - length;
+ if (length > remaining) length = 0;
             /* complete the last copy */
             if( length != 0 ) {
                 OMPI_DDT_SAFEGUARD_POINTER( user_memory, length, pConv->pBaseBuf,

=======================================================================
Harald Forbert e-mail: Harald.Forbert_at_[hidden]
Lehrstuhl fuer Theoretische Chemie Phone: ++49 (0)234/32-26751
Ruhr-Universitaet Bochum Fax: ++49 (0)234/32-14045
Universitaetsstrasse 150
D-44780 Bochum, Germany
=======================================================================