[mpich-discuss] Bug reporting for some mpi/rma tests

Kenneth Raffenetti raffenet at mcs.anl.gov
Tue May 31 09:51:33 CDT 2016


Hi,

On 05/31/2016 09:31 AM, Clément Foyer wrote:
> Hi everyone,
>
> As I was using your tests I was surprised by some of them.
>
> The first one is test/mpi/rma/get_acc_local.c, as you accumulate NITER
> times acc_val into out_val, initialized at 0. At each step of the loop
> you check whether the out_val is equal to i times acc_val. As i start
> from 0, you expect the result to be 0 instead of acc_val. I suppose you
> should have had i start from 1, or change the test line 36 to "if
> (out_val != acc_val * (i + 1)) {", with an adaptation of the debug
> message as well.

This test looks correct to me. Consider the values of the first few 
interations.

Iteration 0 before Get_accumulate:
i = 0, counter = 0, acc_val = 3, out_val = N/A;
Iteration 0 after Get_accumulate:
i = 0, counter = 3, acc_val = 3, out_val = 0 == (acc_val * i);
Iteration 1 before Get_accumulate:
i = 1, counter = 3, acc_val = 3, out_val = 0;
Iteration 1 after Get_accumulate:
i = 1, counter = 6, acc_val = 3, out_val = 3 == (acc_val * i);

And so on...

>
> The second test in which I found errors is mpi/rma/selfrma.c. The
> parameters given to the printf function at lines 66, 80 and 95 are in
> the wrong order. It should be "j, winbuf[j], sbuf[j]" instead of
> "winbuf[j], j, sbuf[j]". And at the line 95, the header to the debug
> line is "AccVec", as it seems it should have been "GetVec".

Yes, this looks like a bug. We will commit a fix soon. Thanks for reporting.

Ken
_______________________________________________
discuss mailing list     discuss at mpich.org
To manage subscription options or unsubscribe:
https://lists.mpich.org/mailman/listinfo/discuss


More information about the discuss mailing list