aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschnetter <schnetter@2e825fa2-fb71-486d-8b7f-a5ff3f0f6cb8>2005-08-26 14:49:16 +0000
committerschnetter <schnetter@2e825fa2-fb71-486d-8b7f-a5ff3f0f6cb8>2005-08-26 14:49:16 +0000
commitc25bd93ed153311f74bf7ee792eadbed4b830b01 (patch)
tree2408fcb8ec8b717549824a85fce09cd68e2bb218
parent88fedc2ff9f70e05fa3757000051b8e48ef0f4d1 (diff)
GetMPICommWorld now returns a pointer to the communicator, instead of
the communicator itself cast to an int git-svn-id: http://svn.cactuscode.org/arrangements/CactusNumerical/Slab/trunk@44 2e825fa2-fb71-486d-8b7f-a5ff3f0f6cb8
-rw-r--r--interface.ccl3
-rw-r--r--src/slab.c8
2 files changed, 6 insertions, 5 deletions
diff --git a/interface.ccl b/interface.ccl
index 100ed3a..7110914 100644
--- a/interface.ccl
+++ b/interface.ccl
@@ -6,5 +6,6 @@ IMPLEMENTS: Slab
INCLUDES HEADER: slab.h IN Slab.h
INCLUDES HEADER: slab.inc IN Slab.inc
-CCTK_INT FUNCTION GetMPICommWorld (CCTK_POINTER_TO_CONST IN cctkGH)
+CCTK_POINTER_TO_CONST \
+FUNCTION GetMPICommWorld (CCTK_POINTER_TO_CONST IN cctkGH)
USES FUNCTION GetMPICommWorld
diff --git a/src/slab.c b/src/slab.c
index 3fec618..47c2339 100644
--- a/src/slab.c
+++ b/src/slab.c
@@ -302,7 +302,7 @@ get_mpi_comm (const cGH * restrict const cctkGH)
{
#ifdef CCTK_MPI
if (CCTK_IsFunctionAliased ("GetMPICommWorld")) {
- return GetMPICommWorld (cctkGH);
+ return * (MPI_Comm const *) GetMPICommWorld (cctkGH);
}
# if defined CARPET_CARPET
{
@@ -800,11 +800,11 @@ int Slab_MultiTransfer (cGH const * const cctkGH,
{
- CCTK_INT tmp;
- int const iret = Util_TableGetInt (options, &tmp, "comm");
+ CCTK_POINTER tmp;
+ int const iret = Util_TableGetPointer (options, &tmp, "comm");
if (iret == 1) {
/* There was an entry, use it */
- comm = tmp;
+ comm = * (MPI_Comm const *) tmp;
} else if (iret == UTIL_ERROR_BAD_HANDLE
|| iret == UTIL_ERROR_TABLE_NO_SUCH_KEY) {
/* There was no entry, use a default */