Unprecise routine name in error messages and modified a few comments.

git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@10663 c92efa57-630b-4861-b058-cf58834340f0
This commit is contained in:
dalcorso 2014-01-07 13:54:17 +00:00
parent d4881fde32
commit ee4ad00be9
4 changed files with 28 additions and 20 deletions

View File

@ -41,7 +41,7 @@ CONTAINS
SUBROUTINE mp_start_bands( nband_, ntg_, parent_comm )
!---------------------------------------------------------------------------
!
! ... Divide processors (of the "parent_comm" group) into bands pools
! ... Divide processors (of the "parent_comm" group) into nband_ pools
! ... Requires: nband_, read from command line
! ... parent_comm, typically processors of a k-point pool
! ... (intra_pool_comm)
@ -63,9 +63,9 @@ CONTAINS
!
nbgrp = nband_
!
IF ( nbgrp < 1 .OR. nbgrp > parent_nproc ) CALL errore( 'init_bands', &
IF ( nbgrp < 1 .OR. nbgrp > parent_nproc ) CALL errore( 'mp_start_bands',&
'invalid number of band groups, out of range', 1 )
IF ( MOD( parent_nproc, nbgrp ) /= 0 ) CALL errore( 'init_bands', &
IF ( MOD( parent_nproc, nbgrp ) /= 0 ) CALL errore( 'mp_start_bands', &
'n. of band groups must be divisor of parent_nproc', 1 )
!
! ... Set number of processors per band group
@ -86,7 +86,7 @@ CONTAINS
!
CALL MPI_COMM_SPLIT( parent_comm, my_bgrp_id, parent_mype, intra_bgrp_comm, ierr )
!
IF ( ierr /= 0 ) CALL errore( 'init_bands', &
IF ( ierr /= 0 ) CALL errore( 'mp_start_bands', &
'intra band group communicator initialization', ABS(ierr) )
!
CALL mp_barrier( parent_comm )
@ -95,7 +95,7 @@ CONTAINS
!
CALL MPI_COMM_SPLIT( parent_comm, me_bgrp, parent_mype, inter_bgrp_comm, ierr )
!
IF ( ierr /= 0 ) CALL errore( 'init_bands', &
IF ( ierr /= 0 ) CALL errore( 'mp_start_bands', &
'inter band group communicator initialization', ABS(ierr) )
!
IF ( PRESENT(ntg_) ) THEN

View File

@ -55,9 +55,9 @@ CONTAINS
nimage = nimage_
!
IF ( nimage < 1 .OR. nimage > parent_nproc ) &
CALL errore( 'init_images', 'invalid number of images, out of range', 1 )
CALL errore( 'mp_start_images', 'invalid number of images, out of range', 1 )
IF ( MOD( parent_nproc, nimage ) /= 0 ) &
CALL errore( 'init_images', 'n. of images must be divisor of nproc', 1 )
CALL errore( 'mp_start_images', 'n. of images must be divisor of nproc', 1 )
!
! ... set number of cpus per image
!
@ -78,7 +78,7 @@ CONTAINS
CALL MPI_COMM_SPLIT ( parent_comm, my_image_id, parent_mype, &
intra_image_comm, ierr )
IF ( ierr /= 0 ) CALL errore &
( 'init_images', 'intra image communicator initialization', ABS(ierr) )
( 'mp_start_images', 'intra image communicator initialization', ABS(ierr) )
!
CALL mp_barrier( parent_comm )
!
@ -87,7 +87,7 @@ CONTAINS
CALL MPI_COMM_SPLIT( parent_comm, me_image, parent_mype, &
inter_image_comm, ierr )
IF ( ierr /= 0 ) CALL errore &
( 'init_images', 'inter image communicator initialization', ABS(ierr) )
( 'mp_start_images', 'inter image communicator initialization', ABS(ierr) )
!
! ... set processor that performs I/O
!

View File

@ -26,8 +26,9 @@ MODULE mp_pools
INTEGER :: inter_pool_comm = 0 ! inter pool communicator
INTEGER :: intra_pool_comm = 0 ! intra pool communicator
!
! ... Obscure parallelization info, maybe obsolete
INTEGER :: kunit = 1 ! granularity of k-point distribution
INTEGER :: kunit = 1 ! granularity of k-point distribution
! kunit=1 standard case. In phonon k and k+q must
! be on the same pool, so kunit=2.
!
CONTAINS
!
@ -35,7 +36,7 @@ CONTAINS
SUBROUTINE mp_start_pools( npool_, parent_comm )
!---------------------------------------------------------------------------
!
! ... Divide processors (of the "parent_comm" group) into "pots"
! ... Divide processors (of the "parent_comm" group) into "pools"
! ... Requires: npool_, read from command line
! ... parent_comm, typically world_comm = group of all processors
!
@ -54,13 +55,16 @@ CONTAINS
! ... by a call to routine get_command_line
!
npool = npool_
IF ( npool < 1 .OR. npool > parent_nproc ) CALL errore( 'mp_start_pools',&
'invalid number of pools, out of range', 1 )
IF ( MOD( parent_nproc, npool ) /= 0 ) CALL errore( 'mp_start_pools', &
'invalid number of pools, parent_nproc /= nproc_pool * npool', 1 )
!
! ... number of cpus per pool of k-points (created inside each parent group)
!
nproc_pool = parent_nproc / npool
!
IF ( MOD( parent_nproc, npool ) /= 0 ) CALL errore( 'init_pools', &
'invalid number of pools, parent_nproc /= nproc_pool * npool', 1 )
!
! ... my_pool_id = pool index for this processor ( 0 : npool - 1 )
! ... me_pool = processor index within the pool ( 0 : nproc_pool - 1 )
@ -74,7 +78,7 @@ CONTAINS
!
CALL MPI_COMM_SPLIT( parent_comm, my_pool_id, parent_mype, intra_pool_comm, ierr )
!
IF ( ierr /= 0 ) CALL errore( 'init_pools', &
IF ( ierr /= 0 ) CALL errore( 'mp_start_pools', &
'intra pool communicator initialization', ABS(ierr) )
!
CALL mp_barrier( parent_comm )
@ -83,7 +87,7 @@ CONTAINS
!
CALL MPI_COMM_SPLIT( parent_comm, me_pool, parent_mype, inter_pool_comm, ierr )
!
IF ( ierr /= 0 ) CALL errore( 'init_pools', &
IF ( ierr /= 0 ) CALL errore( 'mp_start_pools', &
'inter pool communicator initialization', ABS(ierr) )
!
#endif

View File

@ -53,12 +53,16 @@ CONTAINS
!
npot = npot_
!
IF ( npot < 1 .OR. npot > parent_nproc ) CALL errore( 'mp_start_pots',&
'invalid number of pot groups, out of range', 1 )
IF ( MOD( parent_nproc, npot ) /= 0 ) CALL errore( 'mp_start_pots', &
'invalid number of pots, parent_nproc /= nproc_pot * npot', 1 )
!
! ... number of cpus per pot (they are created inside each parent group)
!
nproc_pot = parent_nproc / npot
!
IF ( MOD( parent_nproc, npot ) /= 0 ) CALL errore( 'init_pots', &
'invalid number of pots, parent_nproc /= nproc_pot * npot', 1 )
!
! ... my_pot_id = pot index for this processor ( 0 : npot - 1 )
! ... me_pot = processor index within the pot ( 0 : nproc_pot - 1 )
@ -72,7 +76,7 @@ CONTAINS
!
CALL MPI_COMM_SPLIT( parent_comm, my_pot_id, parent_mype, intra_pot_comm, ierr )
!
IF ( ierr /= 0 ) CALL errore( 'init_pots', &
IF ( ierr /= 0 ) CALL errore( 'mp_start_pots', &
'intra pot communicator initialization', ABS(ierr) )
!
CALL mp_barrier( parent_comm )
@ -82,7 +86,7 @@ CONTAINS
CALL MPI_COMM_SPLIT( parent_comm, me_pot, parent_mype, inter_pot_comm, ierr )
!
IF ( ierr /= 0 ) &
CALL errore( 'init_pots', 'inter pot communicator initialization', ABS(ierr) )
CALL errore( 'mp_start_pots', 'inter pot communicator initialization', ABS(ierr) )
!
#endif
!