commits
Threads by month
- ----- 2026 -----
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- 2054 discussions
[mpich] MPICH primary repository branch, master, updated. v3.0.2-81-g317b2f3
by noreply@mpich.org 21 Mar '13
by noreply@mpich.org 21 Mar '13
21 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 317b2f3e7ab4efb58b20cf51e35871d4e88f630e (commit)
via a0e9eb583b383f234bedd58a7af9d132dcdd45bf (commit)
via 803fda10de941c79e2dc1bfbcfe65d0cb68e328f (commit)
from 5ac51edf49d664d33b4a88fc6a5cebeb51950149 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/317b2f3e7ab4efb58b20cf51e35871d4e…
commit 317b2f3e7ab4efb58b20cf51e35871d4e88f630e
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Mar 21 11:35:27 2013 -0500
Fix coll6 test hanging with more than 10 processes
This closes ticket #1798. Patch provided by Jeff Hammond.
Reviewer: dinan
diff --git a/test/mpi/coll/coll6.c b/test/mpi/coll/coll6.c
index 5691357..6e8ea36 100644
--- a/test/mpi/coll/coll6.c
+++ b/test/mpi/coll/coll6.c
@@ -17,21 +17,23 @@ int main( int argc, char **argv )
int participants;
int displs[MAX_PROCESSES];
int recv_counts[MAX_PROCESSES];
+ MPI_Comm test_comm;
MTest_Init( &argc, &argv );
MPI_Comm_rank( MPI_COMM_WORLD, &rank );
MPI_Comm_size( MPI_COMM_WORLD, &size );
/* A maximum of MAX_PROCESSES processes can participate */
- if ( size > MAX_PROCESSES ) participants = MAX_PROCESSES;
- else participants = size;
- /* while (MAX_PROCESSES % participants) participants--; */
+ participants = ( size > MAX_PROCESSES ) ? MAX_PROCESSES : size;
+
if (MAX_PROCESSES % participants) {
fprintf( stderr, "Number of processors must divide %d\n",
MAX_PROCESSES );
MPI_Abort( MPI_COMM_WORLD, 1 );
}
- if ( (rank < participants) ) {
+ MPI_Comm_split(MPI_COMM_WORLD, rank<participants, rank, &test_comm);
+
+ if ( rank < participants ) {
/* Determine what rows are my responsibility */
int block_size = MAX_PROCESSES / participants;
@@ -53,7 +55,7 @@ int main( int argc, char **argv )
/* Everybody gets the gathered data */
MPI_Allgatherv(&table[begin_row][0], send_count, MPI_INT,
&table[0][0], recv_counts, displs,
- MPI_INT, MPI_COMM_WORLD);
+ MPI_INT, test_comm);
/* Everybody should have the same table now.
@@ -80,6 +82,8 @@ int main( int argc, char **argv )
}
MTest_Finalize( errors );
+
+ MPI_Comm_free(&test_comm);
MPI_Finalize();
return MTestReturnValue( errors );
}
http://git.mpich.org/mpich.git/commitdiff/a0e9eb583b383f234bedd58a7af9d132d…
commit a0e9eb583b383f234bedd58a7af9d132dcdd45bf
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Mar 21 09:23:43 2013 -0500
Replace calls to sleep with MTestSleep in tests
This replaces calls to non-portable (to e.g. Windows) sleep with calls
to MTestSleep. Submitted by Jeff Hammond. Where possible, dependencies
on unistd.h have been removed.
Reviewer: dinan
diff --git a/test/mpi/basic/wtime.c b/test/mpi/basic/wtime.c
index bcad008..ec09cb3 100644
--- a/test/mpi/basic/wtime.c
+++ b/test/mpi/basic/wtime.c
@@ -5,7 +5,7 @@
*/
#include "mpi.h"
#include <stdio.h>
-#include <unistd.h>
+#include "mpitest.h"
int main(int argc, char *argv[])
{
@@ -16,7 +16,7 @@ int main(int argc, char *argv[])
MPI_Comm_rank(MPI_COMM_WORLD, &i);
dStart = MPI_Wtime();
- sleep(1);
+ MTestSleep(1);
dFinish = MPI_Wtime();
dDuration = dFinish - dStart;
diff --git a/test/mpi/errors/faults/pt2ptf2.c b/test/mpi/errors/faults/pt2ptf2.c
index 248eb28..0808ac2 100644
--- a/test/mpi/errors/faults/pt2ptf2.c
+++ b/test/mpi/errors/faults/pt2ptf2.c
@@ -7,7 +7,6 @@
#include "mpi.h"
#include <stdio.h>
#include <stdlib.h>
-#include <unistd.h>
#include "mpitest.h"
/*
@@ -49,7 +48,7 @@ int main( int argc, char *argv[] )
else {
/* To improve the chance that the "faulted" processes will have
exited, wait for 1 second */
- sleep( 1 );
+ MTestSleep( 1 );
}
/* Can we still use newcomm? */
diff --git a/test/mpi/group/gtranksperf.c b/test/mpi/group/gtranksperf.c
index 9dfb52e..98b79d2 100644
--- a/test/mpi/group/gtranksperf.c
+++ b/test/mpi/group/gtranksperf.c
@@ -9,9 +9,6 @@
#include "mpitest.h"
#include <math.h> /* for fabs(3) */
-#ifdef HAVE_UNISTD_H
-#include <unistd.h> /* for sleep(3) */
-#endif
/* Measure and compare the relative performance of MPI_Group_translate_ranks
* with small and large group2 sizes but a constant number of ranks. This
@@ -89,10 +86,10 @@ int main( int argc, char *argv[] )
MPI_Barrier(comm);
if (rank != 0) {
- sleep(10);
+ MTestSleep(10);
}
else /* rank==0 */ {
- sleep(1); /* try to avoid timing while everyone else is making syscalls */
+ MTestSleep(1); /* try to avoid timing while everyone else is making syscalls */
MPI_Group_translate_ranks(grev, size, ranks, gworld, ranksout); /*throwaway iter*/
start = MPI_Wtime();
diff --git a/test/mpi/manual/mpi_t/nem_fbox_fallback_to_queue_count.c b/test/mpi/manual/mpi_t/nem_fbox_fallback_to_queue_count.c
index c6dec0b..04c1cba 100644
--- a/test/mpi/manual/mpi_t/nem_fbox_fallback_to_queue_count.c
+++ b/test/mpi/manual/mpi_t/nem_fbox_fallback_to_queue_count.c
@@ -19,10 +19,6 @@
#include <stdio.h>
#include "mpitest.h"
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-
#define TRY(func) \
do { \
err = (func); \
@@ -41,7 +37,6 @@ MPI_T_pvar_handle fbox_handle;
/* Check that we can successfuly write to the variable. */
void blank_test()
{
- int i;
uint64_t temp[2] = { -1 };
temp[0] = 0x1234; temp[1] = 0xABCD;
@@ -92,13 +87,13 @@ void send_first_test()
* FIXME: Ideally this should use a barrier, but that uses messages
* internally and hence will sometimes screw up the asserts above.
*/
- sleep(1);
+ MTestSleep(1);
} else if (rank == 1) {
char recv_buf[BUF_COUNT];
MPI_Status status;
- sleep(1); /* see above */
+ MTestSleep(1); /* see above */
MPI_Recv(recv_buf, BUF_COUNT, MPI_CHAR, 0, 0, MPI_COMM_WORLD, &status);
MPI_Recv(recv_buf, BUF_COUNT, MPI_CHAR, 0, 0, MPI_COMM_WORLD, &status);
diff --git a/test/mpi/manual/spawntest_master.c b/test/mpi/manual/spawntest_master.c
index 62e87fd..b576649 100644
--- a/test/mpi/manual/spawntest_master.c
+++ b/test/mpi/manual/spawntest_master.c
@@ -11,7 +11,7 @@
#include "mpi.h"
#include <stdio.h>
#include <stdlib.h>
-#include <unistd.h>
+#include "mpitest.h"
#define NUM_SPAWNS 4
@@ -48,11 +48,11 @@ int main( int argc, char *argv[] ) {
MPI_Comm_free( &allcomm );
MPI_Comm_disconnect( &intercomm );
- fprintf(stdout, "%s:%d: Sleep starting; children should exit\n",
+ fprintf(stdout, "%s:%d: MTestSleep starting; children should exit\n",
__FILE__, __LINE__ );fflush(stdout);
- sleep(30);
+ MTestSleep(30);
fprintf(stdout,
- "%s:%d: Sleep done; all children should have already exited\n",
+ "%s:%d: MTestSleep done; all children should have already exited\n",
__FILE__, __LINE__ );fflush(stdout);
MPI_Finalize();
diff --git a/test/mpi/manual/testconnectserial.c b/test/mpi/manual/testconnectserial.c
index 88d3bf4..8e3fc69 100644
--- a/test/mpi/manual/testconnectserial.c
+++ b/test/mpi/manual/testconnectserial.c
@@ -11,6 +11,7 @@
#include <string.h>
#include <time.h>
#include <unistd.h>
+#include "mpitest.h"
#include "connectstuff.h"
@@ -119,7 +120,7 @@ int main( int argc, char ** argv ) {
if( expectedRank == 0 ) {
/* Cleanup on rank zero - delete some files */
- sleep( 4 );
+ MTestSleep( 4 );
unlink( actualFname );
free( actualFname );
unlink( globalFname );
diff --git a/test/mpi/threads/comm/comm_dup_deadlock.c b/test/mpi/threads/comm/comm_dup_deadlock.c
index c44b8fd..1bfc29a 100644
--- a/test/mpi/threads/comm/comm_dup_deadlock.c
+++ b/test/mpi/threads/comm/comm_dup_deadlock.c
@@ -4,7 +4,6 @@
* See COPYRIGHT in top-level directory.
*/
-#include <unistd.h>
#include <stdio.h>
#include <mpi.h>
#include "mpitest.h"
@@ -21,10 +20,6 @@
} \
} while (0)
-#ifdef HAVE_WINDOWS_H
-#define sleep(a) Sleep(a*1000)
-#endif
-
MPI_Comm comms[NUM_THREADS];
MTEST_THREAD_LOCK_TYPE comm_lock;
int rank, size;
@@ -41,7 +36,7 @@ MTEST_THREAD_RETURN_TYPE test_comm_dup(void *arg)
MPI_Comm comm, self_dup;
if (*(int*)arg == rank) {
- sleep(1);
+ MTestSleep(1);
}
MTest_thread_lock(&comm_lock);
@@ -66,7 +61,7 @@ MTEST_THREAD_RETURN_TYPE test_comm_dup(void *arg)
int main(int argc, char **argv)
{
int thread_args[NUM_THREADS];
- int i, err, provided;
+ int i, provided;
MPI_Init_thread(&argc, &argv, MPI_THREAD_MULTIPLE, &provided);
diff --git a/test/mpi/threads/comm/ctxdup.c b/test/mpi/threads/comm/ctxdup.c
index 3f3a9b3..6d3aaa8 100644
--- a/test/mpi/threads/comm/ctxdup.c
+++ b/test/mpi/threads/comm/ctxdup.c
@@ -7,7 +7,6 @@
#include "mpi.h"
#include <stdio.h>
#include <stdlib.h>
-#include <unistd.h>
#include "mpitest.h"
#include "mpithreadtest.h"
@@ -15,10 +14,6 @@
static char MTEST_Descrip[] = "Creating communications concurrently in different threads";
*/
-#ifdef HAVE_WINDOWS_H
-#define sleep(a) Sleep(a*1000)
-#endif
-
MTEST_THREAD_RETURN_TYPE dup_thread(void *);
MTEST_THREAD_RETURN_TYPE dup_thread(void *p)
@@ -88,7 +83,7 @@ int main( int argc, char *argv[] )
/* If we're odd, send to our new thread and then delay */
if (rank & 0x1) {
MPI_Ssend( buffer, 0, MPI_INT, rank, 0, MPI_COMM_WORLD );
- sleep(1);
+ MTestSleep(1);
}
MPI_Comm_dup( comm1, &comm4 );
http://git.mpich.org/mpich.git/commitdiff/803fda10de941c79e2dc1bfbcfe65d0cb…
commit 803fda10de941c79e2dc1bfbcfe65d0cb68e328f
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Tue Mar 19 20:31:46 2013 -0500
Fix Irecv race in wait/test_all/any/some err tests
This fixes a race in the ERR_IN_STATUS tests for wait/test_all/any/some
tests. In these tests, there was a race that could cause the tested
error to occur within the Irecv call, rather than the wait/test call
(expected behavior). This race was happening when MPICH_ASYNC_PROGRESS
was enabled. It should be noted that tests tests still rely on
non-standard behavior, in particular some/any calls are expected to
complete all operations. This closes ticket #1802.
Reviewer: balaji
diff --git a/test/mpi/errors/pt2pt/errinstatta.c b/test/mpi/errors/pt2pt/errinstatta.c
index 861507f..49929bd 100644
--- a/test/mpi/errors/pt2pt/errinstatta.c
+++ b/test/mpi/errors/pt2pt/errinstatta.c
@@ -47,7 +47,19 @@ int main( int argc, char *argv[] )
printf( "Error returned from Irecv\n" );
}
- /* synchronize */
+ /* Wait for Irecvs to be posted before the sender calls send. This
+ * prevents the operation from completing and returning an error in the
+ * Irecv. */
+ errval = MPI_Recv(NULL, 0, MPI_INT, src, 100, comm, MPI_STATUS_IGNORE);
+ if (errval) {
+ errs++;
+ MTestPrintError( errval );
+ printf( "Error returned from Recv\n" );
+ }
+
+ /* Wait for sends to complete at the sender before proceeding */
+ /* WARNING: This does not guarantee that the sends are ready to
+ * complete at the receiver. */
errval = MPI_Recv(NULL, 0, MPI_INT, src, 10, comm, MPI_STATUS_IGNORE);
if (errval) {
errs++;
@@ -57,6 +69,9 @@ int main( int argc, char *argv[] )
for (i=0; i<2; i++) {
s[i].MPI_ERROR = -1;
}
+
+ /* WARNING: The following assumes that Testall will complete both
+ * send/irecv pairs. This is *not* guaranteed by the MPI standard. */
errval = MPI_Testall( 2, r, &flag, s );
MPI_Error_class( errval, &errclass );
if (errclass != MPI_ERR_IN_STATUS) {
@@ -84,12 +99,15 @@ int main( int argc, char *argv[] )
}
else if (rank == src) {
+ /* Wait for Irecvs to be posted before the sender calls send */
+ MPI_Ssend( NULL, 0, MPI_INT, dest, 100, comm );
+
/* Send test messages, then send another message so that the test does
not start until we are sure that the sends have begun */
MPI_Send( b1, 10, MPI_INT, dest, 0, comm );
MPI_Send( b2, 11, MPI_INT, dest, 10, comm );
- /* synchronize */
+ /* Wait for sends to complete before proceeding to the testsome. */
MPI_Ssend( NULL, 0, MPI_INT, dest, 10, comm );
}
diff --git a/test/mpi/errors/pt2pt/errinstatts.c b/test/mpi/errors/pt2pt/errinstatts.c
index e588373..dd247f2 100644
--- a/test/mpi/errors/pt2pt/errinstatts.c
+++ b/test/mpi/errors/pt2pt/errinstatts.c
@@ -49,7 +49,19 @@ int main( int argc, char *argv[] )
printf( "Error returned from Irecv\n" );
}
- /* synchronize */
+ /* Wait for Irecvs to be posted before the sender calls send. This
+ * prevents the operation from completing and returning an error in the
+ * Irecv. */
+ errval = MPI_Recv(NULL, 0, MPI_INT, src, 100, comm, MPI_STATUS_IGNORE);
+ if (errval) {
+ errs++;
+ MTestPrintError( errval );
+ printf( "Error returned from Recv\n" );
+ }
+
+ /* Wait for sends to complete at the sender before proceeding */
+ /* WARNING: This does not guarantee that the sends are ready to
+ * complete at the receiver. */
errval = MPI_Recv(NULL, 0, MPI_INT, src, 10, comm, MPI_STATUS_IGNORE);
if (errval) {
errs++;
@@ -59,6 +71,9 @@ int main( int argc, char *argv[] )
for (i=0; i<2; i++) {
s[i].MPI_ERROR = -1;
}
+
+ /* WARNING: The following assumes that Testsome will complete both
+ * send/irecv pairs. This is *not* guaranteed by the MPI standard. */
errval = MPI_Testsome( 2, r, &outcount, indices, s );
MPI_Error_class( errval, &errclass );
if (errclass != MPI_ERR_IN_STATUS) {
@@ -89,12 +104,15 @@ int main( int argc, char *argv[] )
}
else if (rank == src) {
+ /* Wait for Irecvs to be posted before the sender calls send */
+ MPI_Ssend( NULL, 0, MPI_INT, dest, 100, comm );
+
/* Send test messages, then send another message so that the test does
not start until we are sure that the sends have begun */
MPI_Send( b1, 10, MPI_INT, dest, 0, comm );
MPI_Send( b2, 11, MPI_INT, dest, 10, comm );
- /* synchronize */
+ /* Wait for sends to complete before proceeding to the testsome. */
MPI_Ssend( NULL, 0, MPI_INT, dest, 10, comm );
}
diff --git a/test/mpi/errors/pt2pt/errinstatwa.c b/test/mpi/errors/pt2pt/errinstatwa.c
index 98a70ec..99308e4 100644
--- a/test/mpi/errors/pt2pt/errinstatwa.c
+++ b/test/mpi/errors/pt2pt/errinstatwa.c
@@ -48,7 +48,16 @@ int main( int argc, char *argv[] )
printf( "Error returned from Irecv\n" );
}
- errval = MPI_Barrier(comm);
+ /* Wait for Irecvs to be posted before the sender calls send. This
+ * prevents the operation from completing and returning an error in the
+ * Irecv. */
+ errval = MPI_Recv(NULL, 0, MPI_INT, src, 100, comm, MPI_STATUS_IGNORE);
+ if (errval) {
+ errs++;
+ MTestPrintError( errval );
+ printf( "Error returned from Recv\n" );
+ }
+
if (errval) {
errs++;
MTestPrintError( errval );
@@ -89,14 +98,11 @@ int main( int argc, char *argv[] )
}
else if (rank == src) {
- /* Send messages, then barrier so that the wait does not start
- until we are sure that the sends have begun */
+ /* Wait for Irecvs to be posted before the sender calls send */
+ MPI_Ssend( NULL, 0, MPI_INT, dest, 100, comm );
+
MPI_Send( b1, 10, MPI_INT, dest, 0, comm );
MPI_Send( b2, 11, MPI_INT, dest, 10, comm );
- MPI_Barrier(comm);
- }
- else {
- MPI_Barrier(comm);
}
MTest_Finalize( errs );
diff --git a/test/mpi/errors/pt2pt/errinstatws.c b/test/mpi/errors/pt2pt/errinstatws.c
index 21f0243..002d781 100644
--- a/test/mpi/errors/pt2pt/errinstatws.c
+++ b/test/mpi/errors/pt2pt/errinstatws.c
@@ -49,7 +49,19 @@ int main( int argc, char *argv[] )
printf( "Error returned from Irecv\n" );
}
- /* synchronize */
+ /* Wait for Irecvs to be posted before the sender calls send. This
+ * prevents the operation from completing and returning an error in the
+ * Irecv. */
+ errval = MPI_Recv(NULL, 0, MPI_INT, src, 100, comm, MPI_STATUS_IGNORE);
+ if (errval) {
+ errs++;
+ MTestPrintError( errval );
+ printf( "Error returned from Recv\n" );
+ }
+
+ /* Wait for sends to complete at the sender before proceeding */
+ /* WARNING: This does not guarantee that the sends are ready to
+ * complete at the receiver. */
errval = MPI_Recv(NULL, 0, MPI_INT, src, 10, comm, MPI_STATUS_IGNORE);
if (errval) {
errs++;
@@ -59,6 +71,9 @@ int main( int argc, char *argv[] )
for (i=0; i<2; i++) {
s[i].MPI_ERROR = -1;
}
+
+ /* WARNING: The following assumes that Waitsome will complete both
+ * send/irecv pairs. This is *not* guaranteed by the MPI standard. */
errval = MPI_Waitsome( 2, r, &outcount, indices, s );
MPI_Error_class( errval, &errclass );
if (errclass != MPI_ERR_IN_STATUS) {
@@ -88,12 +103,15 @@ int main( int argc, char *argv[] )
}
else if (rank == src) {
+ /* Wait for Irecvs to be posted before the sender calls send */
+ MPI_Ssend( NULL, 0, MPI_INT, dest, 100, comm );
+
/* Send test messages, then send another message so that the test does
not start until we are sure that the sends have begun */
MPI_Send( b1, 10, MPI_INT, dest, 0, comm );
MPI_Send( b2, 11, MPI_INT, dest, 10, comm );
- /* synchronize */
+ /* Wait for sends to complete before proceeding to the testsome. */
MPI_Ssend( NULL, 0, MPI_INT, dest, 10, comm );
}
-----------------------------------------------------------------------
Summary of changes:
test/mpi/basic/wtime.c | 4 +-
test/mpi/coll/coll6.c | 14 ++++++++----
test/mpi/errors/faults/pt2ptf2.c | 3 +-
test/mpi/errors/pt2pt/errinstatta.c | 22 ++++++++++++++++++-
test/mpi/errors/pt2pt/errinstatts.c | 22 ++++++++++++++++++-
test/mpi/errors/pt2pt/errinstatwa.c | 20 +++++++++++------
test/mpi/errors/pt2pt/errinstatws.c | 22 ++++++++++++++++++-
test/mpi/group/gtranksperf.c | 7 +----
.../mpi_t/nem_fbox_fallback_to_queue_count.c | 9 +------
test/mpi/manual/spawntest_master.c | 8 +++---
test/mpi/manual/testconnectserial.c | 3 +-
test/mpi/threads/comm/comm_dup_deadlock.c | 9 +------
test/mpi/threads/comm/ctxdup.c | 7 +-----
13 files changed, 98 insertions(+), 52 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-78-g5ac51ed
by noreply@mpich.org 15 Mar '13
by noreply@mpich.org 15 Mar '13
15 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 5ac51edf49d664d33b4a88fc6a5cebeb51950149 (commit)
via 9f3b12348c4f94bc059fcc6350a660dabb020c4e (commit)
from e04dd4b64ff618f2df58789265b741a8e9fab081 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/5ac51edf49d664d33b4a88fc6a5cebeb5…
commit 5ac51edf49d664d33b4a88fc6a5cebeb51950149
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Fri Mar 1 09:12:19 2013 -0600
Add additional wait/test cases to Req. ops. test
This adds additional cases to the request-generation RMA operations test
case that ensures the implementation correctly handles waiting on the
request inside of the same passive target epoch, a different passive
target epoch, a different fence epoch, and no epoch.
Reviewer: goodell
diff --git a/test/mpi/rma/reqops.c b/test/mpi/rma/reqops.c
index 7622dd1..ef2636f 100644
--- a/test/mpi/rma/reqops.c
+++ b/test/mpi/rma/reqops.c
@@ -172,6 +172,106 @@ int main( int argc, char *argv[] )
}
MPI_Win_unlock(0, window);
+ MPI_Barrier(MPI_COMM_WORLD);
+
+ /* Wait inside of an epoch */
+ {
+ MPI_Request pn_req[4];
+ int val[4], res;
+ const int target = 0;
+
+ MPI_Win_lock_all(0, window);
+
+ MPI_Rget_accumulate(&val[0], 1, MPI_INT, &res, 1, MPI_INT, target, 0, 1, MPI_INT, MPI_REPLACE, window, &pn_req[0]);
+ MPI_Rget(&val[1], 1, MPI_INT, target, 1, 1, MPI_INT, window, &pn_req[1]);
+ MPI_Rput(&val[2], 1, MPI_INT, target, 2, 1, MPI_INT, window, &pn_req[2]);
+ MPI_Raccumulate(&val[3], 1, MPI_INT, target, 3, 1, MPI_INT, MPI_REPLACE, window, &pn_req[3]);
+
+ assert(pn_req[0] != MPI_REQUEST_NULL);
+ assert(pn_req[1] != MPI_REQUEST_NULL);
+ assert(pn_req[2] != MPI_REQUEST_NULL);
+ assert(pn_req[3] != MPI_REQUEST_NULL);
+
+ MPI_Waitall(4, pn_req, MPI_STATUSES_IGNORE);
+
+ MPI_Win_unlock_all(window);
+ }
+
+ MPI_Barrier(MPI_COMM_WORLD);
+
+ /* Wait outside of an epoch */
+ {
+ MPI_Request pn_req[4];
+ int val[4], res;
+ const int target = 0;
+
+ MPI_Win_lock_all(0, window);
+
+ MPI_Rget_accumulate(&val[0], 1, MPI_INT, &res, 1, MPI_INT, target, 0, 1, MPI_INT, MPI_REPLACE, window, &pn_req[0]);
+ MPI_Rget(&val[1], 1, MPI_INT, target, 1, 1, MPI_INT, window, &pn_req[1]);
+ MPI_Rput(&val[2], 1, MPI_INT, target, 2, 1, MPI_INT, window, &pn_req[2]);
+ MPI_Raccumulate(&val[3], 1, MPI_INT, target, 3, 1, MPI_INT, MPI_REPLACE, window, &pn_req[3]);
+
+ assert(pn_req[0] != MPI_REQUEST_NULL);
+ assert(pn_req[1] != MPI_REQUEST_NULL);
+ assert(pn_req[2] != MPI_REQUEST_NULL);
+ assert(pn_req[3] != MPI_REQUEST_NULL);
+
+ MPI_Win_unlock_all(window);
+
+ MPI_Waitall(4, pn_req, MPI_STATUSES_IGNORE);
+ }
+
+ /* Wait in a different epoch */
+ {
+ MPI_Request pn_req[4];
+ int val[4], res;
+ const int target = 0;
+
+ MPI_Win_lock_all(0, window);
+
+ MPI_Rget_accumulate(&val[0], 1, MPI_INT, &res, 1, MPI_INT, target, 0, 1, MPI_INT, MPI_REPLACE, window, &pn_req[0]);
+ MPI_Rget(&val[1], 1, MPI_INT, target, 1, 1, MPI_INT, window, &pn_req[1]);
+ MPI_Rput(&val[2], 1, MPI_INT, target, 2, 1, MPI_INT, window, &pn_req[2]);
+ MPI_Raccumulate(&val[3], 1, MPI_INT, target, 3, 1, MPI_INT, MPI_REPLACE, window, &pn_req[3]);
+
+ assert(pn_req[0] != MPI_REQUEST_NULL);
+ assert(pn_req[1] != MPI_REQUEST_NULL);
+ assert(pn_req[2] != MPI_REQUEST_NULL);
+ assert(pn_req[3] != MPI_REQUEST_NULL);
+
+ MPI_Win_unlock_all(window);
+
+ MPI_Win_lock_all(0, window);
+ MPI_Waitall(4, pn_req, MPI_STATUSES_IGNORE);
+ MPI_Win_unlock_all(window);
+ }
+
+ /* Wait in a fence epoch */
+ {
+ MPI_Request pn_req[4];
+ int val[4], res;
+ const int target = 0;
+
+ MPI_Win_lock_all(0, window);
+
+ MPI_Rget_accumulate(&val[0], 1, MPI_INT, &res, 1, MPI_INT, target, 0, 1, MPI_INT, MPI_REPLACE, window, &pn_req[0]);
+ MPI_Rget(&val[1], 1, MPI_INT, target, 1, 1, MPI_INT, window, &pn_req[1]);
+ MPI_Rput(&val[2], 1, MPI_INT, target, 2, 1, MPI_INT, window, &pn_req[2]);
+ MPI_Raccumulate(&val[3], 1, MPI_INT, target, 3, 1, MPI_INT, MPI_REPLACE, window, &pn_req[3]);
+
+ assert(pn_req[0] != MPI_REQUEST_NULL);
+ assert(pn_req[1] != MPI_REQUEST_NULL);
+ assert(pn_req[2] != MPI_REQUEST_NULL);
+ assert(pn_req[3] != MPI_REQUEST_NULL);
+
+ MPI_Win_unlock_all(window);
+
+ MPI_Win_fence(0, window);
+ MPI_Waitall(4, pn_req, MPI_STATUSES_IGNORE);
+ MPI_Win_fence(0, window);
+ }
+
MPI_Win_free(&window);
if (buf) MPI_Free_mem(buf);
http://git.mpich.org/mpich.git/commitdiff/9f3b12348c4f94bc059fcc6350a660dab…
commit 9f3b12348c4f94bc059fcc6350a660dabb020c4e
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Fri Mar 15 14:14:44 2013 -0500
Fix req. op. completion outside of PT epoch
This is a temporary fix for request-generating operations to allow their
requests to be completed after the user has called unlock on the given
target. This closes ticket #1801. Ticket #1741 is still active and is
keeping track of the fact that an implementation of req. ops that tracks
and completes individual operations (rather than the current approach,
which just calls flush) is still needed.
Reviewer: goodell
diff --git a/src/mpid/ch3/src/ch3u_rma_reqops.c b/src/mpid/ch3/src/ch3u_rma_reqops.c
index 09cf9d9..acfe1cb 100644
--- a/src/mpid/ch3/src/ch3u_rma_reqops.c
+++ b/src/mpid/ch3/src/ch3u_rma_reqops.c
@@ -30,10 +30,16 @@ static int MPIDI_CH3I_Rma_req_poll(void *state, MPI_Status *status)
MPIU_UNREFERENCED_ARG(status);
- /* Call flush to complete the operation */
+ /* Call flush to complete the operation. Check that a passive target epoch
+ * is still active first; the user could complete the request after calling
+ * unlock. */
/* FIXME: We need per-operation completion to make this more efficient. */
- mpi_errno = req_state->win_ptr->RMAFns.Win_flush(req_state->target_rank,
- req_state->win_ptr);
+ if (req_state->win_ptr->targets[req_state->target_rank].remote_lock_state
+ != MPIDI_CH3_WIN_LOCK_NONE)
+ {
+ mpi_errno = req_state->win_ptr->RMAFns.Win_flush(req_state->target_rank,
+ req_state->win_ptr);
+ }
if (mpi_errno != MPI_SUCCESS) { MPIU_ERR_POP(mpi_errno); }
-----------------------------------------------------------------------
Summary of changes:
src/mpid/ch3/src/ch3u_rma_reqops.c | 12 +++-
test/mpi/rma/reqops.c | 100 ++++++++++++++++++++++++++++++++++++
2 files changed, 109 insertions(+), 3 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-76-ge04dd4b
by noreply@mpich.org 15 Mar '13
by noreply@mpich.org 15 Mar '13
15 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via e04dd4b64ff618f2df58789265b741a8e9fab081 (commit)
from 4b6df5cd56f9044a03f8ed421b7e8e293ffac286 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/e04dd4b64ff618f2df58789265b741a8e…
commit e04dd4b64ff618f2df58789265b741a8e9fab081
Author: Pavan Balaji <balaji(a)mcs.anl.gov>
Date: Tue Mar 12 11:02:07 2013 -0500
Bug-fix: correct MPIR_proctable setup when we use wraparound ranks.
As reported by John DelSignore @ Roguewave, when we wraparound ranks
among nodes, we were not allocating the MPIR_proctable structure in
rank order. We were always grouping them per node.
Reviewed by dinan.
diff --git a/src/pm/hydra/tools/debugger/debugger.c b/src/pm/hydra/tools/debugger/debugger.c
index 3637343..b5449dd 100644
--- a/src/pm/hydra/tools/debugger/debugger.c
+++ b/src/pm/hydra/tools/debugger/debugger.c
@@ -28,7 +28,7 @@ HYD_status HYDT_dbg_setup_procdesc(struct HYD_pg * pg)
{
struct HYD_proxy *proxy;
struct HYD_exec *exec;
- int i, j, np;
+ int i, j, k, np, round;
HYD_status status = HYD_SUCCESS;
HYDU_FUNC_ENTER();
@@ -36,10 +36,27 @@ HYD_status HYDT_dbg_setup_procdesc(struct HYD_pg * pg)
HYDU_MALLOC(MPIR_proctable, struct MPIR_PROCDESC *,
pg->pg_process_count * sizeof(struct MPIR_PROCDESC), status);
- for (proxy = pg->proxy_list, i = 0; proxy; proxy = proxy->next) {
+ round = 0;
+ /* We need to allocate the MPIR_proctable in COMM_WORLD rank
+ * order. We do this in multiple rounds. In each round, we
+ * allocate the proctable entries for the executables on the proxy
+ * that form a contiguous rank list. Then we move to the next
+ * proxy. When we run out of proxies, we go back to the first
+ * proxy and find the next set of contiguous ranks on that
+ * proxy. */
+ for (proxy = pg->proxy_list, i = 0;; proxy = proxy->next) {
j = 0;
+ k = 0;
+ if (!proxy) {
+ proxy = pg->proxy_list;
+ round++;
+ }
for (exec = proxy->exec_list; exec; exec = exec->next) {
for (np = 0; np < exec->proc_count; np++) {
+ if (k + np >= ((round + 1) * proxy->node->core_count))
+ break;
+ if (k + np < round * proxy->node->core_count)
+ continue;
MPIR_proctable[i].host_name = HYDU_strdup(proxy->node->hostname);
MPIR_proctable[i].pid = proxy->pid[j++];
if (exec->exec[0])
@@ -48,7 +65,11 @@ HYD_status HYDT_dbg_setup_procdesc(struct HYD_pg * pg)
MPIR_proctable[i].executable_name = NULL;
i++;
}
+ k += exec->proc_count;
}
+
+ if (i >= pg->pg_process_count)
+ break;
}
MPIR_proctable_size = pg->pg_process_count;
-----------------------------------------------------------------------
Summary of changes:
src/pm/hydra/tools/debugger/debugger.c | 25 +++++++++++++++++++++++--
1 files changed, 23 insertions(+), 2 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-75-g4b6df5c
by noreply@mpich.org 12 Mar '13
by noreply@mpich.org 12 Mar '13
12 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 4b6df5cd56f9044a03f8ed421b7e8e293ffac286 (commit)
from 0f6085639368dc008cf18ca4c85cdc00b880d02b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/4b6df5cd56f9044a03f8ed421b7e8e293…
commit 4b6df5cd56f9044a03f8ed421b7e8e293ffac286
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 12 19:28:55 2013 -0500
`--enable-g=all` now means _all_, add `=most`
Before this commit `--enable-g` meant `--enable-g=all`, which actually
turned on all debugging options *except* `memarena` and `handle`.
As of this commit:
* `most` is a new valid debug option having the old effect of
`all,handle`
* `all` really means everything now, including `memarena` and `handle`
* `--enable-g` with no `=BLAH` means `most`
Reviewed by balaji@.
diff --git a/configure.ac b/configure.ac
index e3a2b43..d135372 100644
--- a/configure.ac
+++ b/configure.ac
@@ -352,8 +352,8 @@ AC_ARG_ENABLE(timing,
AC_ARG_ENABLE(g,
[ --enable-g=option - Control the level of debugging support in the
- MPICH implementation. option is a list of comma
- separated names including
+ MPICH implementation. "option" is a list of comma
+ separated names including. Default is "most".
none - No debugging
handle - Trace handle operations
handlealloc - Trace handle allocations
@@ -369,6 +369,9 @@ AC_ARG_ENABLE(g,
memarena - Check for overwrite errors in memory allocation arena
mutex - Enable error checking on pthread mutexes
mutexnesting - Check for non-nesting of mutexes
+ most - Most of the above options, excluding some with severe
+ performance impacts. Recommended for typical development.
+ yes - synonym for "most" (*not* "all")
all - All of the above choices
],,enable_g=none)
@@ -1372,7 +1375,7 @@ for option in $enable_g ; do
perform_handlealloc=yes
;;
handle)
- AC_DEFINE(MPICH_DEBUG_HANDLES,1,[Define to enable handle checking])
+ perform_handle=yes
;;
instr)
perform_instr=yes
@@ -1396,7 +1399,19 @@ for option in $enable_g ; do
mutexnesting)
perform_mutexnesting=yes
;;
- all|yes)
+ most|yes)
+ perform_memtracing=yes
+ perform_dbglog=yes
+ enable_append_g=yes
+ perform_meminit=yes
+ perform_instr=yes
+ perform_dbgmutex=yes
+ perform_mutexnesting=yes
+ perform_handlealloc=yes
+ perform_handle=yes
+ ;;
+ all)
+ perform_memarena=yes
perform_memtracing=yes
perform_dbglog=yes
enable_append_g=yes
@@ -1405,6 +1420,7 @@ for option in $enable_g ; do
perform_dbgmutex=yes
perform_mutexnesting=yes
perform_handlealloc=yes
+ perform_handle=yes
;;
*)
IFS=$save_IFS
@@ -1437,6 +1453,8 @@ fi
if test "$perform_instr" = yes ; then
AC_DEFINE(USE_MPIU_INSTR,1,[Define this to enable internal instrumentation] )
fi
+AS_IF([test "X$perform_handle" = "Xyes"],
+ [AC_DEFINE(MPICH_DEBUG_HANDLES,1,[Define to enable handle checking])])
if test -n "$perform_memtracing" ; then
enable_g_mem=yes
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 26 ++++++++++++++++++++++----
1 files changed, 22 insertions(+), 4 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-74-g0f60856
by noreply@mpich.org 07 Mar '13
by noreply@mpich.org 07 Mar '13
07 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 0f6085639368dc008cf18ca4c85cdc00b880d02b (commit)
from 115fc21aff37499f35ebde653833103c0f5a963a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/0f6085639368dc008cf18ca4c85cdc00b…
commit 0f6085639368dc008cf18ca4c85cdc00b880d02b
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Thu Mar 7 14:29:15 2013 -0600
fix `complex<long double>` bug from [3f1fcead]
If C++ is disabled or the C++ compiler does not support
`complex<long double>`, then bad Fortran code would be emitted into
`mpif.h`.
No reviewer.
diff --git a/configure.ac b/configure.ac
index 4a80c12..e3a2b43 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4185,10 +4185,10 @@ MPIR_CXX_BOOL=0x0c000000
MPIR_CXX_COMPLEX=0x0c000000
MPIR_CXX_DOUBLE_COMPLEX=0x0c000000
MPIR_CXX_LONG_DOUBLE_COMPLEX=0x0c000000
-MPI_F77_CXX_BOOL=0x0c000000
-MPI_F77_CXX_FLOAT_COMPLEX=0x0c000000
-MPI_F77_CXX_DOUBLE_COMPLEX=0x0c000000
-MPI_F77_CXX_LONG_DOUBLE_COMPLEX=0x0c000000
+MPI_F77_CXX_BOOL=MPI_DATATYPE_NULL
+MPI_F77_CXX_FLOAT_COMPLEX=MPI_DATATYPE_NULL
+MPI_F77_CXX_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
+MPI_F77_CXX_LONG_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
if test "$enable_cxx" = "yes" ; then
AC_LANG_CPLUSPLUS
AC_CHECK_SIZEOF(bool)
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-73-g115fc21
by noreply@mpich.org 06 Mar '13
by noreply@mpich.org 06 Mar '13
06 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 115fc21aff37499f35ebde653833103c0f5a963a (commit)
via 429bc280abd3d8c32831c8b2e7b1c5c758cd4afb (commit)
from 0feb67a6f283f922f008717d138162c2059dad05 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/115fc21aff37499f35ebde653833103c0…
commit 115fc21aff37499f35ebde653833103c0f5a963a
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Wed Mar 6 09:26:45 2013 -0600
fix `long double _Complex` logic from [a9305613]
No reviewer.
diff --git a/configure.ac b/configure.ac
index 186246e..4a80c12 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2949,7 +2949,7 @@ AC_CHECK_SIZEOF([double _Complex],0,[
#include <complex.h>
#endif
])
-AS_IF(["X$pac_cv_have_long_double" = "Xyes"],[
+AS_IF([test "X$pac_cv_have_long_double" = "Xyes"],[
AC_CHECK_SIZEOF([long double _Complex],0,[
#ifdef HAVE_COMPLEX_H
#include <complex.h>
@@ -2961,7 +2961,7 @@ AS_IF(["X$pac_cv_have_long_double" = "Xyes"],[
# HAVE_typename macro is useful for consistency
AC_CHECK_TYPES([_Bool, float _Complex, double _Complex])
-AS_IF(["X$pac_cv_have_long_double" = "Xyes"],[
+AS_IF([test "X$pac_cv_have_long_double" = "Xyes"],[
AC_CHECK_TYPES([long double _Complex])
])
http://git.mpich.org/mpich.git/commitdiff/429bc280abd3d8c32831c8b2e7b1c5c75…
commit 429bc280abd3d8c32831c8b2e7b1c5c758cd4afb
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Wed Mar 6 09:10:28 2013 -0600
tests: gate `long double _Complex`
We should not support `long double _Complex` if we don't support `long
double`.
No reviewer.
diff --git a/test/mpi/configure.ac b/test/mpi/configure.ac
index 0106e6c..09b0427 100644
--- a/test/mpi/configure.ac
+++ b/test/mpi/configure.ac
@@ -541,8 +541,9 @@ AC_TYPE_UINT64_T
AC_CHECK_TYPES([_Bool, float _Complex, double _Complex, long double _Complex])
# Only run the long double complex tests if that type is available
-if test "$enable_long_double_complex" != "no" -a \
- "x$ac_cv_type_long_double__Complex" = "xyes" ; then
+if test "x$enable_long_double" = "xyes" && \
+ test "x$enable_long_double_complex" = "xyes" && \
+ test "x$ac_cv_type_long_double__Complex" = "xyes" ; then
AC_DEFINE(USE_LONG_DOUBLE_COMPLEX,1,[Define if tests with long double complex should be included])
fi
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 4 ++--
test/mpi/configure.ac | 5 +++--
2 files changed, 5 insertions(+), 4 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-71-g0feb67a
by noreply@mpich.org 05 Mar '13
by noreply@mpich.org 05 Mar '13
05 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 0feb67a6f283f922f008717d138162c2059dad05 (commit)
via 909399515d55620e2469bef20d0cf06bac57ddfc (commit)
via 71552aac5b704eea8b343dce699f8a2288d1bf3f (commit)
via a93056137603ec9a62b43f9c4bcc4bffb593b913 (commit)
via afe8c4a468b0f381a8135679afb4bad542e72d5f (commit)
via 3f1fcead9a9f2ae4013cfa931dc31cd41663f7fd (commit)
via d9db47aee320b83ddf4f448f38a6278c9e3467a8 (commit)
from bba79775fd322347bed3a8231c626061373e271f (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/0feb67a6f283f922f008717d138162c20…
commit 0feb67a6f283f922f008717d138162c2059dad05
Merge: bba7977 9093995
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 18:04:21 2013 -0600
Merge branch 'fix-long-double'
Numerous fixes related to `long double` support, including selectively
enabling/disabling it.
http://git.mpich.org/mpich.git/commitdiff/909399515d55620e2469bef20d0cf06ba…
commit 909399515d55620e2469bef20d0cf06bac57ddfc
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 16:54:19 2013 -0600
mpi.h: guard `long double`-derived MPI types
Probably not too harmful to omit the guards, but better not to jumble
more constants together in the compiler's type-checking machinery.
No reviewer.
diff --git a/src/include/mpi.h.in b/src/include/mpi.h.in
index 00e086b..4a848ad 100644
--- a/src/include/mpi.h.in
+++ b/src/include/mpi.h.in
@@ -126,7 +126,9 @@ static const MPI_Datatype mpich_mpi_long MPICH_ATTR_TYPE_TAG(long)
static const MPI_Datatype mpich_mpi_unsigned_long MPICH_ATTR_TYPE_TAG(unsigned long) = MPI_UNSIGNED_LONG;
static const MPI_Datatype mpich_mpi_float MPICH_ATTR_TYPE_TAG(float) = MPI_FLOAT;
static const MPI_Datatype mpich_mpi_double MPICH_ATTR_TYPE_TAG(double) = MPI_DOUBLE;
+#if @MPI_LONG_DOUBLE@ != 0x0c000000
static const MPI_Datatype mpich_mpi_long_double MPICH_ATTR_TYPE_TAG(long double) = MPI_LONG_DOUBLE;
+#endif
static const MPI_Datatype mpich_mpi_long_long_int MPICH_ATTR_TYPE_TAG(long long int) = MPI_LONG_LONG_INT;
static const MPI_Datatype mpich_mpi_unsigned_long_long MPICH_ATTR_TYPE_TAG(unsigned long long) = MPI_UNSIGNED_LONG_LONG;
#endif
@@ -156,15 +158,19 @@ struct mpich_struct_mpi_double_int { double d; int i; };
struct mpich_struct_mpi_long_int { long l; int i; };
struct mpich_struct_mpi_short_int { short s; int i; };
struct mpich_struct_mpi_2int { int i1; int i2; };
+#if @MPI_LONG_DOUBLE_INT@ != 0x0c000000
struct mpich_struct_mpi_long_double_int { long double ld; int i; };
+#endif
static const MPI_Datatype mpich_mpi_float_int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_float_int) = MPI_FLOAT_INT;
static const MPI_Datatype mpich_mpi_double_int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_double_int) = MPI_DOUBLE_INT;
static const MPI_Datatype mpich_mpi_long_int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_long_int) = MPI_LONG_INT;
static const MPI_Datatype mpich_mpi_short_int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_short_int) = MPI_SHORT_INT;
static const MPI_Datatype mpich_mpi_2int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_2int) = MPI_2INT;
+#if @MPI_LONG_DOUBLE_INT@ != 0x0c000000
static const MPI_Datatype mpich_mpi_long_double_int MPICH_ATTR_TYPE_TAG_LAYOUT_COMPATIBLE(struct mpich_struct_mpi_long_double_int) = MPI_LONG_DOUBLE_INT;
#endif
+#endif
/* Fortran types */
#define MPI_COMPLEX ((MPI_Datatype)@MPI_COMPLEX@)
@@ -234,8 +240,10 @@ static const MPI_Datatype mpich_mpi_uint64_t MPICH_ATTR_TYPE_TAG_STDINT(uint64_t
static const MPI_Datatype mpich_mpi_c_bool MPICH_ATTR_TYPE_TAG_C99(_Bool) = MPI_C_BOOL;
static const MPI_Datatype mpich_mpi_c_float_complex MPICH_ATTR_TYPE_TAG_C99(float _Complex) = MPI_C_FLOAT_COMPLEX;
static const MPI_Datatype mpich_mpi_c_double_complex MPICH_ATTR_TYPE_TAG_C99(double _Complex) = MPI_C_DOUBLE_COMPLEX;
+#if @MPI_C_LONG_DOUBLE_COMPLEX@ != 0x0c000000
static const MPI_Datatype mpich_mpi_c_long_double_complex MPICH_ATTR_TYPE_TAG_C99(long double _Complex) = MPI_C_LONG_DOUBLE_COMPLEX;
#endif
+#endif
/* address/offset types */
#define MPI_AINT ((MPI_Datatype)@MPI_AINT_DATATYPE@)
http://git.mpich.org/mpich.git/commitdiff/71552aac5b704eea8b343dce699f8a228…
commit 71552aac5b704eea8b343dce699f8a2288d1bf3f
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 16:53:34 2013 -0600
clang annotations: fix `long double _Complex'
Obvious bug.
No reviewer.
diff --git a/src/include/mpi.h.in b/src/include/mpi.h.in
index 30a356f..00e086b 100644
--- a/src/include/mpi.h.in
+++ b/src/include/mpi.h.in
@@ -234,7 +234,7 @@ static const MPI_Datatype mpich_mpi_uint64_t MPICH_ATTR_TYPE_TAG_STDINT(uint64_t
static const MPI_Datatype mpich_mpi_c_bool MPICH_ATTR_TYPE_TAG_C99(_Bool) = MPI_C_BOOL;
static const MPI_Datatype mpich_mpi_c_float_complex MPICH_ATTR_TYPE_TAG_C99(float _Complex) = MPI_C_FLOAT_COMPLEX;
static const MPI_Datatype mpich_mpi_c_double_complex MPICH_ATTR_TYPE_TAG_C99(double _Complex) = MPI_C_DOUBLE_COMPLEX;
-static const MPI_Datatype mpich_mpi_c_long_double_complex MPICH_ATTR_TYPE_TAG_C99(double _Complex) = MPI_C_LONG_DOUBLE_COMPLEX;
+static const MPI_Datatype mpich_mpi_c_long_double_complex MPICH_ATTR_TYPE_TAG_C99(long double _Complex) = MPI_C_LONG_DOUBLE_COMPLEX;
#endif
/* address/offset types */
http://git.mpich.org/mpich.git/commitdiff/a93056137603ec9a62b43f9c4bcc4bffb…
commit a93056137603ec9a62b43f9c4bcc4bffb593b913
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 16:17:54 2013 -0600
`long double _Complex` depends on `long double`
It was possible to have a working `long double _Complex` even if the MPI
library was pretending that `long double` should not work.
Ditto for the C++ version.
No reviewer.
diff --git a/configure.ac b/configure.ac
index 8c96fe4..186246e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2949,14 +2949,21 @@ AC_CHECK_SIZEOF([double _Complex],0,[
#include <complex.h>
#endif
])
-AC_CHECK_SIZEOF([long double _Complex],0,[
+AS_IF(["X$pac_cv_have_long_double" = "Xyes"],[
+ AC_CHECK_SIZEOF([long double _Complex],0,[
#ifdef HAVE_COMPLEX_H
#include <complex.h>
#endif
+ ])
])
+
# we need really could just use the result of AC_CHECK_SIZEOF, but having a
# HAVE_typename macro is useful for consistency
-AC_CHECK_TYPES([_Bool, float _Complex, double _Complex, long double _Complex])
+AC_CHECK_TYPES([_Bool, float _Complex, double _Complex])
+
+AS_IF(["X$pac_cv_have_long_double" = "Xyes"],[
+ AC_CHECK_TYPES([long double _Complex])
+])
# Generate a hex version of the size of each type
for type in short int long long_long float double long_double wchar_t \
@@ -4264,13 +4271,17 @@ using namespace std;
32) MPIR_CXX_DOUBLE_COMPLEX=0x4c002035 ;;
*) ;;
esac
- case "$ac_cv_sizeof_LongDoubleComplex" in
- 8) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c000836 ;;
- 16) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c001036 ;;
- 24) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c001836 ;;
- 32) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c002036 ;;
- *) ;;
- esac
+ # only enable CXX "long double" if we have a C "long double", since we
+ # currently perform reductions on CXX "long double" types via C.
+ if test "X$pac_cv_have_long_double" = "Xyes" ; then
+ case "$ac_cv_sizeof_LongDoubleComplex" in
+ 8) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c000836 ;;
+ 16) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c001036 ;;
+ 24) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c001836 ;;
+ 32) MPIR_CXX_LONG_DOUBLE_COMPLEX=0x4c002036 ;;
+ *) ;;
+ esac
+ fi
fi
AC_LANG_C
http://git.mpich.org/mpich.git/commitdiff/afe8c4a468b0f381a8135679afb4bad54…
commit afe8c4a468b0f381a8135679afb4bad542e72d5f
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 16:03:49 2013 -0600
configure: add `--disable-long-double`
This helps Cray out (and conceivably other vendors), since they ship
several compilers which have different interpretations of what `long
double` should mean (80-bit vs. 128-bit, being most common).
Note that exporting `MPID_NO_LONG_DOUBLE=yes` in the environment before
running `configure` does work, but may not work as intended in the face
of an automake-initiated reconfigure. Autoconf does not treat this
variable as precious (and we don't ask it to, since it's for
inside-configure-use only), so its value will not be preserved for the
reconfigure. The same holds for any `MPID_` variables mentioned at the
top of `configure.ac`.
No reviewer.
diff --git a/configure.ac b/configure.ac
index 98a918b..8c96fe4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -588,6 +588,16 @@ AC_ARG_ENABLE([wrapper-rpath],
[],[enable_wrapper_rpath=yes])
AC_SUBST([enable_wrapper_rpath])
+AC_ARG_ENABLE([long-double],
+ [AC_HELP_STRING([--disable-long-double],
+ [Pass --disable-long-double to prevent the MPI
+ library from supporting the C "long double" type,
+ even if the C compiler supports it. "long
+ double" support is enabled by default, provided
+ the compiler supports it.])],
+ [],
+ [enable_long_double=yes])
+
AC_ARG_WITH(cross,
AC_HELP_STRING([--with-cross=file],
[Specify the values of variables that configure cannot
@@ -2696,7 +2706,7 @@ fi
# types as well. In addition, allow the device to suppress support for these
# optional C types by setting MPID_NO_LONG_DOUBLE and/or MPID_NO_LONG_LONG
# to yes.
-if test "$MPID_NO_LONG_DOUBLE" != "yes" ; then
+if test "$MPID_NO_LONG_DOUBLE" != "yes" && test "X$enable_long_double" != "Xno" ; then
AC_CACHE_CHECK([whether long double is supported],
pac_cv_have_long_double,[
AC_TRY_COMPILE(,[long double a;],
http://git.mpich.org/mpich.git/commitdiff/3f1fcead9a9f2ae4013cfa931dc31cd41…
commit 3f1fcead9a9f2ae4013cfa931dc31cd41663f7fd
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 15:39:29 2013 -0600
fix compile error when `long double` is disabled
Otherwise `oputil.h` barfs on a bad preprocessor comparison when
`MPID_NO_LONG_DOUBLE` is set.
Fix reported by and suggested by Steve Oyanagi from Cray.
No reviewer.
diff --git a/configure.ac b/configure.ac
index e3cd063..98a918b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4161,14 +4161,17 @@ fi
# C++ types
# default to null types
-MPIR_CXX_BOOL=MPI_DATATYPE_NULL
-MPIR_CXX_COMPLEX=MPI_DATATYPE_NULL
-MPIR_CXX_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
-MPIR_CXX_LONG_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
-MPI_F77_CXX_BOOL=MPI_DATATYPE_NULL
-MPI_F77_CXX_FLOAT_COMPLEX=MPI_DATATYPE_NULL
-MPI_F77_CXX_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
-MPI_F77_CXX_LONG_DOUBLE_COMPLEX=MPI_DATATYPE_NULL
+# Set to "0x0c000000" instead of "MPI_DATATYPE_NULL" because these values
+# sometimes are used in preprocessor tests where we cannot compare the
+# type-casted values.
+MPIR_CXX_BOOL=0x0c000000
+MPIR_CXX_COMPLEX=0x0c000000
+MPIR_CXX_DOUBLE_COMPLEX=0x0c000000
+MPIR_CXX_LONG_DOUBLE_COMPLEX=0x0c000000
+MPI_F77_CXX_BOOL=0x0c000000
+MPI_F77_CXX_FLOAT_COMPLEX=0x0c000000
+MPI_F77_CXX_DOUBLE_COMPLEX=0x0c000000
+MPI_F77_CXX_LONG_DOUBLE_COMPLEX=0x0c000000
if test "$enable_cxx" = "yes" ; then
AC_LANG_CPLUSPLUS
AC_CHECK_SIZEOF(bool)
http://git.mpich.org/mpich.git/commitdiff/d9db47aee320b83ddf4f448f38a6278c9…
commit d9db47aee320b83ddf4f448f38a6278c9e3467a8
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 16:16:25 2013 -0600
move `_NULL` handle definitions earlier in mpi.h
In particular, the clang type checking helpers can cause
`MPI_DATATYPE_NULL` to be used before it has been `#define`d.
No reviewer.
diff --git a/src/include/mpi.h.in b/src/include/mpi.h.in
index 4487bfd..30a356f 100644
--- a/src/include/mpi.h.in
+++ b/src/include/mpi.h.in
@@ -76,6 +76,17 @@ extern "C" {
# define MPICH_ATTR_TYPE_TAG_CXX(type)
#endif
+
+/* Define some null objects */
+#define MPI_COMM_NULL ((MPI_Comm)0x04000000)
+#define MPI_OP_NULL ((MPI_Op)0x18000000)
+#define MPI_GROUP_NULL ((MPI_Group)0x08000000)
+#define MPI_DATATYPE_NULL ((MPI_Datatype)0x0c000000)
+#define MPI_REQUEST_NULL ((MPI_Request)0x2c000000)
+#define MPI_ERRHANDLER_NULL ((MPI_Errhandler)0x14000000)
+#define MPI_MESSAGE_NULL ((MPI_Message)MPI_REQUEST_NULL)
+#define MPI_MESSAGE_NO_PROC ((MPI_Message)0x6c000000)
+
/* Results of the compare operations. */
#define MPI_IDENT 0
#define MPI_CONGRUENT 1
@@ -310,16 +321,6 @@ typedef int MPI_Op;
#define MPI_WIN_CREATE_FLAVOR 0x66000007
#define MPI_WIN_MODEL 0x66000009
-/* Define some null objects */
-#define MPI_COMM_NULL ((MPI_Comm)0x04000000)
-#define MPI_OP_NULL ((MPI_Op)0x18000000)
-#define MPI_GROUP_NULL ((MPI_Group)0x08000000)
-#define MPI_DATATYPE_NULL ((MPI_Datatype)0x0c000000)
-#define MPI_REQUEST_NULL ((MPI_Request)0x2c000000)
-#define MPI_ERRHANDLER_NULL ((MPI_Errhandler)0x14000000)
-#define MPI_MESSAGE_NULL ((MPI_Message)MPI_REQUEST_NULL)
-#define MPI_MESSAGE_NO_PROC ((MPI_Message)0x6c000000)
-
#ifdef MPICH_DEFINE_ATTR_TYPE_TYPES
static const MPI_Datatype mpich_mpi_datatype_null MPICH_ATTR_TYPE_TAG_MUST_BE_NULL() = MPI_DATATYPE_NULL;
#endif
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 60 +++++++++++++++++++++++++++++++++++---------------
src/include/mpi.h.in | 31 ++++++++++++++++---------
2 files changed, 62 insertions(+), 29 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-64-gbba7977
by noreply@mpich.org 05 Mar '13
by noreply@mpich.org 05 Mar '13
05 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via bba79775fd322347bed3a8231c626061373e271f (commit)
from 193f2f69d6fe5e3b05c1c35772edccefbcda9ef9 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/bba79775fd322347bed3a8231c6260613…
commit bba79775fd322347bed3a8231c626061373e271f
Author: Dave Goodell <goodell(a)mcs.anl.gov>
Date: Tue Mar 5 18:01:16 2013 -0600
.gitignore: fixup for [006dd97e]
diff --git a/.gitignore b/.gitignore
index 60ce4db..ea06e48 100644
--- a/.gitignore
+++ b/.gitignore
@@ -160,6 +160,7 @@ Makefile.am-stamp
/test/mpi/f90/rma/Makefile.am
/test/mpi/errors/f90/errhan/Makefile.am
/test/mpi/errors/f90/errhan/testlist
+/test/mpi/errors/f90/errhan/uerrhandf90.f90
# created solely from the f77 counterpart dirs
/test/mpi/f90/coll/
-----------------------------------------------------------------------
Summary of changes:
.gitignore | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-63-g193f2f6
by noreply@mpich.org 01 Mar '13
by noreply@mpich.org 01 Mar '13
01 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 193f2f69d6fe5e3b05c1c35772edccefbcda9ef9 (commit)
from 0b9da88e2e80be4a25bc9142b14bbdcf25ad7804 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/193f2f69d6fe5e3b05c1c35772edccefb…
commit 193f2f69d6fe5e3b05c1c35772edccefbcda9ef9
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Fri Mar 1 09:18:35 2013 -0600
Cleanup comment in rmazero test
diff --git a/test/mpi/rma/rmazero.c b/test/mpi/rma/rmazero.c
index 4792656..0ea28d7 100644
--- a/test/mpi/rma/rmazero.c
+++ b/test/mpi/rma/rmazero.c
@@ -127,10 +127,8 @@ int main( int argc, char *argv[] )
MPI_Abort( MPI_COMM_WORLD, 1 );
}
- /* The following illustrates the use of the routines to
- run through a selection of communicators and datatypes.
- Use subsets of these for tests that do not involve combinations
- of communicators, datatypes, and counts of datatypes */
+ /* The following loop is used to run through a series of communicators
+ * that are subsets of MPI_COMM_WORLD, of size 1 or greater. */
while (MTestGetIntracommGeneral( &comm, 1, 1 )) {
int count = 0;
-----------------------------------------------------------------------
Summary of changes:
test/mpi/rma/rmazero.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
hooks/post-receive
--
MPICH primary repository
1
0
[mpich] MPICH primary repository branch, master, updated. v3.0.2-62-g0b9da88
by noreply@mpich.org 01 Mar '13
by noreply@mpich.org 01 Mar '13
01 Mar '13
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via 0b9da88e2e80be4a25bc9142b14bbdcf25ad7804 (commit)
via ab38c94853c55283bc6334a5c5bd6652f83a7e96 (commit)
via 4611dedbefb197248718c4dd33669e77ec3cdceb (commit)
via 9931e2a433f22ffb15b0fed721ae371f39537f90 (commit)
via a77f0eac2460e292b1417c087b86c1620a73c4bb (commit)
from f5be9cdbf563dd55fa935967903241038ed60fae (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/0b9da88e2e80be4a25bc9142b14bbdcf2…
commit 0b9da88e2e80be4a25bc9142b14bbdcf25ad7804
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Feb 28 15:32:56 2013 -0600
Test handling of 0-byte RMA xfers
Added a new test to check that 0-byte transfers are handled correctly.
Reviewer: goodell
diff --git a/test/mpi/rma/Makefile.am b/test/mpi/rma/Makefile.am
index eb5b8d6..d919c83 100644
--- a/test/mpi/rma/Makefile.am
+++ b/test/mpi/rma/Makefile.am
@@ -66,6 +66,7 @@ noinst_PROGRAMS = \
baseattrwin \
nullpscw \
rmanull \
+ rmazero \
mixedsync \
manyrma2 \
selfrma \
diff --git a/test/mpi/rma/rmazero.c b/test/mpi/rma/rmazero.c
new file mode 100644
index 0000000..4792656
--- /dev/null
+++ b/test/mpi/rma/rmazero.c
@@ -0,0 +1,222 @@
+/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */
+/*
+ *
+ * (C) 2013 by Argonne National Laboratory.
+ * See COPYRIGHT in top-level directory.
+ */
+#include "mpi.h"
+#include <stdio.h>
+#include <stdlib.h>
+#include "mpitest.h"
+
+#define TARGET 0
+
+/* Test the given operation within a Fence epoch */
+#define TEST_FENCE_OP(op_name_, fcn_call_) \
+ do { \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Zero-byte op " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_fence( 0, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Fence after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
+
+/* Test the given operation within a passive target epoch */
+#define TEST_PT_OP(op_name_, fcn_call_) \
+ do { \
+ err = MPI_Win_lock(MPI_LOCK_EXCLUSIVE, TARGET, 0, win); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Lock before" op_name_, err ); \
+ } \
+ } \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Zero-byte op " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_unlock( TARGET, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Unlock after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
+
+/* Test the given request-based operation within a passive target epoch */
+#define TEST_REQ_OP(op_name_, req_, fcn_call_) \
+ do { \
+ err = MPI_Win_lock(MPI_LOCK_EXCLUSIVE, TARGET, 0, win); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Lock before" op_name_, err ); \
+ } \
+ } \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Zero-byte op " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_unlock( TARGET, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Unlock after " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Wait( &req_, MPI_STATUS_IGNORE ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Wait after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
+/*
+static char MTEST_Descrip[] = "Test handling of zero-byte transfers";
+*/
+
+int main( int argc, char *argv[] )
+{
+ int errs = 0, err;
+ int rank, size;
+ int *buf, bufsize;
+ int *result;
+ int *rmabuf, rsize, rcount;
+ MPI_Comm comm;
+ MPI_Win win;
+ MPI_Request req;
+
+ MTest_Init( &argc, &argv );
+
+ bufsize = 256 * sizeof(int);
+ buf = (int *)malloc( bufsize );
+ if (!buf) {
+ fprintf( stderr, "Unable to allocated %d bytes\n", bufsize );
+ MPI_Abort( MPI_COMM_WORLD, 1 );
+ }
+ result = (int *)malloc( bufsize );
+ if (!result) {
+ fprintf( stderr, "Unable to allocated %d bytes\n", bufsize );
+ MPI_Abort( MPI_COMM_WORLD, 1 );
+ }
+ rcount = 16;
+ rsize = rcount * sizeof(int);
+ rmabuf = (int *)malloc( rsize );
+ if (!rmabuf) {
+ fprintf( stderr, "Unable to allocated %d bytes\n", rsize );
+ MPI_Abort( MPI_COMM_WORLD, 1 );
+ }
+
+ /* The following illustrates the use of the routines to
+ run through a selection of communicators and datatypes.
+ Use subsets of these for tests that do not involve combinations
+ of communicators, datatypes, and counts of datatypes */
+ while (MTestGetIntracommGeneral( &comm, 1, 1 )) {
+ int count = 0;
+
+ if (comm == MPI_COMM_NULL) continue;
+ /* Determine the sender and receiver */
+ MPI_Comm_rank( comm, &rank );
+ MPI_Comm_size( comm, &size );
+
+ MPI_Win_create( buf, bufsize, sizeof(int), MPI_INFO_NULL, comm, &win );
+ /* To improve reporting of problems about operations, we
+ change the error handler to errors return */
+ MPI_Win_set_errhandler( win, MPI_ERRORS_RETURN );
+
+ /** TEST OPERATIONS USING ACTIVE TARGET (FENCE) SYNCHRONIZATION **/
+ MPI_Win_fence( 0, win );
+
+ TEST_FENCE_OP("Put",
+ MPI_Put( rmabuf, count, MPI_INT, TARGET, 0,
+ count, MPI_INT, win );
+ );
+
+ TEST_FENCE_OP("Get",
+ MPI_Get( rmabuf, count, MPI_INT, TARGET, 0,
+ count, MPI_INT, win );
+ );
+ TEST_FENCE_OP("Accumulate",
+ MPI_Accumulate( rmabuf, count, MPI_INT, TARGET,
+ 0, count, MPI_INT, MPI_SUM, win );
+ );
+ TEST_FENCE_OP("Get accumulate",
+ MPI_Get_accumulate( rmabuf, count, MPI_INT, result,
+ count, MPI_INT, TARGET, 0,
+ count, MPI_INT, MPI_SUM, win );
+ );
+ /* Note: It's not possible to generate a zero-byte FOP or CAS */
+
+ /** TEST OPERATIONS USING PASSIVE TARGET SYNCHRONIZATION **/
+
+ TEST_PT_OP("Put",
+ MPI_Put( rmabuf, count, MPI_INT, TARGET, 0, count,
+ MPI_INT, win );
+ );
+ TEST_PT_OP("Get",
+ MPI_Get( rmabuf, count, MPI_INT, TARGET, 0, count,
+ MPI_INT, win );
+ );
+ TEST_PT_OP("Accumulate",
+ MPI_Accumulate( rmabuf, count, MPI_INT, TARGET, 0,
+ count, MPI_INT, MPI_SUM, win );
+ );
+ TEST_PT_OP("Get accumulate",
+ MPI_Get_accumulate( rmabuf, count, MPI_INT, result, count,
+ MPI_INT, TARGET, 0, count,
+ MPI_INT, MPI_SUM, win );
+ );
+
+ /* Note: It's not possible to generate a zero-byte FOP or CAS */
+
+ /** TEST REQUEST-BASED OPERATIONS (PASSIVE TARGET ONLY) **/
+
+ TEST_REQ_OP("Rput", req,
+ MPI_Rput( rmabuf, count, MPI_INT, TARGET, 0, count,
+ MPI_INT, win, &req );
+ );
+ TEST_REQ_OP("Rget", req,
+ MPI_Rget( rmabuf, count, MPI_INT, TARGET, 0, count,
+ MPI_INT, win, &req );
+ );
+ TEST_REQ_OP("Raccumulate", req,
+ MPI_Raccumulate( rmabuf, count, MPI_INT, TARGET, 0,
+ count, MPI_INT, MPI_SUM, win, &req );
+ );
+ TEST_REQ_OP("Rget_accumulate", req,
+ MPI_Rget_accumulate( rmabuf, count, MPI_INT, result,
+ count, MPI_INT, TARGET, 0,
+ count, MPI_INT, MPI_SUM, win, &req );
+ );
+
+ MPI_Win_free( &win );
+ MTestFreeComm(&comm);
+ }
+
+ free( result );
+ free( buf );
+ free( rmabuf );
+ MTest_Finalize( errs );
+ MPI_Finalize();
+ return 0;
+}
diff --git a/test/mpi/rma/testlist b/test/mpi/rma/testlist
index 772be24..4a479b2 100644
--- a/test/mpi/rma/testlist
+++ b/test/mpi/rma/testlist
@@ -49,6 +49,7 @@ mixedsync 4
epochtest 4
locknull 2
rmanull 2
+rmazero 2
strided_acc_indexed 2
strided_acc_onelock 2
strided_acc_subarray 2
http://git.mpich.org/mpich.git/commitdiff/ab38c94853c55283bc6334a5c5bd6652f…
commit ab38c94853c55283bc6334a5c5bd6652f83a7e96
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Feb 28 16:00:35 2013 -0600
Fix handling of 0-byte xfers in req-gen ops
Added a check for 0-byte transfers in request-generating operations.
When a 0-byte transfer is encountered, the user is returned a completed
handle and no communication is performed.
Reviewer: goodell
diff --git a/src/mpid/ch3/src/ch3u_rma_reqops.c b/src/mpid/ch3/src/ch3u_rma_reqops.c
index b40f71e..09cf9d9 100644
--- a/src/mpid/ch3/src/ch3u_rma_reqops.c
+++ b/src/mpid/ch3/src/ch3u_rma_reqops.c
@@ -137,6 +137,10 @@ int MPIDI_Rput(const void *origin_addr, int origin_count,
MPID_Request **request)
{
int mpi_errno = MPI_SUCCESS;
+ int dt_contig ATTRIBUTE((unused));
+ MPID_Datatype *dtp;
+ MPI_Aint dt_true_lb ATTRIBUTE((unused));
+ MPIDI_msg_sz_t data_sz;
MPIDI_CH3I_Rma_req_state_t *req_state;
MPIU_CHKPMEM_DECL(1);
MPIDI_STATE_DECL(MPID_STATE_MPIDI_RPUT);
@@ -155,8 +159,11 @@ int MPIDI_Rput(const void *origin_addr, int origin_count,
req_state->win_ptr = win_ptr;
req_state->target_rank = target_rank;
+ MPIDI_Datatype_get_info(origin_count, origin_datatype,
+ dt_contig, data_sz, dtp, dt_true_lb);
+
/* Enqueue or perform the RMA operation */
- if (target_rank != MPI_PROC_NULL) {
+ if (target_rank != MPI_PROC_NULL && data_sz != 0) {
mpi_errno = win_ptr->RMAFns.Put(origin_addr, origin_count,
origin_datatype, target_rank,
target_disp, target_count,
@@ -169,7 +176,7 @@ int MPIDI_Rput(const void *origin_addr, int origin_count,
* Otherwise, generate a grequest. */
/* FIXME: We still may need to flush or sync for shared memory windows */
if (target_rank == MPI_PROC_NULL || target_rank == win_ptr->myrank ||
- win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED)
+ win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED || data_sz == 0)
{
mpi_errno = MPIR_Grequest_start_impl(MPIDI_CH3I_Rma_req_query,
MPIDI_CH3I_Rma_req_free,
@@ -211,6 +218,10 @@ int MPIDI_Rget(void *origin_addr, int origin_count,
MPID_Request **request)
{
int mpi_errno = MPI_SUCCESS;
+ int dt_contig ATTRIBUTE((unused));
+ MPID_Datatype *dtp;
+ MPI_Aint dt_true_lb ATTRIBUTE((unused));
+ MPIDI_msg_sz_t data_sz;
MPIDI_CH3I_Rma_req_state_t *req_state;
MPIU_CHKPMEM_DECL(1);
MPIDI_STATE_DECL(MPID_STATE_MPIDI_RGET);
@@ -229,8 +240,11 @@ int MPIDI_Rget(void *origin_addr, int origin_count,
req_state->win_ptr = win_ptr;
req_state->target_rank = target_rank;
+ MPIDI_Datatype_get_info(origin_count, origin_datatype,
+ dt_contig, data_sz, dtp, dt_true_lb);
+
/* Enqueue or perform the RMA operation */
- if (target_rank != MPI_PROC_NULL) {
+ if (target_rank != MPI_PROC_NULL && data_sz != 0) {
mpi_errno = win_ptr->RMAFns.Get(origin_addr, origin_count,
origin_datatype, target_rank,
target_disp, target_count,
@@ -243,7 +257,7 @@ int MPIDI_Rget(void *origin_addr, int origin_count,
* Otherwise, generate a grequest. */
/* FIXME: We still may need to flush or sync for shared memory windows */
if (target_rank == MPI_PROC_NULL || target_rank == win_ptr->myrank ||
- win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED)
+ win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED || data_sz == 0)
{
mpi_errno = MPIR_Grequest_start_impl(MPIDI_CH3I_Rma_req_query,
MPIDI_CH3I_Rma_req_free,
@@ -285,6 +299,10 @@ int MPIDI_Raccumulate(const void *origin_addr, int origin_count,
MPID_Request **request)
{
int mpi_errno = MPI_SUCCESS;
+ int dt_contig ATTRIBUTE((unused));
+ MPID_Datatype *dtp;
+ MPI_Aint dt_true_lb ATTRIBUTE((unused));
+ MPIDI_msg_sz_t data_sz;
MPIDI_CH3I_Rma_req_state_t *req_state;
MPIU_CHKPMEM_DECL(1);
MPIDI_STATE_DECL(MPID_STATE_MPIDI_RACCUMULATE);
@@ -303,8 +321,11 @@ int MPIDI_Raccumulate(const void *origin_addr, int origin_count,
req_state->win_ptr = win_ptr;
req_state->target_rank = target_rank;
+ MPIDI_Datatype_get_info(origin_count, origin_datatype,
+ dt_contig, data_sz, dtp, dt_true_lb);
+
/* Enqueue or perform the RMA operation */
- if (target_rank != MPI_PROC_NULL) {
+ if (target_rank != MPI_PROC_NULL && data_sz != 0) {
mpi_errno = win_ptr->RMAFns.Accumulate(origin_addr, origin_count,
origin_datatype, target_rank,
target_disp, target_count,
@@ -316,7 +337,7 @@ int MPIDI_Raccumulate(const void *origin_addr, int origin_count,
* Otherwise, generate a grequest. */
/* FIXME: We still may need to flush or sync for shared memory windows */
if (target_rank == MPI_PROC_NULL || target_rank == win_ptr->myrank ||
- win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED)
+ win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED || data_sz == 0)
{
mpi_errno = MPIR_Grequest_start_impl(MPIDI_CH3I_Rma_req_query,
MPIDI_CH3I_Rma_req_free,
@@ -359,6 +380,10 @@ int MPIDI_Rget_accumulate(const void *origin_addr, int origin_count,
MPID_Request **request)
{
int mpi_errno = MPI_SUCCESS;
+ int dt_contig ATTRIBUTE((unused));
+ MPID_Datatype *dtp;
+ MPI_Aint dt_true_lb ATTRIBUTE((unused));
+ MPIDI_msg_sz_t data_sz, trg_data_sz;
MPIDI_CH3I_Rma_req_state_t *req_state;
MPIU_CHKPMEM_DECL(1);
MPIDI_STATE_DECL(MPID_STATE_MPIDI_RGET_ACCUMULATE);
@@ -377,8 +402,14 @@ int MPIDI_Rget_accumulate(const void *origin_addr, int origin_count,
req_state->win_ptr = win_ptr;
req_state->target_rank = target_rank;
+ /* Note that GACC is only a no-op if no data goes in both directions */
+ MPIDI_Datatype_get_info(origin_count, origin_datatype,
+ dt_contig, data_sz, dtp, dt_true_lb);
+ MPIDI_Datatype_get_info(origin_count, origin_datatype,
+ dt_contig, trg_data_sz, dtp, dt_true_lb);
+
/* Enqueue or perform the RMA operation */
- if (target_rank != MPI_PROC_NULL) {
+ if (target_rank != MPI_PROC_NULL && (data_sz != 0 || trg_data_sz != 0)) {
mpi_errno = win_ptr->RMAFns.Get_accumulate(origin_addr, origin_count,
origin_datatype, result_addr,
result_count, result_datatype,
@@ -392,7 +423,8 @@ int MPIDI_Rget_accumulate(const void *origin_addr, int origin_count,
* Otherwise, generate a grequest. */
/* FIXME: We still may need to flush or sync for shared memory windows */
if (target_rank == MPI_PROC_NULL || target_rank == win_ptr->myrank ||
- win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED)
+ win_ptr->create_flavor == MPI_WIN_FLAVOR_SHARED ||
+ (data_sz == 0 && trg_data_sz == 0))
{
mpi_errno = MPIR_Grequest_start_impl(MPIDI_CH3I_Rma_req_query,
MPIDI_CH3I_Rma_req_free,
http://git.mpich.org/mpich.git/commitdiff/4611dedbefb197248718c4dd33669e77e…
commit 4611dedbefb197248718c4dd33669e77ec3cdceb
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Feb 28 11:28:29 2013 -0600
Added new operations to RMA PROC_NULL test
Extended the RMA PROC_NULL test to cover new operations and also to test
passive target synchronization.
Reviewer: goodell
diff --git a/test/mpi/rma/rmanull.c b/test/mpi/rma/rmanull.c
index ef8195a..cb228f3 100644
--- a/test/mpi/rma/rmanull.c
+++ b/test/mpi/rma/rmanull.c
@@ -9,6 +9,86 @@
#include <stdlib.h>
#include "mpitest.h"
+/* Test the given operation within a Fence epoch */
+#define TEST_FENCE_OP(op_name_, fcn_call_) \
+ do { \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "PROC_NULL to " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_fence( 0, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Fence after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
+
+/* Test the given operation within a passive target epoch */
+#define TEST_PT_OP(op_name_, fcn_call_) \
+ do { \
+ err = MPI_Win_lock(MPI_LOCK_EXCLUSIVE, MPI_PROC_NULL, 0, win); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Lock before" op_name_, err ); \
+ } \
+ } \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "PROC_NULL to " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_unlock( MPI_PROC_NULL, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Unlock after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
+
+/* Test the given request-based operation within a passive target epoch */
+#define TEST_REQ_OP(op_name_, req_, fcn_call_) \
+ do { \
+ err = MPI_Win_lock(MPI_LOCK_EXCLUSIVE, MPI_PROC_NULL, 0, win); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Lock before" op_name_, err ); \
+ } \
+ } \
+ err = fcn_call_ \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "PROC_NULL to " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Win_unlock( MPI_PROC_NULL, win ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Unlock after " op_name_, err ); \
+ } \
+ } \
+ err = MPI_Wait( &req_, MPI_STATUS_IGNORE ); \
+ if (err) { \
+ errs++; \
+ if (errs < 10) { \
+ MTestPrintErrorMsg( "Wait after " op_name_, err ); \
+ } \
+ } \
+ } while (0)
+
/*
static char MTEST_Descrip[] = "Test the MPI_PROC_NULL is a valid target";
*/
@@ -18,9 +98,11 @@ int main( int argc, char *argv[] )
int errs = 0, err;
int rank, size;
int *buf, bufsize;
+ int *result;
int *rmabuf, rsize, rcount;
MPI_Comm comm;
MPI_Win win;
+ MPI_Request req;
MTest_Init( &argc, &argv );
@@ -30,6 +112,11 @@ int main( int argc, char *argv[] )
fprintf( stderr, "Unable to allocated %d bytes\n", bufsize );
MPI_Abort( MPI_COMM_WORLD, 1 );
}
+ result = (int *)malloc( bufsize );
+ if (!result) {
+ fprintf( stderr, "Unable to allocated %d bytes\n", bufsize );
+ MPI_Abort( MPI_COMM_WORLD, 1 );
+ }
rcount = 16;
rsize = rcount * sizeof(int);
rmabuf = (int *)malloc( rsize );
@@ -49,63 +136,93 @@ int main( int argc, char *argv[] )
MPI_Comm_size( comm, &size );
MPI_Win_create( buf, bufsize, sizeof(int), MPI_INFO_NULL, comm, &win );
- MPI_Win_fence( 0, win );
/* To improve reporting of problems about operations, we
change the error handler to errors return */
MPI_Win_set_errhandler( win, MPI_ERRORS_RETURN );
- err = MPI_Put( rmabuf, rcount, MPI_INT,
- MPI_PROC_NULL, 0, rcount, MPI_INT, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "PROC_NULL to Put", err );
- }
- }
- err = MPI_Win_fence( 0, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "Fence after Put", err );
- }
- }
-
- err = MPI_Get( rmabuf, rcount, MPI_INT,
- MPI_PROC_NULL, 0, rcount, MPI_INT, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "PROC_NULL to Get", err );
- }
- }
- err = MPI_Win_fence( 0, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "Fence after Get", err );
- }
- }
-
- err = MPI_Accumulate( rmabuf, rcount, MPI_INT,
- MPI_PROC_NULL, 0, rcount, MPI_INT, MPI_SUM, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "PROC_NULL to Accumulate", err );
- }
- }
- err = MPI_Win_fence( 0, win );
- if (err) {
- errs++;
- if (errs < 10) {
- MTestPrintErrorMsg( "Fence after Accumulate", err );
- }
- }
+ /** TEST OPERATIONS USING ACTIVE TARGET (FENCE) SYNCHRONIZATION **/
+ MPI_Win_fence( 0, win );
+
+ TEST_FENCE_OP("Put",
+ MPI_Put( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, win );
+ );
+
+ TEST_FENCE_OP("Get",
+ MPI_Get( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, win );
+ );
+ TEST_FENCE_OP("Accumulate",
+ MPI_Accumulate( rmabuf, rcount, MPI_INT, MPI_PROC_NULL,
+ 0, rcount, MPI_INT, MPI_SUM, win );
+ );
+ TEST_FENCE_OP("Get accumulate",
+ MPI_Get_accumulate( rmabuf, rcount, MPI_INT, result,
+ rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, MPI_SUM, win );
+ );
+ TEST_FENCE_OP("Fetch and op",
+ MPI_Fetch_and_op( rmabuf, result, MPI_INT, MPI_PROC_NULL,
+ 0, MPI_SUM, win );
+ );
+ TEST_FENCE_OP("Compare and swap",
+ MPI_Compare_and_swap( rmabuf, &rank, result, MPI_INT,
+ MPI_PROC_NULL, 0, win );
+ );
+
+ /** TEST OPERATIONS USING PASSIVE TARGET SYNCHRONIZATION **/
+
+ TEST_PT_OP("Put",
+ MPI_Put( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0, rcount,
+ MPI_INT, win );
+ );
+ TEST_PT_OP("Get",
+ MPI_Get( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0, rcount,
+ MPI_INT, win );
+ );
+ TEST_PT_OP("Accumulate",
+ MPI_Accumulate( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, MPI_SUM, win );
+ );
+ TEST_PT_OP("Get accumulate",
+ MPI_Get_accumulate( rmabuf, rcount, MPI_INT, result, rcount,
+ MPI_INT, MPI_PROC_NULL, 0, rcount,
+ MPI_INT, MPI_SUM, win );
+ );
+ TEST_PT_OP("Fetch and op",
+ MPI_Fetch_and_op( rmabuf, result, MPI_INT, MPI_PROC_NULL, 0,
+ MPI_SUM, win );
+ );
+ TEST_PT_OP("Compare and swap",
+ MPI_Compare_and_swap( rmabuf, &rank, result, MPI_INT,
+ MPI_PROC_NULL, 0, win );
+ );
+
+ /** TEST REQUEST-BASED OPERATIONS (PASSIVE TARGET ONLY) **/
+
+ TEST_REQ_OP("Rput", req,
+ MPI_Rput( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0, rcount,
+ MPI_INT, win, &req );
+ );
+ TEST_REQ_OP("Rget", req,
+ MPI_Rget( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0, rcount,
+ MPI_INT, win, &req );
+ );
+ TEST_REQ_OP("Raccumulate", req,
+ MPI_Raccumulate( rmabuf, rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, MPI_SUM, win, &req );
+ );
+ TEST_REQ_OP("Rget_accumulate", req,
+ MPI_Rget_accumulate( rmabuf, rcount, MPI_INT, result,
+ rcount, MPI_INT, MPI_PROC_NULL, 0,
+ rcount, MPI_INT, MPI_SUM, win, &req );
+ );
MPI_Win_free( &win );
MTestFreeComm(&comm);
}
+ free( result );
free( buf );
free( rmabuf );
MTest_Finalize( errs );
http://git.mpich.org/mpich.git/commitdiff/9931e2a433f22ffb15b0fed721ae371f3…
commit 9931e2a433f22ffb15b0fed721ae371f39537f90
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Feb 28 13:10:58 2013 -0600
Cleaned up handling of PROC_NULL in RMA ops
Moved handling of MPI_PROC_NULL down to the device and cleaned up
handling of PROC_NULL in the CH3 device.
Reviewer: goodell
diff --git a/src/mpi/rma/accumulate.c b/src/mpi/rma/accumulate.c
index 573a751..8610e92 100644
--- a/src/mpi/rma/accumulate.c
+++ b/src/mpi/rma/accumulate.c
@@ -139,8 +139,6 @@ int MPI_Accumulate(const void *origin_addr, int origin_count, MPI_Datatype
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,Accumulate(origin_addr, origin_count,
origin_datatype,
target_rank, target_disp, target_count,
diff --git a/src/mpi/rma/compare_and_swap.c b/src/mpi/rma/compare_and_swap.c
index cf0ad51..04bf12e 100644
--- a/src/mpi/rma/compare_and_swap.c
+++ b/src/mpi/rma/compare_and_swap.c
@@ -128,8 +128,6 @@ int MPI_Compare_and_swap(const void *origin_addr, const void *compare_addr,
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,Compare_and_swap(origin_addr,
compare_addr, result_addr,
datatype, target_rank,
diff --git a/src/mpi/rma/fetch_and_op.c b/src/mpi/rma/fetch_and_op.c
index 9736133..634b327 100644
--- a/src/mpi/rma/fetch_and_op.c
+++ b/src/mpi/rma/fetch_and_op.c
@@ -142,8 +142,6 @@ int MPI_Fetch_and_op(const void *origin_addr, void *result_addr,
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,Fetch_and_op(origin_addr,
result_addr, datatype,
target_rank, target_disp,
diff --git a/src/mpi/rma/get.c b/src/mpi/rma/get.c
index afd49b5..0e0ca28 100644
--- a/src/mpi/rma/get.c
+++ b/src/mpi/rma/get.c
@@ -134,8 +134,6 @@ int MPI_Get(void *origin_addr, int origin_count, MPI_Datatype
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,
Get(origin_addr, origin_count, origin_datatype,
target_rank, target_disp, target_count,
diff --git a/src/mpi/rma/get_accumulate.c b/src/mpi/rma/get_accumulate.c
index 7df2377..db8fb3f 100644
--- a/src/mpi/rma/get_accumulate.c
+++ b/src/mpi/rma/get_accumulate.c
@@ -187,8 +187,6 @@ int MPI_Get_accumulate(const void *origin_addr, int origin_count,
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,Get_accumulate(origin_addr, origin_count,
origin_datatype,
result_addr, result_count,
diff --git a/src/mpi/rma/put.c b/src/mpi/rma/put.c
index 8199b04..8bb1bd9 100644
--- a/src/mpi/rma/put.c
+++ b/src/mpi/rma/put.c
@@ -134,8 +134,6 @@ int MPI_Put(const void *origin_addr, int origin_count, MPI_Datatype
/* ... body of routine ... */
- if (target_rank == MPI_PROC_NULL) goto fn_exit;
-
mpi_errno = MPIU_RMA_CALL(win_ptr,
Put(origin_addr, origin_count, origin_datatype,
target_rank, target_disp, target_count,
diff --git a/src/mpid/ch3/src/ch3u_rma_ops.c b/src/mpid/ch3/src/ch3u_rma_ops.c
index d940a50..f2fc7ca 100644
--- a/src/mpid/ch3/src/ch3u_rma_ops.c
+++ b/src/mpid/ch3/src/ch3u_rma_ops.c
@@ -189,6 +189,10 @@ int MPIDI_Put(const void *origin_addr, int origin_count, MPI_Datatype
MPIDI_RMA_FUNC_ENTER(MPID_STATE_MPIDI_PUT);
+ if (target_rank == MPI_PROC_NULL) {
+ goto fn_exit;
+ }
+
if (win_ptr->epoch_state == MPIDI_EPOCH_NONE && win_ptr->fence_issued) {
win_ptr->epoch_state = MPIDI_EPOCH_FENCE;
}
@@ -199,8 +203,7 @@ int MPIDI_Put(const void *origin_addr, int origin_count, MPI_Datatype
MPIDI_Datatype_get_info(origin_count, origin_datatype,
dt_contig, data_sz, dtp,dt_true_lb);
- if ((data_sz == 0) || (target_rank == MPI_PROC_NULL))
- {
+ if (data_sz == 0) {
goto fn_exit;
}
@@ -297,6 +300,10 @@ int MPIDI_Get(void *origin_addr, int origin_count, MPI_Datatype
MPIDI_RMA_FUNC_ENTER(MPID_STATE_MPIDI_GET);
+ if (target_rank == MPI_PROC_NULL) {
+ goto fn_exit;
+ }
+
if (win_ptr->epoch_state == MPIDI_EPOCH_NONE && win_ptr->fence_issued) {
win_ptr->epoch_state = MPIDI_EPOCH_FENCE;
}
@@ -307,8 +314,7 @@ int MPIDI_Get(void *origin_addr, int origin_count, MPI_Datatype
MPIDI_Datatype_get_info(origin_count, origin_datatype,
dt_contig, data_sz, dtp, dt_true_lb);
- if ((data_sz == 0) || (target_rank == MPI_PROC_NULL))
- {
+ if (data_sz == 0) {
goto fn_exit;
}
@@ -404,6 +410,10 @@ int MPIDI_Accumulate(const void *origin_addr, int origin_count, MPI_Datatype
MPIDI_RMA_FUNC_ENTER(MPID_STATE_MPIDI_ACCUMULATE);
+ if (target_rank == MPI_PROC_NULL) {
+ goto fn_exit;
+ }
+
if (win_ptr->epoch_state == MPIDI_EPOCH_NONE && win_ptr->fence_issued) {
win_ptr->epoch_state = MPIDI_EPOCH_FENCE;
}
@@ -414,8 +424,7 @@ int MPIDI_Accumulate(const void *origin_addr, int origin_count, MPI_Datatype
MPIDI_Datatype_get_info(origin_count, origin_datatype,
dt_contig, data_sz, dtp, dt_true_lb);
- if ((data_sz == 0) || (target_rank == MPI_PROC_NULL))
- {
+ if (data_sz == 0) {
goto fn_exit;
}
http://git.mpich.org/mpich.git/commitdiff/a77f0eac2460e292b1417c087b86c1620…
commit a77f0eac2460e292b1417c087b86c1620a73c4bb
Author: James Dinan <dinan(a)mcs.anl.gov>
Date: Thu Feb 28 12:54:38 2013 -0600
Updated req-based ops to handle PROC_NULL
Updated request-generating RMA operations to correctly handle
communication with MPI_PROC_NULL.
Reviewer: goodell
diff --git a/src/mpid/ch3/src/ch3u_rma_reqops.c b/src/mpid/ch3/src/ch3u_rma_reqops.c
index 822da94..b40f71e 100644
--- a/src/mpid/ch3/src/ch3u_rma_reqops.c
+++ b/src/mpid/ch3/src/ch3u_rma_reqops.c
@@ -144,7 +144,8 @@ int MPIDI_Rput(const void *origin_addr, int origin_count,
MPIDI_FUNC_ENTER(MPID_STATE_MPIDI_RPUT);
MPIU_ERR_CHKANDJUMP(win_ptr->epoch_state != MPIDI_EPOCH_LOCK &&
- win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL,
+ win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL &&
+ target_rank != MPI_PROC_NULL,
mpi_errno, MPI_ERR_RMA_SYNC, "**rmasync");
MPIU_CHKPMEM_MALLOC(req_state, MPIDI_CH3I_Rma_req_state_t*,
@@ -217,7 +218,8 @@ int MPIDI_Rget(void *origin_addr, int origin_count,
MPIDI_FUNC_ENTER(MPID_STATE_MPIDI_RGET);
MPIU_ERR_CHKANDJUMP(win_ptr->epoch_state != MPIDI_EPOCH_LOCK &&
- win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL,
+ win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL &&
+ target_rank != MPI_PROC_NULL,
mpi_errno, MPI_ERR_RMA_SYNC, "**rmasync");
MPIU_CHKPMEM_MALLOC(req_state, MPIDI_CH3I_Rma_req_state_t*,
@@ -290,7 +292,8 @@ int MPIDI_Raccumulate(const void *origin_addr, int origin_count,
MPIDI_FUNC_ENTER(MPID_STATE_MPIDI_RACCUMULATE);
MPIU_ERR_CHKANDJUMP(win_ptr->epoch_state != MPIDI_EPOCH_LOCK &&
- win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL,
+ win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL &&
+ target_rank != MPI_PROC_NULL,
mpi_errno, MPI_ERR_RMA_SYNC, "**rmasync");
MPIU_CHKPMEM_MALLOC(req_state, MPIDI_CH3I_Rma_req_state_t*,
@@ -363,7 +366,8 @@ int MPIDI_Rget_accumulate(const void *origin_addr, int origin_count,
MPIDI_FUNC_ENTER(MPID_STATE_MPIDI_RGET_ACCUMULATE);
MPIU_ERR_CHKANDJUMP(win_ptr->epoch_state != MPIDI_EPOCH_LOCK &&
- win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL,
+ win_ptr->epoch_state != MPIDI_EPOCH_LOCK_ALL &&
+ target_rank != MPI_PROC_NULL,
mpi_errno, MPI_ERR_RMA_SYNC, "**rmasync");
MPIU_CHKPMEM_MALLOC(req_state, MPIDI_CH3I_Rma_req_state_t*,
-----------------------------------------------------------------------
Summary of changes:
src/mpi/rma/accumulate.c | 2 -
src/mpi/rma/compare_and_swap.c | 2 -
src/mpi/rma/fetch_and_op.c | 2 -
src/mpi/rma/get.c | 2 -
src/mpi/rma/get_accumulate.c | 2 -
src/mpi/rma/put.c | 2 -
src/mpid/ch3/src/ch3u_rma_ops.c | 21 +++-
src/mpid/ch3/src/ch3u_rma_reqops.c | 60 ++++++++--
test/mpi/rma/Makefile.am | 1 +
test/mpi/rma/rmanull.c | 213 ++++++++++++++++++++++++++--------
test/mpi/rma/rmazero.c | 222 ++++++++++++++++++++++++++++++++++++
test/mpi/rma/testlist | 1 +
12 files changed, 452 insertions(+), 78 deletions(-)
create mode 100644 test/mpi/rma/rmazero.c
hooks/post-receive
--
MPICH primary repository
1
0