2006-04-03 18:33:22 +08:00
|
|
|
!
|
|
|
|
! Copyright (C) 2001 PWSCF group
|
|
|
|
! This file is distributed under the terms of the
|
|
|
|
! GNU General Public License. See the file `License'
|
|
|
|
! in the root directory of the present distribution,
|
|
|
|
! or http://www.gnu.org/copyleft/gpl.txt .
|
|
|
|
!
|
|
|
|
!--------------------------------------------------------------------
|
2010-06-19 00:54:19 +08:00
|
|
|
SUBROUTINE stop_vdw
|
2006-04-03 18:33:22 +08:00
|
|
|
!--------------------------------------------------------------------
|
|
|
|
!
|
|
|
|
! Synchronize processes before stopping.
|
|
|
|
!
|
2010-06-19 00:54:19 +08:00
|
|
|
USE control_flags, ONLY: twfcollect
|
|
|
|
USE io_files, ONLY: iunwfc
|
|
|
|
USE mp_global, ONLY: mp_global_end
|
2006-04-03 18:33:22 +08:00
|
|
|
USE parallel_include
|
|
|
|
#ifdef __PARA
|
|
|
|
|
2010-06-19 00:54:19 +08:00
|
|
|
INTEGER :: info
|
|
|
|
LOGICAL :: op
|
2006-04-03 18:33:22 +08:00
|
|
|
|
2010-06-19 00:54:19 +08:00
|
|
|
CALL print_clock_vdw ()
|
2006-04-03 18:33:22 +08:00
|
|
|
|
2010-06-19 00:54:19 +08:00
|
|
|
INQUIRE ( iunwfc, opened = op )
|
2006-04-03 18:33:22 +08:00
|
|
|
|
2010-06-19 00:54:19 +08:00
|
|
|
IF ( op ) THEN
|
|
|
|
IF (twfcollect) THEN
|
|
|
|
CLOSE (unit = iunwfc, status = 'delete')
|
|
|
|
ELSE
|
|
|
|
CLOSE (unit = iunwfc, status = 'keep')
|
|
|
|
ENDIF
|
|
|
|
ENDIF
|
2006-04-03 18:33:22 +08:00
|
|
|
|
|
|
|
#endif
|
|
|
|
|
2010-06-19 00:54:19 +08:00
|
|
|
CALL mp_global_end ()
|
|
|
|
|
|
|
|
STOP
|
|
|
|
END SUBROUTINE stop_vdw
|