1
1

Partially implemented and commented out binding for now

This commit was SVN r2505.
Этот коммит содержится в:
Vishal Sahay 2004-09-04 00:28:30 +00:00
родитель 6e4558343c
Коммит 2adafa8f53
2 изменённых файлов: 68 добавлений и 4 удалений

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

@ -46,7 +46,32 @@ OMPI_GENERATE_F77_BINDINGS (MPI_COMM_SPAWN,
#include "mpi/f77/profile/defines.h"
#endif
void mpi_comm_spawn_f(char *command, char *argv, MPI_Fint *maxprocs, MPI_Fint *info, MPI_Fint *root, MPI_Fint *comm, MPI_Fint *intercomm, MPI_Fint *array_of_errcodes, MPI_Fint *ierr)
void mpi_comm_spawn_f(char *command, char *argv, MPI_Fint *maxprocs,
MPI_Fint *info, MPI_Fint *root, MPI_Fint *comm,
MPI_Fint *intercomm, MPI_Fint *array_of_errcodes,
MPI_Fint *ierr)
{
/* This function not yet implemented */
#if 0
MPI_Comm c_comm, c_new_comm;
MPI_Info c_info;
int size;
OMPI_ARRAY_NAME_DECL(array_of_errcodes);
c_comm = MPI_Comm_f2c(*comm);
c_info = MPI_Info_f2c(*info);
MPI_Comm_size(c_comm, &size);
OMPI_ARRAY_FINT_2_INT_ALLOC(array_of_errcodes, size);
*ierr = OMPI_INT_2_FINT(MPI_Comm_spawn(command, argv,
OMPI_FINT_2_INT(*maxprocs),
c_info,
OMPI_FINT_2_INT(*root),
c_comm, &c_new_comm,
OMPI_ARRAY_NAME_CONVERT(array_of_errcodes)));
*intercomm = MPI_Comm_c2f(c_new_comm);
OMPI_ARRAY_INT_2_FINT(array_of_errcodes, size);
#endif
}

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

@ -46,7 +46,46 @@ OMPI_GENERATE_F77_BINDINGS (MPI_COMM_SPAWN_MULTIPLE,
#include "mpi/f77/profile/defines.h"
#endif
void mpi_comm_spawn_multiple_f(MPI_Fint *count, char *array_of_commands, char *array_of_argv, MPI_Fint *array_of_maxprocs, MPI_Fint *array_of_info, MPI_Fint *root, MPI_Fint *comm, MPI_Fint *intercomm, MPI_Fint *array_of_errcodes, MPI_Fint *ierr)
void mpi_comm_spawn_multiple_f(MPI_Fint *count, char *array_commands,
char *array_argv,
MPI_Fint *array_maxprocs,
MPI_Fint *array_info, MPI_Fint *root,
MPI_Fint *comm, MPI_Fint *intercomm,
MPI_Fint *array_errcds, MPI_Fint *ierr)
{
/* This function not yet implemented */
#if 0
MPI_Comm c_comm, c_new_comm;
MPI_Info *c_info;
int size, array_size, i;
OMPI_ARRAY_NAME_DECL(array_maxprocs);
OMPI_ARRAY_NAME_DECL(array_errcds);
c_comm = MPI_Comm_f2c(*comm);
MPI_Comm_size(c_comm, &size);
array_size = OMPI_FINT_2_INT(*count);
OMPI_ARRAY_FINT_2_INT(array_maxprocs, array_size);
OMPI_ARRAY_FINT_2_INT_ALLOC(array_errcds, size);
c_info = malloc (array_size * sizeof(MPI_Info));
for (i = 0; i < array_size; ++i) {
c_info[i] = MPI_Info_f2c(array_info[i]);
}
*ierr =
OMPI_INT_2_FINT(MPI_Comm_spawn_multiple(OMPI_FINT_2_INT(*count),
array_commands,
array_argv,
OMPI_ARRAY_NAME_CONVERT(array_maxprocs),
c_info,
OMPI_FINT_2_INT(*root),
c_comm, &c_new_comm,
OMPI_ARRAY_NAME_CONVERT(array_errcds)));
*intercomm = MPI_Comm_c2f(c_new_comm);
OMPI_ARRAY_INT_2_FINT(array_errcds, size);
OMPI_ARRAY_FINT_2_INT_CLEANUP(array_maxprocs);
#endif
}