File tree Expand file tree Collapse file tree 1 file changed +13
-6
lines changed
GEOSagcm_GridComp/GEOSphysics_GridComp/GEOSmoist_GridComp Expand file tree Collapse file tree 1 file changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -23,14 +23,21 @@ endif ()
2323
2424if (CMAKE_Fortran_COMPILER_ID MATCHES GNU AND CMAKE_BUILD_TYPE MATCHES Release)
2525 string (REPLACE "${FOPT3} " "${FOPT2} " CMAKE_Fortran_FLAGS_RELEASE ${CMAKE_Fortran_FLAGS_RELEASE} )
26- # There is some odd interaction between GCC 15 and the GF code. FPEs
27- # that do not occur with GCC 14 or earlier. For now, we compile GF
26+
27+ # GCC 15+ workaround for some moist sources
28+ # There is some odd interaction between GCC 15 and some moist code. FPEs
29+ # that do not occur with GCC 14 or earlier. For now, we compile some
2830 # codes with -O1 which seems to avoid the bad instruction. Tests show
2931 # not much of a speed difference with GCC 14
30- if (${CMAKE_Fortran_COMPILER_VERSION} VERSION_GREATER_EQUAL 15)
31- message (STATUS "[GCC15+] Setting GF Code to use -O1 for GCC 15" )
32- set_source_files_properties (ConvPar_GF2020.F90 PROPERTIES COMPILE_OPTIONS ${FOPT1} )
33- set_source_files_properties (ConvPar_GF_GEOS5.F90 PROPERTIES COMPILE_OPTIONS ${FOPT1} )
32+ if (CMAKE_Fortran_COMPILER_VERSION VERSION_GREATER_EQUAL 15)
33+ message (STATUS "[GCC15+] Setting GF Code to use -O1 for GCC 15" )
34+ set (degrade_o1_sources
35+ ConvPar_GF2020.F90
36+ ConvPar_GF_GEOS5.F90
37+ aer_actv_single_moment.F90
38+ )
39+ set_source_files_properties (${degrade_o1_sources}
40+ PROPERTIES COMPILE_OPTIONS "${FOPT1} " )
3441 endif ()
3542endif ()
3643
You can’t perform that action at this time.
0 commit comments