source: proiecte/hpl/openmpi_compiled/share/man/man3/MPI_Init.3 @ 97

Last change on this file since 97 was 97, checked in by (none), 14 years ago

Adding compiled files

File size: 2.6 KB
Line 
1.\"Copyright 2006-2008 Sun Microsystems, Inc.
2.\" Copyright (c) 1996 Thinking Machines Corporation
3.TH MPI_Init 3 "Dec 08, 2009" "1.4" "Open MPI"
4
5.SH NAME
6\fBMPI_Init\fP \- Initializes the MPI execution environment
7
8.SH SYNTAX
9.ft R
10
11.SH C Syntax
12.nf
13#include <mpi.h>
14int MPI_Init(int *\fIargc\fP, char ***\fIargv\fP)
15
16.SH Fortran Syntax
17.nf
18INCLUDE 'mpif.h'
19MPI_INIT(\fIIERROR\fP)
20        INTEGER \fIIERROR\fP
21
22.SH C++ Syntax
23.nf
24#include <mpi.h>
25void MPI::Init(int& \fIargc\fP, char**& \fIargv\fP)
26void MPI::Init()
27
28.SH INPUT PARAMETERS
29.ft R
30.TP 1i
31argc
32C/C++ only: Pointer to the number of arguments.
33.TP 1i
34argv
35C/C++ only: Argument vector.
36
37.SH OUTPUT PARAMETER
38.ft R
39.TP 1i
40IERROR
41Fortran only: Error status (integer).
42
43.SH DESCRIPTION
44.ft R
45This routine, or MPI_Init_thread, must be called before any other MPI
46routine (apart from MPI_Initialized) is called. MPI can be initialized
47at most once; subsequent calls to MPI_Init or MPI_Init_thread are
48erroneous.
49.sp
50All MPI programs must contain a call to MPI_Init or
51MPI_Init_thread. Open MPI accepts the C/C++ \fIargc\fP and \fIargv\fP
52arguments to main, but neither modifies, interprets, nor distributes
53them:
54.sp
55.nf
56        {
57                /* declare variables */
58                MPI_Init(&argc, &argv);
59                /* parse arguments */
60                /* main program */
61                MPI_Finalize();
62        }
63.fi
64
65.SH NOTES
66.ft R
67The Fortran version does not have provisions for \fIargc\fP and
68\fIargv\fP and takes only IERROR.
69.sp
70The MPI Standard does not say what a program can do before an MPI_Init
71or after an MPI_Finalize. In the Open MPI implementation, it should do
72as little as possible. In particular, avoid anything that changes the
73external state of the program, such as opening files, reading standard
74input, or writing to standard output.
75
76.SH ERRORS
77.ft R
78Almost all MPI routines return an error value; C routines as
79the value of the function and Fortran routines in the last argument. C++
80functions do not return errors. If the default error handler is set to
81MPI::ERRORS_THROW_EXCEPTIONS, then on error the C++ exception mechanism
82will be used to throw an MPI:Exception object.
83.sp
84Before the error value is returned, the current MPI error handler is
85called. By default, this error handler aborts the MPI job, except for
86I/O function errors. The error handler may be changed with
87MPI_Comm_set_errhandler; the predefined error handler MPI_ERRORS_RETURN
88may be used to cause error values to be returned. Note that MPI does not
89guarantee that an MPI program can continue past an error.
90.sp
91See the MPI man page for a full list of MPI error codes.
92
93.SH SEE ALSO
94.ft R
95.nf
96MPI_Init_thread
97MPI_Initialized
98MPI_Finalize
99
Note: See TracBrowser for help on using the repository browser.