diff --git a/io/writeOutParameters.f90 b/io/writeOutParameters.f90 index aeaa114bda6a11a1a3f8a64bbe5b8afc1eb5604f..e3e5b93d1ea81146420ca46e1f3f3ec8db5ab8d1 100644 --- a/io/writeOutParameters.f90 +++ b/io/writeOutParameters.f90 @@ -53,6 +53,10 @@ SUBROUTINE writeOutParameters(mpi,input,sym,stars,atoms,vacuum,obsolete,kpts,& CALL writeXMLElementFormPoly('density',(/'ng3','ng2'/),& attributes(:2),reshape((/7,6,8,8/),(/2,2/))) + WRITE(attributes(1),'(i0)') dimension%neigd + CALL writeXMLElementFormPoly('bands',(/'numbands'/),& + attributes(:1),reshape((/9,8/),(/1,2/))) + CALL closeXMLElement('numericalParameters') END SUBROUTINE writeOutParameters diff --git a/io/xmlOutput.F90 b/io/xmlOutput.F90 index e1c29f48fae213b99a5865541e0edf9840f39576..49219d3f82bd6fa727448e6adc8f67acc62c9f7f 100644 --- a/io/xmlOutput.F90 +++ b/io/xmlOutput.F90 @@ -48,6 +48,7 @@ MODULE m_xmlOutput USE m_constants USE m_utility USE m_compile_descr +!$ use omp_lib IMPLICIT NONE @@ -56,6 +57,7 @@ MODULE m_xmlOutput INTEGER :: err, isize #endif INTEGER :: numFlags + INTEGER :: nOMPThreads CHARACTER(LEN=8) :: date CHARACTER(LEN=10) :: time CHARACTER(LEN=10) :: zone @@ -66,6 +68,7 @@ MODULE m_xmlOutput CHARACTER(LEN=20) :: structureSpecifiers(11) CHARACTER(LEN=50) :: gitdesc,githash,gitbranch,compile_date,compile_user,compile_host CHARACTER(LEN=50) :: compile_flags,link_flags + CHARACTER(LEN=20) :: attributes(7) maxNumElements = 10 ALLOCATE(elementList(maxNumElements)) @@ -104,10 +107,24 @@ MODULE m_xmlOutput CALL writeXMLElementNoAttributes('additionalCompilerFlags',flags(1:numFlags)) END IF CALL closeXMLElement('programVersion') + + CALL openXMLElementNoAttributes('parallelSetup') + nOMPThreads = -1 + !$ nOMPThreads=omp_get_max_threads() + IF(nOMPThreads.NE.-1) THEN + WRITE(attributes(1),'(i0)') nOMPThreads + CALL writeXMLElementFormPoly('openMP',(/'ompThreads'/),& + attributes(:1),reshape((/10,8/),(/1,2/))) + END IF + #ifdef CPP_MPI CALL MPI_COMM_SIZE(MPI_COMM_WORLD,isize,err) - CALL writeXMLElementPoly('parallelizationParameters',(/'mpiPEs'/),(/isize/)) + WRITE(attributes(1),'(i0)') isize + CALL writeXMLElementFormPoly('mpi',(/'mpiProcesses'/),& + attributes(:1),reshape((/13,8/),(/1,2/))) #endif + CALL closeXMLElement('parallelSetup') + CALL writeXMLElement('startDateAndTime',(/'date','time','zone'/),(/dateString,timeString,zone/)) END SUBROUTINE startXMLOutput diff --git a/main/mix.F90 b/main/mix.F90 index c2ab89f4f141b139a01c325ca404228f774d66a4..2529cd948c77a601e8564bbac61aa3a33a5bbb76 100644 --- a/main/mix.F90 +++ b/main/mix.F90 @@ -160,17 +160,17 @@ SUBROUTINE mix(stars,atoms,sphhar,vacuum,input,sym,cell,noco,oneD,& IF (input%imix.EQ.0) THEN CALL stmix(atoms,input,noco, nmap,nmaph,fsm, sm) ELSE -! CALL broyden(cell,stars,atoms,vacuum,sphhar,input,noco,oneD,sym,& -! hybrid,mmap,nmaph,mapmt,mapvac2,nmap,fsm,sm) + CALL broyden(cell,stars,atoms,vacuum,sphhar,input,noco,oneD,sym,& + hybrid,mmap,nmaph,mapmt,mapvac2,nmap,fsm,sm) ! Replace the broyden call above by the commented metric and broyden2 calls ! below to switch on the continuous restart of the Broyden method. ! Apply metric w to sm and store in smMet: w |sm> - CALL metric(cell,atoms,vacuum,sphhar,input,noco,stars,sym,oneD,& - mmap,nmaph,mapmt,mapvac2,sm,smMet,l_pot) - - CALL broyden2(cell,stars,atoms,vacuum,sphhar,input,noco,oneD,sym,& - hybrid,mmap,nmaph,mapmt,mapvac2,nmap,fsm,sm,fmMet,smMet) +! CALL metric(cell,atoms,vacuum,sphhar,input,noco,stars,sym,oneD,& +! mmap,nmaph,mapmt,mapvac2,sm,smMet,l_pot) +! +! CALL broyden2(cell,stars,atoms,vacuum,sphhar,input,noco,oneD,sym,& +! hybrid,mmap,nmaph,mapmt,mapvac2,nmap,fsm,sm,fmMet,smMet) END IF !initiatlize mixed density and extract it with brysh2 call diff --git a/tests/tests/inpgen/Si_full_para/test.run1 b/tests/tests/inpgen/Si_full_para/test.run1 index 86bd3c9b0d39fac8f46e3d60a3c5b5df65597e53..dd4ea89553a452f267cb8a6baed2cf4909926687 100644 --- a/tests/tests/inpgen/Si_full_para/test.run1 +++ b/tests/tests/inpgen/Si_full_para/test.run1 @@ -3,7 +3,7 @@ jt::copyfile("files/inp_Si_para",$workdir); #jt::testrun("$executable < inp_Si_para",$workdir); -jt::testrun("$executable -explicit < inp_Si_para &>outshell ; cat outshell",$workdir); +jt::testrun("$executable -explicit < inp_Si_para 2>&1 >outshell ; cat outshell",$workdir); $result=jt::test_grep_error("$workdir/outshell"); #now test output diff --git a/tests/tests/inpgen/Si_plain/test.run1 b/tests/tests/inpgen/Si_plain/test.run1 index 064bc3f3676cd639635083180cbbe3e9505ebd56..a2d9ff27570e420f674bddbff4250f5bfd364965 100644 --- a/tests/tests/inpgen/Si_plain/test.run1 +++ b/tests/tests/inpgen/Si_plain/test.run1 @@ -2,8 +2,7 @@ jt::copyfile("files/inp_Si_plain",$workdir); -#jt::testrun("$executable < inp_Si_plain &> outshell | cat outshell",$workdir); -jt::testrun("$executable < inp_Si_plain &>outshell ; cat outshell",$workdir); +jt::testrun("$executable < inp_Si_plain 2>&1 >outshell ;cat outshell",$workdir); $result=jt::test_grep_error("$workdir/outshell"); diff --git a/tests/tests/inpgen/Si_plain_explicit/test.run1 b/tests/tests/inpgen/Si_plain_explicit/test.run1 index 8af0ddcbfffc68945d09766af6ef5690b052f85d..a4649c3bf9156597321f2dfe7f6cf9fd471a45b5 100644 --- a/tests/tests/inpgen/Si_plain_explicit/test.run1 +++ b/tests/tests/inpgen/Si_plain_explicit/test.run1 @@ -2,7 +2,7 @@ jt::copyfile("files/inp_Si_plain",$workdir); -jt::testrun("$executable -explicit < inp_Si_plain &>outshell ; cat outshell",$workdir); +jt::testrun("$executable -explicit < inp_Si_plain 2>&1 >outshell ; cat outshell",$workdir); # test for errors and warnings $result=jt::test_grep_error("$workdir/outshell");