Skip to content

Commit

Permalink
Merge branch 'ndk/machinefiles/PM-add-arg-pack-flag-gnu10' into next …
Browse files Browse the repository at this point in the history
…(PR #4836)

Add a flag to disable new behavior in gnu v10. For now, just do this only for Perlmutter and gnu v10+.

This PR adds to new files to be specific to Perlmutter for now.

Flag itself does not change results, but the tests were hitting errors without it.
  • Loading branch information
ndkeen committed Mar 16, 2022
2 parents e1bbb00 + 8690d0a commit 85656d9
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
14 changes: 14 additions & 0 deletions cime_config/machines/Depends.perlmutter.gnu.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
list(APPEND NO_INLINE_ARG_PACKING_LIST
eam/src/dynamics/se/inidat.F90
)

if (CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER_EQUAL 10)

if (NOT DEBUG)
# new in gnu10, inline arg packing was causing INF values with SMS_P4x1.ne4pg2_ne4pg2.F-MMFXX
foreach(ITEM IN LISTS NO_INLINE_ARG_PACKING_LIST)
e3sm_add_flags("${ITEM}" " -fno-inline-arg-packing")
endforeach()
endif()

endif()
15 changes: 15 additions & 0 deletions cime_config/machines/Depends.perlmutter.gnugpu.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
list(APPEND NO_INLINE_ARG_PACKING_LIST
eam/src/dynamics/se/inidat.F90
)

if (CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER_EQUAL 10)

if (NOT DEBUG)
# new in gnu10, inline arg packing was causing INF values with SMS_P4x1.ne4pg2_ne4pg2.F-MMFXX
foreach(ITEM IN LISTS NO_INLINE_ARG_PACKING_LIST)
e3sm_add_flags("${ITEM}" " -fno-inline-arg-packing")
endforeach()
endif()

endif()

0 comments on commit 85656d9

Please sign in to comment.