1 |
|
|
MODULE ABORT_TRANS_MOD |
2 |
|
|
CONTAINS |
3 |
|
|
SUBROUTINE ABORT_TRANS(CDTEXT) |
4 |
|
|
|
5 |
|
|
USE TPM_GEN , ONLY : NOUT,NERR |
6 |
|
|
USE TPM_DISTR, ONLY : NPROC,MYPROC |
7 |
|
|
!USE MPL_MODULE, ONLY : MPL_ABORT ! MPL 1.12.08 |
8 |
|
|
USE SDL_MODULE, ONLY : SDL_TRACEBACK, SDL_SRLABORT |
9 |
|
|
|
10 |
|
|
IMPLICIT NONE |
11 |
|
|
|
12 |
|
|
|
13 |
|
|
CHARACTER(LEN=*),INTENT(IN) :: CDTEXT |
14 |
|
|
|
15 |
|
|
WRITE(NOUT,'(1X,A)') 'ABORT_TRANS CALLED' |
16 |
|
|
|
17 |
|
|
WRITE(NOUT,'(1X,A)') CDTEXT |
18 |
|
|
WRITE(NERR,'(1X,A,1X,I3,1X,A)') 'ABORT! ',MYPROC,CDTEXT |
19 |
|
|
CLOSE(NOUT) |
20 |
|
|
IF (NPROC > 1) THEN |
21 |
|
|
! CALL MPL_ABORT(CDTEXT) ! MPL 1.12.08 |
22 |
|
|
CALL ABOR1('DANS ABORT_TRANS_MOD') |
23 |
|
|
ELSE |
24 |
|
|
CALL SDL_TRACEBACK |
25 |
|
|
CALL FLUSH(0) |
26 |
|
|
CALL SDL_SRLABORT |
27 |
|
|
ENDIF |
28 |
|
|
|
29 |
|
|
END SUBROUTINE ABORT_TRANS |
30 |
|
|
END MODULE ABORT_TRANS_MOD |