Skip to content

Commit

Permalink
Merge branch 'dev/gfdl' into USTAR_GUSTLESS_BUG
Browse files Browse the repository at this point in the history
  • Loading branch information
marshallward authored Dec 19, 2023
2 parents 9e1fe8a + a28443b commit cf51b9f
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 13 deletions.
15 changes: 15 additions & 0 deletions .github/actions/macos-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,18 @@ runs:
brew install netcdf-fortran
brew install mpich
echo "::endgroup::"
# NOTE: Floating point exceptions are currently disabled due to an error in
# HDF5 1.4.3. They will be re-enabled when the default brew version has
# been updated to a working version.

- name: Set compiler flags
shell: bash
run: |
cd .testing
echo "FCFLAGS_DEBUG = -g -O0 -Wextra -Wno-compare-reals -fbacktrace -fcheck=bounds" >> config.mk
echo "FCFLAGS_REPRO = -g -O2 -fbacktrace" >> config.mk
echo "FCFLAGS_INIT = -finit-real=snan -finit-integer=2147483647 -finit-derived" >> config.mk
echo "FCFLAGS_FMS = -g -fbacktrace -O0" >> config.mk
cat config.mk
echo "::endgroup::"
11 changes: 0 additions & 11 deletions .github/actions/testing-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,6 @@ runs:
REPORT_ERROR_LOGS=true make deps/lib/libFMS.a -s -j
echo "::endgroup::"
- name: Store compiler flags used in Makefile
shell: bash
run: |
echo "::group::config.mk"
cd .testing
echo "FCFLAGS_DEBUG=-g -O0 -Wextra -Wno-compare-reals -fbacktrace -ffpe-trap=invalid,zero,overflow -fcheck=bounds" >> config.mk
echo "FCFLAGS_REPRO=-g -O2 -fbacktrace" >> config.mk
echo "FCFLAGS_INIT=-finit-real=snan -finit-integer=2147483647 -finit-derived" >> config.mk
cat config.mk
echo "::endgroup::"
- name: Compile MOM6 in symmetric memory mode
shell: bash
run: |
Expand Down
12 changes: 12 additions & 0 deletions .github/actions/ubuntu-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,15 @@ runs:
sudo apt-get install libopenmpi-dev
sudo apt-get install linux-tools-common
echo "::endgroup::"
- name: Store compiler flags used in Makefile
shell: bash
run: |
echo "::group::config.mk"
cd .testing
echo "FCFLAGS_DEBUG = -g -O0 -Wextra -Wno-compare-reals -fbacktrace -ffpe-trap=invalid,zero,overflow -fcheck=bounds" >> config.mk
echo "FCFLAGS_REPRO = -g -O2 -fbacktrace" >> config.mk
echo "FCFLAGS_INIT = -finit-real=snan -finit-integer=2147483647 -finit-derived" >> config.mk
echo "FCFLAGS_FMS = -g -fbacktrace -O0" >> config.mk
cat config.mk
echo "::endgroup::"
4 changes: 2 additions & 2 deletions src/core/MOM_open_boundary.F90
Original file line number Diff line number Diff line change
Expand Up @@ -3919,7 +3919,7 @@ subroutine update_OBC_segment_data(G, GV, US, OBC, tv, h, Time)
segment%Htot(I,j) = segment%Htot(I,j) + segment%h(I,j,k)
segment%dZtot(I,j) = segment%dZtot(I,j) + dz(i+ishift,j,k)
enddo
segment%Cg(I,j) = sqrt(GV%g_prime(1) * segment%dZtot(I,j))
segment%Cg(I,j) = sqrt(GV%g_prime(1) * max(0.0, segment%dZtot(I,j)))
enddo
else! (segment%direction == OBC_DIRECTION_N .or. segment%direction == OBC_DIRECTION_S)
allocate(normal_trans_bt(segment%HI%isd:segment%HI%ied,segment%HI%JsdB:segment%HI%JedB), source=0.0)
Expand All @@ -3933,7 +3933,7 @@ subroutine update_OBC_segment_data(G, GV, US, OBC, tv, h, Time)
segment%Htot(i,J) = segment%Htot(i,J) + segment%h(i,J,k)
segment%dZtot(i,J) = segment%dZtot(i,J) + dz(i,j+jshift,k)
enddo
segment%Cg(i,J) = sqrt(GV%g_prime(1) * segment%dZtot(i,J))
segment%Cg(i,J) = sqrt(GV%g_prime(1) * max(0.0, segment%dZtot(i,J)))
enddo
endif

Expand Down

0 comments on commit cf51b9f

Please sign in to comment.