Accept an array of request set to NULL if the count is set to ZERO.
This commit was SVN r9504.
Этот коммит содержится в:
родитель
4b1b99d7c9
Коммит
ae47cbfe02
@ -2,7 +2,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -40,7 +40,7 @@ int MPI_Testall(int count, MPI_Request requests[], int *flag,
|
||||
if ( MPI_PARAM_CHECK ) {
|
||||
rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (requests == NULL) {
|
||||
if( (NULL == requests) && (0 != count) ) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
}
|
||||
OMPI_ERRHANDLER_CHECK(rc, MPI_COMM_WORLD, rc, FUNC_NAME);
|
||||
|
@ -2,7 +2,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -39,10 +39,12 @@ int MPI_Testany(int count, MPI_Request requests[], int *index, int *completed, M
|
||||
if ( MPI_PARAM_CHECK ) {
|
||||
int rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (NULL == requests) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
} else if (NULL == index) {
|
||||
rc = MPI_ERR_ARG;
|
||||
if( 0 != count ) {
|
||||
if (NULL == requests) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
} else if (NULL == index) {
|
||||
rc = MPI_ERR_ARG;
|
||||
}
|
||||
}
|
||||
OMPI_ERRHANDLER_CHECK(rc, MPI_COMM_WORLD, rc, FUNC_NAME);
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -43,10 +43,12 @@ int MPI_Testsome(int incount, MPI_Request requests[],
|
||||
if ( MPI_PARAM_CHECK ) {
|
||||
int rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (NULL == requests) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
} else if (NULL == indices) {
|
||||
rc = MPI_ERR_ARG;
|
||||
if( 0 != incount ) {
|
||||
if( NULL == requests) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
} else if (NULL == indices) {
|
||||
rc = MPI_ERR_ARG;
|
||||
}
|
||||
}
|
||||
OMPI_ERRHANDLER_CHECK(rc, MPI_COMM_WORLD, rc, FUNC_NAME);
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -40,7 +40,7 @@ int MPI_Waitall(int count, MPI_Request *requests, MPI_Status *statuses)
|
||||
int i;
|
||||
rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (requests == NULL) {
|
||||
if( (NULL == requests) && (0 != count) ) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
}
|
||||
for (i = 0; i < count; i++) {
|
||||
|
@ -4,7 +4,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -42,7 +42,7 @@ int MPI_Waitany(int count, MPI_Request *requests, int *index, MPI_Status *status
|
||||
int i;
|
||||
rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (requests == NULL) {
|
||||
if( (NULL == requests) && (0 != count) ) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
}
|
||||
for (i = 0; i < count; i++) {
|
||||
|
@ -4,7 +4,7 @@
|
||||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
||||
* University Research and Technology
|
||||
* Corporation. All rights reserved.
|
||||
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
||||
* Copyright (c) 2004-2006 The University of Tennessee and The University
|
||||
* of Tennessee Research Foundation. All rights
|
||||
* reserved.
|
||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
||||
@ -45,7 +45,7 @@ int MPI_Waitsome(int incount, MPI_Request *requests,
|
||||
if ( MPI_PARAM_CHECK ) {
|
||||
int rc = MPI_SUCCESS;
|
||||
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
|
||||
if (requests == NULL) {
|
||||
if( (requests == NULL) && (0 != incount) ) {
|
||||
rc = MPI_ERR_REQUEST;
|
||||
}
|
||||
OMPI_ERRHANDLER_CHECK(rc, MPI_COMM_WORLD, rc, FUNC_NAME);
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user