diff --git a/.github/workflows/linux_gnu.yml b/.github/workflows/linux_gnu.yml index 7ce3e81..fbdfa30 100644 --- a/.github/workflows/linux_gnu.yml +++ b/.github/workflows/linux_gnu.yml @@ -26,18 +26,18 @@ jobs: run: sudo apt-get install openmpi-bin libopenmpi-dev -y # Test debug mode - #- name: Build gf debug - # run: | - # cd ref - # rm -rf build - # mkdir build - # cd build - # export OMP_NUM_THREADS=4 - # export CC=gcc - # export FC=gfortran - # cmake -DCMAKE_BUILD_TYPE=debug .. - # make - # ctest --output-on-failure + - name: Build gf debug + run: | + cd ref + rm -rf build + mkdir build + cd build + #export OMP_NUM_THREADS=4 + export CC=gcc + export FC=gfortran + cmake -DCMAKE_BUILD_TYPE=debug -DENABLE_GPU=off .. + make + ctest --output-on-failure # Test release mode - name: Build gf release diff --git a/.github/workflows/linux_intel.yml b/.github/workflows/linux_intel.yml index 754a997..dfa615c 100644 --- a/.github/workflows/linux_intel.yml +++ b/.github/workflows/linux_intel.yml @@ -55,20 +55,19 @@ jobs: uses: actions/checkout@v2 # Test debug mode - #- name: Build gf debug - # run: | - # source /opt/intel/oneapi/setvars.sh - # cd ref - # rm -rf build - # mkdir build - # cd build - # export OMP_NUM_THREADS=4 - # export CC=icx - # export FC=ifx - # cmake -DCMAKE_BUILD_TYPE=debug .. - # make - # ulimit -s unlimited - # ctest --output-on-failure + - name: Build gf debug + run: | + source /opt/intel/oneapi/setvars.sh + cd ref + rm -rf build + mkdir build + cd build + #export OMP_NUM_THREADS=4 + export CC=icx + export FC=ifx + cmake -DCMAKE_BUILD_TYPE=debug -DENABLE_GPU=off .. + make VERBOSE=1 + ctest --output-on-failure # Test release mode - name: Build gf release diff --git a/ref/cmake/compiler_flags_Intel_Fortran.cmake b/ref/cmake/compiler_flags_Intel_Fortran.cmake index dff3a4c..84dfc2f 100644 --- a/ref/cmake/compiler_flags_Intel_Fortran.cmake +++ b/ref/cmake/compiler_flags_Intel_Fortran.cmake @@ -2,7 +2,7 @@ # COMMON FLAGS #################################################################### -set( CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -g -traceback -fp-model precise " ) +set( CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -g -traceback -fp-model precise -assume nominus0" ) #################################################################### # RELEASE FLAGS @@ -14,7 +14,7 @@ set( CMAKE_Fortran_FLAGS_RELEASE "-O3 -xHost " ) # DEBUG FLAGS #################################################################### -set( CMAKE_Fortran_FLAGS_DEBUG "-O0 -debug -nolib-inline -fno-inline-functions -assume protect_parens,minus0 -prec-div -prec-sqrt -check bounds -check uninit -fp-stack-check -init=snan,array -warn unused" ) +set( CMAKE_Fortran_FLAGS_DEBUG "-O0 -debug -nolib-inline -fno-inline-functions -assume protect_parens -prec-div -prec-sqrt -check bounds -fp-stack-check -init=snan,array -warn unused" ) #################################################################### # FLAGS FOR GPUS diff --git a/ref/src/gf_test.F90 b/ref/src/gf_test.F90 index 152b693..f210b3c 100644 --- a/ref/src/gf_test.F90 +++ b/ref/src/gf_test.F90 @@ -239,6 +239,7 @@ program test_gf cactiv_m(i) = 1 + mod(i,3) enddo CALL mt19937_real2d(forcet(s:e,:)) + forcet(s:e,:) = forcet(s:e,:) * 0.001 CALL mt19937_real2d(forceqv_spechum(s:e,:)) CALL mt19937_real2d(phil(s:e,:)) CALL mt19937_real1d(raincv(s:e)) diff --git a/test/test_output/output.test b/test/test_output/output.test index 7e68c0e..1544b46 100644 --- a/test/test_output/output.test +++ b/test/test_output/output.test @@ -7,7 +7,7 @@ TEST --------------------------------------------------------------------------- TEST garea 3.2777241431E-03 9.9886531830E+00 4.9934797287E+00 7.8682093620E+00 7.4988007545E+00 2.8921554089E+00 TEST cactiv 1 2 1 2 1 1.0000000000E+00 TEST cactiv_m 1 3 2 2 3 0.0000000000E+00 -TEST forcet 2.2139556677E-05 9.9999094009E+00 5.0008244514E+00 3.8052468300E+00 6.1191511154E+00 2.8780047894E+00 +TEST forcet 2.2139557743E-08 9.9999094382E-03 5.0008245744E-03 3.8052469026E-03 6.1191515997E-03 2.8780072462E-03 TEST forceqv_spechum 1.5488486679E-04 9.9997625351E+00 5.0179624557E+00 9.9661817551E+00 9.4433851242E+00 2.8892364502E+00 TEST phil 4.9237874919E-05 9.9999685287E+00 5.0032367706E+00 8.3698558807E+00 6.1671215296E-01 2.8890116215E+00 TEST raincv 2.2879648022E-03 9.9959421158E+00 5.1559128761E+00 8.5739431381E+00 2.6720688343E+00 2.9124729633E+00 @@ -53,7 +53,7 @@ TEST --------------------------------------------------------------------------- TEST garea 3.2777241431E-03 9.9886531830E+00 4.9934797287E+00 7.8682093620E+00 7.4988007545E+00 2.8921554089E+00 TEST cactiv 0 0 0 0 0 0.0000000000E+00 TEST cactiv_m 0 0 0 0 0 0.0000000000E+00 -TEST forcet 2.2139556677E-05 9.9999094009E+00 5.0008244514E+00 3.8052468300E+00 6.1191511154E+00 2.8780047894E+00 +TEST forcet 2.2139557743E-08 9.9999094382E-03 5.0008245744E-03 3.8052469026E-03 6.1191515997E-03 2.8780072462E-03 TEST forceqv_spechum 1.5488486679E-04 9.9997625351E+00 5.0179624557E+00 9.9661817551E+00 9.4433851242E+00 2.8892364502E+00 TEST phil 4.9237874919E-05 9.9999685287E+00 5.0032367706E+00 8.3698558807E+00 6.1671215296E-01 2.8890116215E+00 TEST raincv 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00