[mpich-discuss] Hydra issues

Pavan Balaji balaji at mcs.anl.gov
Fri Sep 4 15:53:56 CDT 2009


This has been fixed in the svn trunk.

Scott: can you try this patch: 
https://trac.mcs.anl.gov/projects/mpich2/changeset/5292

Thanks,

  -- Pavan

On 08/28/2009 04:22 PM, Pavan Balaji wrote:
> 
> Yup, you are right. I can reproduce the problem when I use more than one 
> node. I'll look into this next week.
> 
>  -- Pavan
> 
> On 08/28/2009 02:46 PM, Scott Atchley wrote:
>> On Aug 28, 2009, at 2:53 PM, Scott Atchley wrote:
>>
>>> I tried your test app again and it starts immediately without NO_MPI 
>>> set and is delayed when NO-MPI=1; the exact opposite of the above. I 
>>> tested IMB 2.3 and it too is delayed.
>>
>>
>> I modified your test app (see below). I eliminated the sleep() and 
>> replaced it with busy work. I print it out at the end to avoid the 
>> compiler removing the code (my gcc did).
>>
>> If I run it with -n 4 over two nodes, I see the output from the local 
>> host in real time (and interleaved). The other two ranks' output does 
>> not appear until the end of the run and the output is serialized.
>>
>> Scott
>>
>> #include <stdio.h>
>> #include <stdlib.h>
>> #include "mpi.h"
>>
>> int main(int argc, char *argv[])
>> {
>>    int i, use_mpi = 0, rank = -1;
>>    long sum = 0L;
>>
>>    use_mpi = (!(getenv("NO_MPI"))) ? 1 : 0;
>>
>>    if (use_mpi) {
>>        MPI_Init(&argc, &argv);
>>        MPI_Comm_rank(MPI_COMM_WORLD, &rank);
>>    }
>>
>>    for (i = 0; i < 20; i++) {
>>        int j;
>>
>>        if (use_mpi)
>>            MPI_Barrier(MPI_COMM_WORLD);
>>
>>        printf("%d: Hello World!\n", rank);
>>        for (j = 0; j < 10000000; j++) {
>>            sum += j;
>>            if (j > 0) sum /= j;
>>        }
>>    }
>>
>>    if (use_mpi) {
>>        MPI_Barrier(MPI_COMM_WORLD);
>>        MPI_Finalize();
>>    }
>>    printf("%ld\n", sum);
>>
>>    return 0;
>> }
> 

-- 
Pavan Balaji
http://www.mcs.anl.gov/~balaji


More information about the mpich-discuss mailing list