Purpose
Queries the current STDOUT mode setting.
Library
libmpi.a
C synopsis
#include <pm_util.h> int mpc_stdoutmode_query(int *mode);
FORTRAN synopsis
MP_STDOUTMODE_QUERY(INTEGER MODE)
Parameters
Description
This parallel utility subroutine returns the mode to which STDOUT is currently set.
Notes
Return values
In C and C++ calls, the following applies:
Examples
C Example
The following program uses poe with one task:
#include <pm_util.h>
main()
{
int mode;
mpc_stdoutmode_query(&mode);
printf("Initial (default) STDOUT mode is %d\n", mode);
mpc_stdout_mode(STDIO_ORDERED);
mpc_stdoutmode_query(&mode);
printf("New STDOUT mode is %d\n", mode);
}
Running the above program produces the following output:
Initial (default) STDOUT mode is -3
New STDOUT mode is -2
FORTRAN Example
The following program uses poe with one task:
INTEGER MODE CALL MP_STDOUTMODE_QUERY(mode) WRITE(6, *) 'Initial (default) STDOUT mode is', mode CALL MP_STDOUT_MODE(-2) CALL MP_STDOUTMODE_QUERY(mode) WRITE(6, *) 'New STDOUT mode is', mode END
Running the above program produces the following output:
Initial (default) STDOUT mode is -3
New STDOUT mode is -2
Related information
Commands:
Subroutines: