2 /* Creator: Jeffrey Vetter (vetter3@llnl.gov) Thu Feb 24 2000 */
4 /* type-commit-twice.c -- do a type commit twice w/ the same type */
8 "$Header: /usr/gapps/asde/cvs-vault/umpire/tests/type-commit-twice.c,v 1.4 2002/07/30 21:34:43 bronis Exp $";
18 main (int argc, char **argv)
22 MPI_Comm comm = MPI_COMM_WORLD;
23 char processor_name[128];
28 MPI_Init (&argc, &argv);
29 MPI_Comm_size (comm, &nprocs);
30 MPI_Comm_rank (comm, &rank);
31 MPI_Get_processor_name (processor_name, &namelen);
32 printf ("(%d) is alive on %s\n", rank, processor_name);
37 MPI_Type_contiguous (128, MPI_INT, &newtype);
38 MPI_Type_commit (&newtype);
40 /* COMMITTING TWICE IS NOT AN ERROR - SEE:
41 http://www.mpi-forum.org/docs/mpi-20-html/node50.htm#Node50
42 AT MOST, UMPIRE SHOULD PROVIDE A CLEAR WARNING ABOUT MINOR
43 PERFORMANCE CONSEQUENCE (JUST A WASTED FUNCTION CALL)... */
44 MPI_Type_commit (&newtype);
48 MPI_Type_free (&newtype);
50 printf ("(%d) Finished normally\n", rank);