1 |
C $Header$ |
C $Header$ |
2 |
|
C $Name$ |
3 |
|
|
4 |
#include "CPP_EEOPTIONS.h" |
#include "CPP_EEOPTIONS.h" |
5 |
|
|
6 |
CStartOfInterface |
CBOP |
7 |
|
C !ROUTINE: EEBOOT |
8 |
|
|
9 |
|
C !INTERFACE: |
10 |
SUBROUTINE EEBOOT |
SUBROUTINE EEBOOT |
|
C /==========================================================\ |
|
|
C | SUBROUTINE EEBOOT | |
|
|
C | o Set up execution "environment", particularly perform | |
|
|
C | steps to initialise parallel processing. | |
|
|
C |==========================================================| |
|
|
C | Note: This routine can also be compiled with CPP | |
|
|
C | directives set so that no multi-processing is initialised| |
|
|
C | This is OK and should work fine. | |
|
|
C \==========================================================/ |
|
11 |
IMPLICIT NONE |
IMPLICIT NONE |
12 |
|
|
13 |
|
C !DESCRIPTION: |
14 |
|
C *==========================================================* |
15 |
|
C | SUBROUTINE EEBOOT |
16 |
|
C | o Set up execution "environment", particularly perform |
17 |
|
C | steps to initialise parallel processing. |
18 |
|
C *==========================================================* |
19 |
|
C | Note: This routine can also be compiled with CPP |
20 |
|
C | directives set so that no multi-processing is initialised |
21 |
|
C | This is OK and works fine. |
22 |
|
C *==========================================================* |
23 |
|
|
24 |
|
C !CALLING SEQUENCE: |
25 |
|
C eeboot() |
26 |
|
C | |
27 |
|
C |-- eeboot_minimal() :: Minimal startup. Just enough to |
28 |
|
C | allow basic I/O. |
29 |
|
C | |
30 |
|
C |-- eeintro_msg() :: Write startup greeting. |
31 |
|
C | |
32 |
|
C |-- eeset_parms() :: Set WRAPPER parameters |
33 |
|
C | |
34 |
|
C |-- eewrite_eeenv() :: Print WRAPPER parameter settings |
35 |
|
C | |
36 |
|
C |-- ini_procs() :: Associate processes with grid regions. |
37 |
|
C | |
38 |
|
C |-- ini_threading_environment() :: Associate threads with grid regions. |
39 |
|
C | |
40 |
|
C |-- dfile_init() :: Initialise simple multi-process I/O pacakge. |
41 |
|
|
42 |
|
C !USES: |
43 |
C == Global variables == |
C == Global variables == |
44 |
#include "SIZE.h" |
#include "SIZE.h" |
45 |
#include "EEPARAMS.h" |
#include "EEPARAMS.h" |
46 |
#include "EESUPPORT.h" |
#include "EESUPPORT.h" |
|
CEndOfInterface |
|
47 |
|
|
48 |
|
C !LOCAL VARIABLES: |
49 |
C == Local variables == |
C == Local variables == |
50 |
C I - Loop counter |
C I :: Loop counter |
51 |
INTEGER I |
INTEGER I |
52 |
|
CEOP |
53 |
|
|
54 |
C-- Set error reporting flags and I/O streams |
C-- Set error reporting flags and I/O streams |
55 |
C fatalError is a flag used to indicate that the program |
C fatalError is a flag used to indicate that the program |
72 |
C threadIsRunning used during startup to enable check that all |
C threadIsRunning used during startup to enable check that all |
73 |
C the threads are running. |
C the threads are running. |
74 |
fatalError = .FALSE. |
fatalError = .FALSE. |
|
errorMessageUnit = 0 |
|
|
standardMessageUnit = 6 |
|
75 |
eeBootError = .FALSE. |
eeBootError = .FALSE. |
76 |
eeEndError = .FALSE. |
eeEndError = .FALSE. |
77 |
DO I=1, MAX_NO_THREADS |
DO I=1, MAX_NO_THREADS |
81 |
threadIsComplete(I) = .FALSE. |
threadIsComplete(I) = .FALSE. |
82 |
ioErrorCount(I) = 0 |
ioErrorCount(I) = 0 |
83 |
ENDDO |
ENDDO |
84 |
scrUnit1 = 11 |
standardMessageUnit = 6 |
85 |
scrUnit2 = 12 |
scrUnit1 = 11 |
86 |
eeDataUnit = 13 |
scrUnit2 = 12 |
87 |
modelDataUnit = 14 |
eeDataUnit = 13 |
88 |
|
modelDataUnit = 14 |
89 |
|
errorMessageUnit = 15 |
90 |
|
cph errorMessageUnit = 0 is not allowed on some platforms, e.g. SP3 |
91 |
|
C |
92 |
C Annoyingly there is no universal way to have the usingMPI |
C Annoyingly there is no universal way to have the usingMPI |
93 |
C parameter work as one might expect. This is because, on some |
C parameter work as one might expect. This is because, on some |
94 |
C systems I/O does not work until MPI_Init has been called. The |
C systems I/O does not work until MPI_Init has been called. The |