From 05c8a63e1a33a5ccb6ed83ac97c828ac209c9a21 Mon Sep 17 00:00:00 2001 From: Niri Govind Date: Fri, 4 Jan 2013 18:04:34 +0000 Subject: [PATCH] response updates from Fredy Aquino --- src/hessian/analytic/GNUmakefile | 2 +- src/hessian/analytic/shell_fock_build.F | 41 +++++-------------- ...fock_build_nw.F => shell_fock_build_ext.F} | 0 3 files changed, 12 insertions(+), 31 deletions(-) rename src/hessian/analytic/{shell_fock_build_nw.F => shell_fock_build_ext.F} (100%) diff --git a/src/hessian/analytic/GNUmakefile b/src/hessian/analytic/GNUmakefile index 049e18135d..2fe08ed827 100644 --- a/src/hessian/analytic/GNUmakefile +++ b/src/hessian/analytic/GNUmakefile @@ -27,7 +27,7 @@ OBJ_OPTIMIZE = hess_anal.o \ hess_tidy.o\ uhf_fock_setup.o uhf_fock_finish.o\ print_dens_bit.o \ - shell_fock_build_nw.o + shell_fock_build_ext.o LIBRARY = libhessian.a diff --git a/src/hessian/analytic/shell_fock_build.F b/src/hessian/analytic/shell_fock_build.F index 5c5887042d..5e546f3eab 100644 --- a/src/hessian/analytic/shell_fock_build.F +++ b/src/hessian/analytic/shell_fock_build.F @@ -340,10 +340,9 @@ c c c replicated DM and Fock Matrix c -c turned off for nbf gt 500 since becomes a memory hog +c turned off for now: needs to be debugged c dorepon=.true. - if(nbf.gt.500) dorepon=.false. dorepl=.false. if(ga_cluster_nnodes().gt.1.and.dorepon) then docopy=.true. @@ -364,10 +363,6 @@ c g_fock=g_fockrep else if(dorepd) call util_mirrstop(1,g_densrep) - if(ga_nodeid().eq.0) then - write(6,*) ' no mirroring in shellfockbld' - call util_flush(6) - endif endif endif c write(6,*) 'nshblocks and task_size ',nshblocks,task_size @@ -626,12 +621,14 @@ c $ g_dens, ndens, blen, ibflo, ibfhi, jbflo, jbfhi, buf, fac) implicit none integer ndens, g_dens, blen, ibflo, ibfhi, jbflo, jbfhi + integer blen2 double precision buf(*), fac(ndens) c integer lo(3), hi(3), ld(3) integer idens c -cedo call dcopy(ndens*blen*blen,0d0,0,buf,1) + blen2 = blen*blen + call dcopy(ndens*blen*blen,0d0,0,buf,1) lo(1) = 1 hi(1) = ndens lo(2) = ibflo @@ -658,30 +655,14 @@ c integer idens, i, j double precision factor c - if(ndens.eq.1) then - factor = fac(1) - do j = 1, jbfhi-jbflo+1 - do i = 1, ibfhi-ibflo+1 - buf(1,i,j) = buf(1,i,j) * factor - enddo + do idens = 1, ndens + factor = fac(idens) + do i = 1, ibfhi-ibflo+1 + do j = 1, jbfhi-jbflo+1 + buf(idens,i,j) = buf(idens,i,j) * factor + enddo enddo - elseif(ndens.eq.2) then - do j = 1, jbfhi-jbflo+1 - do i = 1, ibfhi-ibflo+1 - buf(1,i,j) = buf(1,i,j) * fac(1) - buf(2,i,j) = buf(2,i,j) * fac(2) - enddo - enddo - else - do idens = 1, ndens - factor = fac(idens) - do i = 1, ibfhi-ibflo+1 - do j = 1, jbfhi-jbflo+1 - buf(idens,i,j) = buf(idens,i,j) * factor - enddo - enddo - enddo - endif + enddo c return end diff --git a/src/hessian/analytic/shell_fock_build_nw.F b/src/hessian/analytic/shell_fock_build_ext.F similarity index 100% rename from src/hessian/analytic/shell_fock_build_nw.F rename to src/hessian/analytic/shell_fock_build_ext.F