source: LMDZ5/trunk/libf/dyn3d/abort_gcm.F @ 1897

Last change on this file since 1897 was 1825, checked in by Ehouarn Millour, 11 years ago

Première étape de l'implémentation de XIOS. Modifications isolées dans des flags CPP_XIOS. Sorties opérationnelles (sauf stations et régionalisation) en modes séquentiel et omp, pas mpi.
UG
...........................................
First step of the XIOS implementation. Modifications are confined into CPP_XIOS flags. Output is operationnal (except for stations and regionalization) in sequential and omp modes (not mpi).
UG

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 1.2 KB
RevLine 
[524]1!
[1279]2! $Id: abort_gcm.F 1825 2013-08-02 14:36:53Z emillour $
[524]3!
4c
5c
6      SUBROUTINE abort_gcm(modname, message, ierr)
7     
8#ifdef CPP_IOIPSL
9      USE IOIPSL
[1279]10#else
11! if not using IOIPSL, we still need to use (a local version of) getin_dump
12      USE ioipsl_getincom
[524]13#endif
[1825]14
15#ifdef CPP_XIOS
16    ! ug Pour les sorties XIOS
17      USE wxios
18#endif
19
[524]20#include "iniprint.h"
21 
22C
23C Stops the simulation cleanly, closing files and printing various
24C comments
25C
26C  Input: modname = name of calling program
27C         message = stuff to print
28C         ierr    = severity of situation ( = 0 normal )
29
[1107]30      character(len=*) modname
[524]31      integer ierr
[1107]32      character(len=*) message
[524]33
[1425]34      write(lunout,*) 'in abort_gcm'
[1825]35
36#ifdef CPP_XIOS
37    !Fermeture propre de XIOS
38      CALL wxios_close()
39#endif
40
[524]41#ifdef CPP_IOIPSL
42      call histclo
43      call restclo
44#endif
[1147]45      call getin_dump
[524]46c     call histclo(2)
47c     call histclo(3)
48c     call histclo(4)
49c     call histclo(5)
[1425]50      write(lunout,*) 'Stopping in ', modname
51      write(lunout,*) 'Reason = ',message
[524]52      if (ierr .eq. 0) then
[1425]53        write(lunout,*) 'Everything is cool'
54        stop
[524]55      else
[1425]56        write(lunout,*) 'Houston, we have a problem ', ierr
57        stop 1
[524]58      endif
59      END
Note: See TracBrowser for help on using the repository browser.