source: LMDZ6/branches/LMDZ_ECRad/libf/dyn3d/abort_gcm.F @ 5444

Last change on this file since 5444 was 4727, checked in by idelkadi, 15 months ago

Merged trunk changes -r4488:4726 LMDZ_ECRad branch

  • Property copyright set to
    Name of program: LMDZ
    Creation date: 1984
    Version: LMDZ5
    License: CeCILL version 2
    Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539
    See the license file in the root directory
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.2 KB
Line 
1!
2! $Id: abort_gcm.F 4727 2023-10-19 14:02:57Z fhourdin $
3!
4c
5c
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 ! ug Pour les sorties XIOS
15      USE wxios
16
17#include "iniprint.h"
18 
19C
20C Stops the simulation cleanly, closing files and printing various
21C comments
22C
23C  Input: modname = name of calling program
24C         message = stuff to print
25C         ierr    = severity of situation ( = 0 normal )
26
27      character(len=*), intent(in):: modname
28      integer, intent(in):: ierr
29      character(len=*), intent(in):: message
30
31      write(lunout,*) 'in abort_gcm'
32
33      IF (using_xios) THEN
34!Fermeture propre de XIOS
35        CALL wxios_close()
36      ENDIF
37
38#ifdef CPP_IOIPSL
39      call histclo
40      call restclo
41#endif
42      call getin_dump
43c     call histclo(2)
44c     call histclo(3)
45c     call histclo(4)
46c     call histclo(5)
47      write(lunout,*) 'Stopping in ', modname
48      write(lunout,*) 'Reason = ',message
49      if (ierr .eq. 0) then
50        write(lunout,*) 'Everything is cool'
51        stop
52      else
53        write(lunout,*) 'Houston, we have a problem, ierr = ', ierr
54        stop 1
55      endif
56      END
Note: See TracBrowser for help on using the repository browser.