1
1

- Get rid of unused variables / set but never used warnings.

This commit was SVN r14762.
Этот коммит содержится в:
Rainer Keller 2007-05-24 18:57:51 +00:00
родитель 0e2a335297
Коммит c8668ef83f
3 изменённых файлов: 29 добавлений и 35 удалений

Просмотреть файл

@ -43,7 +43,6 @@ int MPI_Intercomm_merge(MPI_Comm intercomm, int high,
ompi_communicator_t *newcomp=MPI_COMM_NULL;
ompi_proc_t **procs=NULL;
int local_size, remote_size;
int local_rank;
int first;
int total_size;
int rc=MPI_SUCCESS;
@ -65,7 +64,6 @@ int MPI_Intercomm_merge(MPI_Comm intercomm, int high,
}
local_size = ompi_comm_size ( intercomm );
local_rank = ompi_comm_rank ( intercomm );
remote_size = ompi_comm_remote_size ( intercomm );
total_size = local_size + remote_size;
procs = (ompi_proc_t **) malloc ( total_size * sizeof(ompi_proc_t *));

Просмотреть файл

@ -36,8 +36,6 @@ static const char FUNC_NAME[] = "MPI_Type_dup";
int MPI_Type_dup (MPI_Datatype type,
MPI_Datatype *newtype)
{
int rc;
OPAL_CR_TEST_CHECKPOINT_READY();
if( MPI_PARAM_CHECK ) {
@ -58,30 +56,30 @@ int MPI_Type_dup (MPI_Datatype type,
return OMPI_SUCCESS;
}
if( (rc = ompi_ddt_duplicate( type, newtype )) != MPI_SUCCESS ) {
ompi_ddt_destroy( newtype );
OMPI_ERRHANDLER_RETURN( MPI_ERR_INTERN, MPI_COMM_WORLD,
MPI_ERR_INTERN, FUNC_NAME );
if (OMPI_SUCCESS != ompi_ddt_duplicate( type, newtype)) {
ompi_ddt_destroy( newtype );
OMPI_ERRHANDLER_RETURN (MPI_ERR_INTERN, MPI_COMM_WORLD,
MPI_ERR_INTERN, FUNC_NAME );
}
ompi_ddt_set_args( *newtype, 0, NULL, 0, NULL, 1, &type, MPI_COMBINER_DUP );
/* Copy all the old attributes, if there were any. This is done
here (vs. ompi_ddt_duplicate()) because MPI_TYPE_DUP is the
only MPI function that copies attributes. All other MPI
functions that take an old type and generate a newtype do not
copy attributes. Really. */
if (NULL != type->d_keyhash) {
ompi_attr_hash_init(&(*newtype)->d_keyhash);
if (OMPI_SUCCESS != (rc = ompi_attr_copy_all(TYPE_ATTR,
type, *newtype,
type->d_keyhash,
(*newtype)->d_keyhash))) {
ompi_ddt_destroy(newtype);
OMPI_ERRHANDLER_RETURN( MPI_ERR_INTERN, MPI_COMM_WORLD,
MPI_ERR_INTERN, FUNC_NAME );
}
}
/* Copy all the old attributes, if there were any. This is done
here (vs. ompi_ddt_duplicate()) because MPI_TYPE_DUP is the
only MPI function that copies attributes. All other MPI
functions that take an old type and generate a newtype do not
copy attributes. Really. */
if (NULL != type->d_keyhash) {
ompi_attr_hash_init(&(*newtype)->d_keyhash);
if (OMPI_SUCCESS != ompi_attr_copy_all(TYPE_ATTR,
type, *newtype,
type->d_keyhash,
(*newtype)->d_keyhash)) {
ompi_ddt_destroy(newtype);
OMPI_ERRHANDLER_RETURN( MPI_ERR_INTERN, MPI_COMM_WORLD,
MPI_ERR_INTERN, FUNC_NAME );
}
}
return MPI_SUCCESS;
}

Просмотреть файл

@ -58,21 +58,19 @@ OMPI_GENERATE_F77_BINDINGS (MPI_CART_COORDS,
#endif
void mpi_cart_coords_f(MPI_Fint *comm, MPI_Fint *rank, MPI_Fint *maxdims,
MPI_Fint *coords, MPI_Fint *ierr)
MPI_Fint *coords, MPI_Fint *ierr)
{
MPI_Comm c_comm;
int size;
OMPI_ARRAY_NAME_DECL(coords);
c_comm = MPI_Comm_f2c(*comm);
size = OMPI_FINT_2_INT(*maxdims);
OMPI_ARRAY_FINT_2_INT_ALLOC(coords, size);
*ierr = OMPI_INT_2_FINT(MPI_Cart_coords(c_comm,
OMPI_FINT_2_INT(*rank),
OMPI_FINT_2_INT(*maxdims),
OMPI_ARRAY_NAME_CONVERT(coords)));
c_comm = MPI_Comm_f2c(*comm);
OMPI_ARRAY_FINT_2_INT_ALLOC(coords, OMPI_FINT_2_INT(*maxdims));
*ierr = OMPI_INT_2_FINT(MPI_Cart_coords(c_comm,
OMPI_FINT_2_INT(*rank),
OMPI_FINT_2_INT(*maxdims),
OMPI_ARRAY_NAME_CONVERT(coords)));
if (MPI_SUCCESS == OMPI_FINT_2_INT(*ierr)) {
OMPI_ARRAY_INT_2_FINT(coords, size);
OMPI_ARRAY_INT_2_FINT(coords, OMPI_FINT_2_INT(*maxdims));
}
}