Last change
on this file since 1892 was
1852,
checked in by Ehouarn Millour, 11 years ago
|
Implémentation des sorties XIOS dans LMDZ. Activation via -cpp CPP_XIOS.
ATTENTION: un problème de raccord subsiste en mode MPI !
UG
................................
Adding XIOS output to LMDZ. Activated by the CPP_XIOS key.
WARNING: buggy for now in MPI mode.
UG
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
File size:
1.3 KB
|
Line | |
---|
1 | ! |
---|
2 | ! $Id: abort_gcm.F 1852 2013-08-30 08:47:10Z fairhead $ |
---|
3 | ! |
---|
4 | c |
---|
5 | c |
---|
6 | SUBROUTINE abort_gcm(modname, message, ierr) |
---|
7 | |
---|
8 | #ifdef CPP_IOIPSL |
---|
9 | USE IOIPSL |
---|
10 | #else |
---|
11 | ! if not using IOIPSL, we still need to use (a local version of) getin_dump |
---|
12 | USE ioipsl_getincom |
---|
13 | #endif |
---|
14 | USE parallel_lmdz |
---|
15 | |
---|
16 | |
---|
17 | |
---|
18 | |
---|
19 | #include "iniprint.h" |
---|
20 | |
---|
21 | C |
---|
22 | C Stops the simulation cleanly, closing files and printing various |
---|
23 | C comments |
---|
24 | C |
---|
25 | C Input: modname = name of calling program |
---|
26 | C message = stuff to print |
---|
27 | C ierr = severity of situation ( = 0 normal ) |
---|
28 | |
---|
29 | character(len=*) modname |
---|
30 | integer ierr, ierror_mpi |
---|
31 | character(len=*) message |
---|
32 | |
---|
33 | write(lunout,*) 'in abort_gcm' |
---|
34 | #ifdef CPP_IOIPSL |
---|
35 | c$OMP MASTER |
---|
36 | call histclo |
---|
37 | call restclo |
---|
38 | if (MPI_rank .eq. 0) then |
---|
39 | call getin_dump |
---|
40 | endif |
---|
41 | c$OMP END MASTER |
---|
42 | #endif |
---|
43 | |
---|
44 | |
---|
45 | |
---|
46 | c call histclo(2) |
---|
47 | c call histclo(3) |
---|
48 | c call histclo(4) |
---|
49 | c call histclo(5) |
---|
50 | write(lunout,*) 'Stopping in ', modname |
---|
51 | write(lunout,*) 'Reason = ',message |
---|
52 | if (ierr .eq. 0) then |
---|
53 | write(lunout,*) 'Everything is cool' |
---|
54 | else |
---|
55 | write(lunout,*) 'Houston, we have a problem ', ierr |
---|
56 | #ifdef CPP_MPI |
---|
57 | C$OMP CRITICAL (MPI_ABORT_GCM) |
---|
58 | call MPI_ABORT(COMM_LMDZ, 1, ierror_mpi) |
---|
59 | C$OMP END CRITICAL (MPI_ABORT_GCM) |
---|
60 | #else |
---|
61 | stop 1 |
---|
62 | #endif |
---|
63 | endif |
---|
64 | END |
---|
Note: See
TracBrowser
for help on using the repository browser.