This source file includes following definitions.
- MPIR_MPIOInit
1
2
3
4
5
6 #include "mpioimpl.h"
7 #include <string.h>
8
9 #ifdef HAVE_WEAK_SYMBOLS
10
11 #define MPIO_BUILD_PROFILING
12 #include "mpioprof.h"
13 #endif
14
15 extern int ADIO_Init_keyval;
16
17
18
19
20 void MPIR_MPIOInit(int * error_code) {
21
22 int flag;
23 char myname[] = "MPIR_MPIOInit";
24
25
26 if (ADIO_Init_keyval == MPI_KEYVAL_INVALID) {
27 MPI_Initialized(&flag);
28
29
30 if (!flag) {
31 *error_code = MPIO_Err_create_code(MPI_SUCCESS,
32 MPIR_ERR_RECOVERABLE, myname, __LINE__,
33 MPI_ERR_OTHER, "**initialized", 0);
34 *error_code = MPIO_Err_return_file(MPI_FILE_NULL, *error_code);
35 return;
36 }
37
38
39 MPI_Comm_create_keyval (MPI_COMM_NULL_COPY_FN, ADIOI_End_call, &ADIO_Init_keyval,
40 (void *) 0);
41
42
43
44
45
46
47 MPI_Comm_set_attr (MPI_COMM_SELF, ADIO_Init_keyval, (void *) 0);
48
49
50 ADIO_Init( (int *)0, (char ***)0, error_code);
51 }
52 *error_code = MPI_SUCCESS;
53 }
54
55
56