support for ufs-s2s-model debug compilaiton#40
Conversation
MinsukJi-NOAA
commented
Mar 9, 2020
- automatically enable NEMS_BUILDOPT=DEBUG=Y based on coupledFV3_MOM6_CICE_debug.appBuilder
- automatically use esmf/8.0.0g module based on coupledFV3_MOM6_CICE_debug.appBuilder
* automatically enable NEMS_BUILDOPT=DEBUG=Y based on coupledFV3_MOM6_CICE_debug.appBuilder * automatically use esmf/8.0.0g module based on coupledFV3_MOM6_CICE_debug.appBuilder
|
I will try this in the s2s branch I am working for with CMEPS. In that case, we build the alternate mediator using COMPONENTS=( FMS FV3%CMEPS=Y MOM6 CICE CMEPS ) in the appbuilder. The debug version uses CMEPS%DEBUG=Y, so I need to add the MAKE_OPT to the component_CMEPS.mk. Will the configure_rules.mk break if a component is listed that isn't being built? |
If you specify "COMPONENTS=( FMS FV3%DEBUG=Y%CMEPS=Y MOM6%DEBUG=Y CICE%DEBUG=Y CMEPS%DEBUG=Y )", it should work. |
|
ufs-weather-model regression tests passed on hera: |
|
I tried the CMEPS version of the build but I had two problems.
My test build is here: /scratch2/NCEPDEV/climate/Denise.Worthen/WORK/TSTdebug/CMEPS_br/NEMS In NEMS/debugbuild_setg I've set the esmfg manually. See line 2213 for the compile of module_MEDIATOR.F90 using '-O2 -debug minimal'. I will try with just the NEMS version and report back. |
|
I apologize for this taking so long for me to review. It appears to be working on hera; I now see the code w/in NEMS/src compiled with debug flags. I've also built the CMEPS mediator version and that also compiles w/ the correct debug flags if I add CMEPS_MAKEOPT to the component_CMEPS.mk. When we move to cmeps we'll need to add that as a debug option. The auto-load of the esmf debug modules I now realize is problematic though. It works on Hera because we have a single module to point to (esmf8.0.0g). It is different on Cheyenne though (first load esmf_libs/8.0.0 and then a specific debug module). I think we might just have to leave it to the user to load the correct esmf debug modules. |
|
At one point, we would specify which module file to use in the appBuilder file. Now that is done in conf/before_components.mk Maybe we would add a module file fv3_coupled_debug and choose that module file in conf/before_components.mk based on some setting. I don't remember the order of what gets read first. |
|
Right...it is specified in before_components.mk. I can't remember the details now, but it was not so straightforward to auto load a different esmf module, because it was a prerequisite of build_NEMS target in NEMS.mk. For this PR, let me remove the automatic esmf module change. So... it will just be the NEMS_BUILDOPT=DEBUG=Y. |
*Remove the previous approach of auto-loading esmf debug module
*Use S2S_DEBUB_MODULE env var to load machine-dependent esmf debug module
*Require ufs-s2s-model/modules/${BUILD_TARGET}/fv3_coupled_debug file
|
support for ufs-s2s-model debug compilaiton (NOAA-EMC#40)
* support for ufs-s2s-model debug compilaiton (NOAA-EMC#40) * automatically enable NEMS_BUILDOPT=DEBUG=Y based on coupledFV3_MOM6_CICE_debug.appBuilder * automatically use esmf/8.0.0g module based on coupledFV3_MOM6_CICE_debug.appBuilder * Change debug flag check from ifeq to findstring * Loading machine-dependent esmf debug module *Use S2S_DEBUB_MODULE env var to load machine-dependent esmf debug module *Require ufs-s2s-model/modules/${BUILD_TARGET}/fv3_coupled_debug file * cmeps integration changes (NOAA-EMC#55) * Bugfix i2a & Add Orion to module-setup (NOAA-EMC#61) * Add Orion to module-setup.*.inc * src/incmake/component_CCPP.mk: SUITES argument no longer mandatory for calling ccpp_prebuild.py (NOAA-EMC#62) Co-authored-by: Minsuk Ji <57227195+MinsukJi-NOAA@users.noreply.github.com> Co-authored-by: Mariana Vertenstein <mvertens@ucar.edu> Co-authored-by: Dom Heinzeller <dom.heinzeller@icloud.com>