58 TYPE(t_region
) :: region
60 INTEGER,
INTENT(IN) :: ireg
63 INTEGER :: icont, ilev
66 CHARACTER(CHRLEN) :: rcsidentstring
70 TYPE(t_level
),
POINTER :: plevel
71 TYPE(t_plag),
POINTER :: pplag
76 rcsidentstring =
'$RCSfile: PLAG_DeallocateMemoryPost.F90,v $ $Revision: 1.3 $'
78 global => region%global
81 'PLAG_DeallocateMemoryPost.F90' )
83 IF ( ireg == 1 .AND. global%myProcid == masterproc .AND. &
84 global%verbLevel > verbose_none )
THEN
85 WRITE(stdout,
'(A,3X,A)') solver_name,
'Deallocating memory for PLAG...'
90 DO ilev=1,region%nGridLevels
92 plevel => region%levels(ilev)
93 pplag => region%levels(ilev)%plag
97 DEALLOCATE( pplag%aiv,stat=errorflag )
98 global%error = errorflag
99 IF (global%error /= err_none)
THEN
100 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%aiv' )
103 DEALLOCATE( pplag%arv,stat=errorflag )
104 global%error = errorflag
105 IF (global%error /= err_none)
THEN
106 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%arv' )
109 DEALLOCATE( pplag%cv,stat=errorflag )
110 global%error = errorflag
111 IF (global%error /= err_none)
THEN
112 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%cv' )
115 DEALLOCATE( pplag%dv,stat=errorflag )
116 global%error = errorflag
117 IF (global%error /= err_none)
THEN
118 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%dv' )
121 DEALLOCATE( pplag%tv,stat=errorflag )
122 global%error = errorflag
123 IF (global%error /= err_none)
THEN
124 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%tv' )
129 DEALLOCATE( pplag%cvPlagMass,stat=errorflag )
130 global%error = errorflag
131 IF (global%error /= err_none)
THEN
132 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%cvPlagMass' )
135 DEALLOCATE( pplag%dvPlagVolu,stat=errorflag )
136 global%error = errorflag
137 IF (global%error /= err_none)
THEN
138 CALL
errorstop( global, err_deallocate,__line__ ,
'pPlag%dvPlagVolu' )
145 IF ( ireg == global%nRegions .AND. global%myProcid == masterproc .AND. &
146 global%verbLevel > verbose_none )
THEN
147 WRITE(stdout,
'(A,3X,A)') solver_name,
'Deallocating memory for PLAG done...'
subroutine plag_deallocatememorypost(region, iReg)
subroutine registerfunction(global, funName, fileName)
subroutine errorstop(global, errorCode, errorLine, addMessage)
subroutine deregisterfunction(global)