Commit 0b1fffd2 authored by giannozz's avatar giannozz

EXX with k-point parallelization: removal of a useless variable

--- This line, and those below, will be ignored--

M    PHonon/PH/phq_init.f90
M    PHonon/PH/elphon.f90
M    PW/src/xk_wk_collect.f90
M    PW/src/exx.f90


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/[email protected] c92efa57-630b-4861-b058-cf58834340f0
parent 1d62aebd
......@@ -530,7 +530,7 @@ SUBROUTINE elphsum ( )
COMPLEX(DP) :: el_ph_sum (3*nat,3*nat)
COMPLEX(DP), POINTER :: el_ph_mat_collect(:,:,:,:)
REAL(DP), ALLOCATABLE :: xk_collect(:,:), wk_collect(:)
REAL(DP), ALLOCATABLE :: xk_collect(:,:)
REAL(DP), POINTER :: wkfit_dist(:), etfit_dist(:,:)
INTEGER :: nksfit_dist, rest, kunit_save
INTEGER :: nks_real, ispin, nksqtot, irr
......@@ -554,7 +554,6 @@ SUBROUTINE elphsum ( )
nsig =el_ph_nsigma
ALLOCATE(xk_collect(3,nkstot))
ALLOCATE(wk_collect(nkstot))
ALLOCATE(deg(nsig))
ALLOCATE(effit(nsig))
......@@ -566,7 +565,6 @@ SUBROUTINE elphsum ( )
!
nksqtot=nksq
xk_collect(:,1:nks) = xk(:,1:nks)
wk_collect(1:nks) = wk(1:nks)
el_ph_mat_collect => el_ph_mat
ELSE
!
......@@ -579,7 +577,7 @@ SUBROUTINE elphsum ( )
nksqtot=nkstot/2
ENDIF
ALLOCATE(el_ph_mat_collect(nbnd,nbnd,nksqtot,3*nat))
CALL xk_wk_collect(xk_collect,wk_collect,xk,wk,nkstot,nks)
CALL xk_wk_collect(xk_collect,xk,nkstot,nks)
CALL el_ph_collect(3*nat,el_ph_mat,el_ph_mat_collect,nksqtot,nksq)
ENDIF
!
......@@ -905,7 +903,6 @@ SUBROUTINE elphsum ( )
DEALLOCATE( effit )
DEALLOCATE( dosfit )
DEALLOCATE(xk_collect)
DEALLOCATE(wk_collect)
IF (npool /= 1) DEALLOCATE(el_ph_mat_collect)
!
......
......@@ -126,8 +126,6 @@ SUBROUTINE phq_init()
END DO
!
IF ( nksq > 1 ) REWIND( iunigk )
!
!
! only for electron-phonon coupling with wannier functions
!
......@@ -231,7 +229,6 @@ SUBROUTINE phq_init()
CALL calbec (npw, vkb, aux1, alphap(ipol,ik) )
END DO
!
!
!!!!!!!!!!!!!!!!!!!!!!!! ACFDT TEST !!!!!!!!!!!!!!!!
IF (acfdt_is_active) THEN
! ACFDT -test always read calculated wcf from non_scf calculation
......@@ -284,7 +281,6 @@ SUBROUTINE phq_init()
CALL mp_sum ( eprec, intra_bgrp_comm )
!
DEALLOCATE( aux1 )
!
CALL dvanqq()
CALL drho()
......
......@@ -221,7 +221,7 @@ MODULE exx
INTEGER :: iq1, iq2, iq3, isym, ik, ikq, iq, max_nk, temp_nkqs
INTEGER, allocatable :: temp_index_xk(:), temp_index_sym(:)
INTEGER, allocatable :: temp_index_ikq(:), new_ikq(:)
REAL(DP),allocatable :: temp_xkq(:,:), wk_collect(:)
REAL(DP),allocatable :: temp_xkq(:,:)
LOGICAL :: xk_not_found
REAL(DP) :: sxk(3), dxk(3), xk_cryst(3)
REAL(DP) :: dq1, dq2, dq3
......@@ -255,9 +255,7 @@ MODULE exx
! the next if/then if probably not necessary, as xk_wk collect can
! deal with npool==1, leaving it for clarity.
IF ( npool > 1 ) THEN
ALLOCATE(wk_collect(nkstot))
CALL xk_wk_collect(xk_collect, wk_collect, xk, wk, nkstot, nks)
DEALLOCATE(wk_collect)
CALL xk_wk_collect(xk_collect, xk, nkstot, nks)
ELSE
xk_collect(:,1:nks) = xk(:,1:nks)
ENDIF
......
......@@ -7,12 +7,11 @@
!
!
!----------------------------------------------------------------------------
SUBROUTINE xk_wk_collect( xk_collect, wk_collect, xk, wk, nkstot, nks )
SUBROUTINE xk_wk_collect( xk_collect, xk, nkstot, nks )
!----------------------------------------------------------------------------
!
! ... This routine collects the k points (with granularity kunit) among
! ... nodes and sets the variable xk_collect and wk_collect with the total
! ... number of k-points
! ... This routine collects the k points (with granularity kunit) among nodes
! ... and sets the variable xk_collect with the total number of k-points
!
USE io_global, only : stdout
USE kinds, ONLY : DP
......@@ -25,8 +24,8 @@ SUBROUTINE xk_wk_collect( xk_collect, wk_collect, xk, wk, nkstot, nks )
INTEGER :: nkstot, nks
! total number of k-points
! number of k-points per pool
REAL (DP) :: xk(3,nks), wk(nks)
REAL (DP) :: xk_collect(3,nkstot), wk_collect(nkstot)
REAL (DP) :: xk(3,nks)
REAL (DP) :: xk_collect(3,nkstot)
! k-points
! k-point weights
!
......@@ -36,8 +35,6 @@ SUBROUTINE xk_wk_collect( xk_collect, wk_collect, xk, wk, nkstot, nks )
!
xk_collect=0.d0
!
wk_collect=0.d0
!
nks1 = kunit * ( nkstot / kunit / npool )
!
rest = ( nkstot - nks1 * npool ) / kunit
......@@ -45,7 +42,7 @@ SUBROUTINE xk_wk_collect( xk_collect, wk_collect, xk, wk, nkstot, nks )
IF ( ( my_pool_id + 1 ) <= rest ) nks1 = nks1 + kunit
!
IF (nks1.ne.nks) &
call errore('xk_wk_collect','problems with nks1',1)
call errore('xk_collect','problems with nks1',1)
!
! ... calculates nbase = the position in the list of the first point that
! ... belong to this npool - 1
......@@ -58,12 +55,8 @@ SUBROUTINE xk_wk_collect( xk_collect, wk_collect, xk, wk, nkstot, nks )
!
xk_collect(:,nbase+1:nbase+nks) = xk(:,1:nks)
!
wk_collect(nbase+1:nbase+nks)=wk(1:nks)
!
CALL mp_sum( xk_collect, inter_pool_comm )
!
CALL mp_sum( wk_collect, inter_pool_comm )
!
#endif
!
RETURN
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment