Hi,

I know 1.4.3 is really old but I am currently stuck with it. However, there seems to be a bug in Allgather.

I have attached the source of an example program.

The output I would expect is:
rettenbs@hpcsccs4:/tmp$ mpiexec -np 5 ./a.out
0 0 1 2
1 0 1 2
2 0 1 2
3 0 1 2
4 0 1 2

But what I get is different results when I run the program multiple times:
rettenbs@hpcsccs4:/tmp$ mpiexec -np 5 ./a.out
0 0 1 2
1 0 1 2
2 0 1 2
3 2000 2001 2002
4 0 1 2
rettenbs@hpcsccs4:/tmp$ mpiexec -np 5 ./a.out
0 0 1 2
1 0 1 2
2 0 1 2
3 2000 2001 2002
4 3000 3001 3002

This bug is probably already fixed. Does anybody know in which version?

Best regards,
Sebastian

--
Sebastian Rettenberger, M.Sc.
Technische Universität München
Department of Informatics
Chair of Scientific Computing
Boltzmannstrasse 3, 85748 Garching, Germany
http://www5.in.tum.de/
#include <mpi.h>

#include <iostream>

int main(int argc, char* argv[])
{
	MPI_Init(&argc, &argv);

	int size, rank;
	MPI_Comm_rank(MPI_COMM_WORLD, &rank);

	int s[25];
	for (int i = 0; i < 25; i++)
		s[i] = rank*1000 + i;

	int r[500];
	MPI_Allgather(s, 25, MPI_INT, r, 25, MPI_INT, MPI_COMM_WORLD);

	std::cout << rank << ' ' << r[0] << ' ' << r[1] << ' ' << r[2] << std::endl;

	MPI_Finalize();
}

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to