Open MPI logo

MPI_Get_processor_name(3) man page (version 5.0.0rc2)

  |   Home   |   Support   |   FAQ   |  

« Return to documentation listing

Table of Contents

Name

C]MPI_Get_processor_nameR] - Gets the name of the processor.

Syntax

C Syntax



C]#include <mpi.h>int MPI_Get_processor_name(char *name, int *resultlen)R]Fortran Syntax



C]USE MPI! or the older form: INCLUDE [aq]mpif.h[aq]MPI_GET_PROCESSOR_NAME(NAME, RESULTLEN, IERROR) CHARACTER*(*) NAME INTEGER RESULTLEN, IERRORR]Fortran 2008 Syntax



C]USE mpi_f08MPI_Get_processor_name(name, resultlen, ierror) CHARACTER(LEN=MPI_MAX_PROCESSOR_NAME), INTENT(OUT) :: name INTEGER, INTENT(OUT) :: resultlen INTEGER, OPTIONAL, INTENT(OUT) :: ierrorR]Output Parameters

[bu]
C]nameR] : A unique specifier for the actual (as opposed to virtual) node.
[bu]
C]resultlenR] : Length (in characters) of result returned in name.
[bu]
C]IERRORR] : Fortran only: Error status (integer).

Description

This routine returns the C]nameR] of the processor on which it was called at the moment of the call. The C]nameR] is a character string for maximum flexibility. From this value it must be possible to identify a specific piece of hardware. The argument C]nameR] must represent storage that is at least C]MPI_MAX_PROCESSOR_NAMER] characters long.

The number of characters actually written is returned in the output argument, C]resultlenR].

Notes

The user must provide at least C]MPI_MAX_PROCESSOR_NAMER] space to write the processor C]nameR]; processor C]nameR]s can be this long. The user should examine the output argument, C]resultlenR], to determine the actual length of the C]nameR].

Errors

Almost all MPI routines return an error value; C routines as the value of the function and Fortran routines in the last argument.

Before the error value is returned, the current MPI error handler is called. By default, this error handler aborts the MPI job, except for I/O function errors. The error handler may be changed with C]MPI_Comm_set_errhandlerR]; the predefined error handler C]MPI_ERRORS_RETURNR] may be used to cause error values to be returned. Note that MPI does not guarantee that an MPI program can continue past an error.


Table of Contents

« Return to documentation listing