Oops ... forgot this file as well

This commit is contained in:
Paolo Giannozzi 2024-01-04 12:45:43 +01:00
parent 1def560952
commit 6e06b898ac
1 changed files with 11 additions and 15 deletions

View File

@ -278,6 +278,7 @@ SUBROUTINE upf_bcast(upf, ionode, ionode_id, comm)
!! ID of the processor that broadcasts
INTEGER, INTENT(in) :: comm
!! MPI communicator
INTEGER :: nbeta
!
CALL mp_bcast (upf%nv, ionode_id, comm )
CALL mp_bcast (upf%generated, ionode_id, comm )
@ -330,26 +331,21 @@ SUBROUTINE upf_bcast(upf, ionode, ionode_id, comm)
ENDIF
!
IF ( .not. ionode) THEN
! next instructions prevents trouble in following broadcasts
nbeta = MAX (1, upf%nbeta)
ALLOCATE( upf%kbeta(nbeta), &
upf%lll(nbeta), &
upf%beta(upf%mesh, nbeta), &
upf%dion(nbeta, nbeta), &
upf%rcut(nbeta), &
upf%rcutus(nbeta), &
upf%els_beta(nbeta) )
! not sure next instructions are needed
IF ( upf%nbeta == 0) THEN
upf%nqf = 0
upf%nqlc= 0
upf%qqq_eps= -1._dp
upf%kkbeta = 0
ALLOCATE( upf%kbeta(1), &
upf%lll(1), &
upf%beta(upf%mesh,1), &
upf%dion(1,1), &
upf%rcut(1), &
upf%rcutus(1), &
upf%els_beta(1) )
ELSE
ALLOCATE( upf%kbeta(upf%nbeta), &
upf%lll(upf%nbeta), &
upf%beta(upf%mesh, upf%nbeta), &
upf%dion(upf%nbeta, upf%nbeta),&
upf%rcut(upf%nbeta), &
upf%rcutus(upf%nbeta), &
upf%els_beta(upf%nbeta) )
END IF
END IF
!