[mpich-discuss] Urgent : debug MPI applications on windows 7

toufik hadjazi h_toufik7 at hotmail.fr
Wed Sep 12 05:34:28 CDT 2012


Hi all,
it's been two weeks I'm struggling with "Access violation reading" error in my application on the function "MPI_Comm_accept", the weird thing is it work well some iterations then it crashes. MPI_Comm_accept is used in a QThread, the code of the thread is below.
So, does anyone knows how to debug MPI applications in order to determine where the problem is located? or some way to run the application instruction per instruction? i need help the sooner possible 'cause I don't have much time to finish the application.P.S: I'm working on qt add-in on visual studio 2010 on windows 7, and I'm running my application with "wmpiexec.exe"
void ReceiverThread::run(){	CMessage Mes;	MPI_Datatype MessageType = Mes.createMessageType();		MPI_Comm client;	MPI_Status status;	Message message;	 	char myPort[MPI_MAX_PORT_NAME];	DIH.getPort(myPort);
	forever	{		// wait up for a new message		printf("\naccepting connections on <%s>\n", myPort); fflush(stdout);		MPI_Comm_accept(
myPort , MPI_INFO_NULL, 0, MPI_COMM_WORLD, &client);				MPI_Recv(&message, 1, MessageType, MPI_ANY_SOURCE, MPI_ANY_TAG, client, &status);
		//insert the message into the fifo		DIH.InFifo.Insert(message);		printf("\nA messaage %d has been received from <%s>\n", message.Command, message.portSource); fflush(stdout);
		//disconnect from the current client		MPI_Barrier(client);		MPI_Comm_disconnect(&client);	}} 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/mpich-discuss/attachments/20120912/2defff55/attachment.html>


More information about the mpich-discuss mailing list