Repository navigation
Senh homme update bringing in Mark Taylor's split-form theta advection and tensor sponge layer. - #99
Conversation
|
@mt5555 This PR updates senh's HOMME to E3SM master to allow access to the tensor sponge layer. Its currently off by default. When it's turned on and The user can also set se_tom_sponge_start (default 0, keeping the existing profile). Are there default values you’d recommend to use with the tensor sponge for our high res stormspeed runs” |
…d ChangeLog_stormspeed - Update ccs_config to ccs_config_cesm1.0.91_nh.03 (jtruesdal/ccs_config_cesm): machines/izumi/gnu_izumi.cmake restores the unconditional -fallow-argument-mismatch -fallow-invalid-boz (non-Kokkos GNU builds on izumi failed on BOZ literals); machines/cmake_macros/nag.cmake sets MPICXX/SCXX so NAG builds that need C++ (Kokkos for theta-l) have a C++ compiler. - Add doc/ChangeLog_stormspeed: StormSPEED tag history (cam6_4_211_ss.NN).
…pdate - Update ccs_config to ccs_config_cesm1.0.91_nh.04 (jtruesdal/ccs_config_cesm): machines/izumi/intel_izumi.cmake adds -heap-arrays 64. Izumi Intel runs segfaulted in routines with large automatic arrays (e.g. RRTMG) placed on the stack (#103). - doc/ChangeLog_stormspeed: ss.01 entry updated; ss.00 entry expanded (CAM changes beyond cam6_4_211, forked externals, derecho and izumi status).
New composable testmods: outfrq9s_thetal_hy, outfrq9s_thetal_kokkos_hy (se_theta_hydrostatic_mode=.true., se_tstep_type=2), outfrq9s_thetal{,_kokkos}_rstunstruct (se_write_restart_unstruct=.true.), outfrq9s_thetal_interp (GLL interpolated output), outfrq9s_preqx (CAM_TARGET=preqx).
New testlist entries (37 tests, 122 machine/compiler instances): aux_cam_e3sm (tier-1 BFB gate for theta-l and theta-l_kokkos: SMS_D NH and hydrostatic, ERS, ERP, PEM, PET, ERI_D on ne3pg3 FHISTC_LTso; ERS ne16pg3; SMS_D FKESSLER ne16; SMS_D/ERS QPC6 GLL ne3; ne30 F2000climo ERS/ERP and FHISTC_MTso SMS on derecho intel), aux_cam_e3sm_perf (PFS timing), aux_cam_preqx, aux_cam_e3sm_unify (tests that require the unified SE interface: unstructured restart, interpolated output). Test definitions only; no source changes.
se_tstep_type=2 is not a theta-l timestepper (Fortran: bad choice of tstep_type; Kokkos: unsupported time_step_type). 5 (explicit KG5) is the non-IMEX scheme both Fortran and Kokkos theta-l implement. PET_Ln9 removed for theta-l_kokkos: CAM refuses threads for that target (dyn_readnl: set NTHRDS_ATM=1). theta-l PET kept.
ERI .ref2 (hybrid) runs failed in CTSM restFileMod (finidat year-consistency check for transient compsets). The existing CAM ERI tests use the outfrq3s_eri testmod, which sets check_finidat_year_consistency=.false. in user_nl_clm. New testmods outfrq3s_eri_thetal and outfrq3s_eri_thetal_kokkos include outfrq3s_eri and set CAM_TARGET; the two E3SM-dycore ERI_D_Ln18 tests now use them.
…a_hydrostatic_mode) The restart writer only defines and writes W and PHINH when not in hydrostatic mode, but read_restart_dynamics, read_elem and read_unstruct looked for and read them unconditionally, so every hydrostatic theta-l restart aborted with "read_restart_dynamics: cannot find W". As in E3SM/EAM, skip the lookups and reads in hydrostatic mode and zero w_i and phinh_i (not prognostic; phinh_i is rediagnosed). Found by the new ERS_Ln9 ...cam-outfrq9s_thetal_hy and _kokkos_hy tests.
HOMME C++ (ComposeTransportImpl, KokkosKernels SIMD templates) does not compile with nvc++ on derecho. Fortran theta-l nvhpc tests are kept.
On izumi (MVAPICH2) the model's MPI_Win_shared_query returns size 0 and no address to every non-leader rank, so node-shared tables (soil_erod, phys_prop, mo_jlong, tracer_data) were null on 23 of 24 ranks. init_comms now probes a small window; if any rank cannot see it (or cam_shmem_force_private is set), every rank becomes its own node (node_size 1, all leaders, leader_comm = all ranks), so callers hold private copies and answers are unchanged. The atm log reports the probe result (PASSED/FAILED) and whether shared or private memory is used. New namelist cam_shmem_nl/cam_shmem_force_private (default .false., not written to atm_in by default); cam_shmem_init now runs after read_namelist.
…d source From ESCOMP/CAM PR ESCOMP#1643 (commit 0b0bd23, fix_shared_read_and_carry): - the in-memory carry-forward of a time record also requires the same file name, since PIO file handles can be reused across files; - the node-shared source field is read on masterproc only and broadcast to the node leaders over cam_shmem_leader_comm (was: every leader read it).
SHM (SystemTestsCompareTwo, one build): run one with default cam_shmem settings, run two with cam_shmem_force_private = .true.; history must be identical. Where the shared-window probe passes (derecho) this proves the shared tables match private memory; where it fails (izumi) it exercises the fallback. Tests in aux_cam: SHM_D_Ln9.ne3pg3_ne3pg3_mt232.FHISTC_LTso.cam-outfrq9s (phys_prop, soil_erod, tracer_data) SHM_D_Ln3.f10_f10_mg37.QPMOZ.cam-outfrq3s_chemproc (mo_jlong)
aux_cam_e3sm (gate): derecho intel runs the full theta-l/theta-l_kokkos set
(SMS_D, ERS, ERP, PEM, PET, ERI_D, ne16pg3, QPC6 GLL, FKESSLER, ne30);
derecho gnu runs SMS_D/ERS core (NH and hydrostatic), FKESSLER and QPC6 SMS_D;
izumi gnu runs the SMS_D/ERS core.
Removed from theta-l testing until their blockers are fixed (issues filed):
derecho nvhpc - HOMME C++ (Kokkos) does not build with nvc++; Fortran ERP
not reproducible across layout/threads (under investigation)
izumi nag - E3SM HOMME sort_mod.F90 declaration order (upstream)
izumi intel - COMPOSE segfault (under investigation)
New category aux_cam_e3sm_canary: SMS_D_Ln9 ne3pg3 FHISTC_LTso theta-l on derecho
nvhpc, to notice when NVHPC works again. aux_cam_e3sm_unify moves from izumi gnu
to derecho gnu. The pre-existing FKESSLER ERS_Ln27/ERP_Ln27 theta-l tests keep
aux_cam on derecho intel and izumi gnu only.
Moves the senh/dycore submodule (sparse: preqx, share, theta-l, theta-l_kokkos) across 25 E3SM merges touching those directories, including Mark Taylor split-form theta advection (#8441), tensor sponge (#8642), tensorvisc and gradw fixes for Hommexx (#8597, #8192), the CAAR race fix (#8027), horizontal/3D turbulence options (#8013, #8392, #8630), and Fortran-C++ transfer reductions (#8627). New options default to previous behavior (theta_advect_form=0, laplace_scaling=0, do_3d_turbulence=.false.). Regenerated cam_mods/namelist_mod.F90 from master (still only the dead CAM-only use dyn_grid block removed). Hommexx at master builds with CAM libraries/kokkos 4.5.1 (E3SM master pins 5.1.0). Builds (clean atm; no circular dependencies); BFB vs ref_dec87846 on ne3pg2 theta-l, theta-l_kokkos and theta-l with 2 threads.
New senh dyn_se_inparm option wired like se_hypervis_scaling (namelist definition, namelist_defaults_senh 0.0 for theta-l and preqx, build-namelist senh list, dyn_readnl declaration/namelist/default/bcast/assignment). 0 keeps the constant-coefficient sponge Laplacian; a positive value selects the tensor Laplacian from E3SM HOMME PR #8642 (Mark Taylor). Not exposed by EAM. Builds (clean atm; no circular dependencies); BFB vs ref_dec87846 (ne3pg2 theta-l, theta-l_kokkos).
…units Documentation only. With se_laplace_scaling > 0, se_nu_top is a tensor-scaled coefficient (E3SM HOMME tests: laplace_scaling = 1, nu_top = 5e-7 to 8e-7); with the default se_nu_top the run aborts in HOMME EOS checks within a few steps. Smoke tests on ne3pg2 (theta-l and theta-l_kokkos with se_laplace_scaling = 1, se_nu_top = 5e-7; theta-l with se_theta_advect_form = 2): all complete without NaNs and differ from the default as expected.
…2/s values When se_laplace_scaling > 0 (tensor sponge) and se_nu_top is not set, use 5.0e-7 (E3SM HOMME tests, low resolution; value for finer grids to be confirmed with Mark Taylor). If se_nu_top > 1.0e-2 it is a constant-coefficient value in m^2/s and build-namelist stops with an explanation, instead of the run aborting in HOMME EOS checks. No effect at the default se_laplace_scaling = 0 (tensor sponge stays off). Verified with preview_namelists: default case unchanged (se_laplace_scaling = 0, se_nu_top = 2.5e5); se_laplace_scaling = 1 alone gives se_nu_top = 5.0e-7; se_laplace_scaling = 1 with se_nu_top = 2.5e5 stops with the error.
New senh dyn_se_inparm option wired like se_laplace_scaling (namelist definition, namelist_defaults_senh 0.0 for theta-l and preqx, build-namelist senh list, dyn_readnl declaration/namelist/default/bcast/assignment). 0 keeps HOMME standard sponge profile (follows the model-top pressure); a positive value starts the sponge at that pressure. Applies to both the constant-coefficient and tensor sponge; E3SM HOMME tests use 15-30 hPa with the tensor sponge. Builds (clean atm; no circular dependencies); BFB vs ref_dec87846 (ne3pg2 theta-l, theta-l_kokkos).
7063cd7 to
d3d3854
Compare
E3SM-dycore regression tests and the bugs they found (cam6_4_211_ss.02) Review summary (prepared with Claude; every change dry-run in a sandbox clone before applying; merge simulated against stormspeed and clean) Scope: E3SM-dycore regression tests plus the problems they exposed. 11 commits: tests and testmods, hydrostatic restart fix, cam_shmem probe and fallback, tracer_data fix (from ESCOMP/CAM ESCOMP#1643), new SHM system test, platform reorganization, ChangeLog. Code changes reviewed: senh/restart_dynamics.F90: hydrostatic restarts no longer read W/PHINH (not written in hydrostatic mode); w_i/phinh_i zeroed, as in E3SM. NH path unchanged. cam_shmem_mod.F90: one collective 64-byte window probe at init; if any rank can’t see the leader’s window (or cam_shmem_force_private), every rank becomes its own node, so callers keep working unchanged with private copies. cam_shmem_init moved after read_namelist. New namelist variable defined but not written to atm_in (no namelist changes for existing tests). tracer_data.F90: identical to ESCOMP/CAM ESCOMP#1643’s version (+30/−4). Testing: Derecho gate aux_cam_e3sm: Intel 33/33, GNU 16/16 PASS. SHM (shared vs private must be BFB): Derecho 3/3 and Izumi 4/4 PASS; logs confirm both modes. Probe PASSES with Derecho MPICH and Izumi GNU MVAPICH2, FAILS with Izumi Intel/NAG MVAPICH2 (#106), where the fallback gives identical answers. Hydrostatic restart: ERS theta-l and theta-l_kokkos, Intel and GNU: 4/4 PASS (previously “cannot find W”). Izumi aux_cam GNU and NAG vs cam6_4_211: answers BFB, so the tracer_data change altered no answers; NAG full physics runs on Izumi for the first time. Derecho aux_cam Intel/NVHPC vs ss.00: in progress at merge; results to be recorded with the next tag. Known issues (none on a gate platform): #110 (Izumi GNU 12.4 optimized ERS NaNs in HOMME diagnostics after restart; debug passes), #107 (Izumi Intel optimized FoX/CDEPS startup crash), #101 (NVHPC decomposition reproducibility, canary only). Answers: no changes (SHM BFB, restart-only fix, Izumi aux_cam BFB). Merge: “Create a merge commit”; #99 (ss.03) is built on this branch.
|
Review summary (prepared with Claude; changes dry-run in a sandbox clone; rebase onto PR 1 verified by identical patch-ids; merge sequence #109 → #99 simulated and clean) Scope: HOMME update 057df66 → E3SM master b70b675a7b (Mark Taylor’s split-form theta advection; tensor sponge-layer Laplacian, E3SM PR #8642), plus two new namelist options and the ss.03 ChangeLog entry. 6 commits, 8 files. Changes reviewed: se_laplace_scaling (default 0: constant-coefficient sponge as before; > 0: tensor sponge, with se_nu_top in tensor-scaled units). Testing (Derecho, vs the ss.02 gate baselines stormspeed_2647799a_e3sm_*): GNU aux_cam_e3sm: 16/16 BFB. Answers: none changed with default settings (BFB); the new options change answers only when set. Merge: “Create a merge commit”. Baselines: stormspeed_d3d38547_e3sm_intel/_gnu. |
senh: update HOMME to E3SM master; expose the tensor sponge layer
Moves senh's HOMME (E3SM submodule, sparse:
preqx,share,theta-l,theta-l_kokkos) from057df66(Nov 2025) to E3SM masterb70b675a7b(Oct 19, 2026), bringing in Mark Taylor's split-form theta advection and tensor sponge layer. Bit-for-bit at default settings on theta-l, theta-l_kokkos and threaded theta-l.Commits
78e6c5cfHOMME → E3SM master. 25 upstream merges touch the sparse directories, including:cam_mods/namelist_mod.F90is regenerated from master (still only the dead CAM-onlyuse dyn_gridblock removed).558c3545exposese_laplace_scaling(default 0: tensor sponge off, as before), wired likese_hypervis_scaling. Not exposed by EAM.f0829787documentation: withse_laplace_scaling > 0,se_nu_topmust be in tensor-scaled units.e6926b80build-namelistsafeguards for the tensor sponge: whense_laplace_scaling > 0andse_nu_topis not set, use5.0e-7(E3SM HOMME test value; finer-grid value to be confirmed with Mark Taylor). Ase_nu_topabove1.0e-2(m²/s) stopsbuild-namelistwith an explanation. No effect at the default.7063cd73exposese_tom_sponge_startNotes from review
se_theta_advect_formstays 1 for theta-l (as in EAM),se_laplace_scaling = 0,do_3d_turbulence = .false..se_theta_advect_form = 2(requiresse_pgrad_correction = 0).prim_init2runsdss_hvtensor(in the baseprim_init2) beforeprim_init_elements_viewscopies bothtensorViscandtensorVisc_2to C++, so senh already used the smoothed tensors. This is consistent with Kokkos being BFB.057df66. E3SM master now pins 5.1.0 through EKAT, which Hommexx doesn't use. Moving CAM to Kokkos 5.1 (C++20) is left as a separate decision.cam_modsmodules are wrappers around the HOMME modules, with no name clashes against master.Testing (derecho, intel)
Persistent ne3pg2 FHISTC_LTso cases (h0a, h0i, cam.i), against the
dec87846referenceBuilds clean (
--clean atm), no circular dependencies.Smoke tests of the new options (ne3pg2, 9 steps)
se_laplace_scaling = 1,se_nu_top = 5e-7se_theta_advect_form = 2,se_pgrad_correction = 0With the default
se_nu_top,se_laplace_scaling > 0aborts within a few steps (EOS bad state); hence commits 3 and 4. With commit 4, that combination is caught bybuild-namelistinstead of at run time.create_testagainststormspeed_senh_pr4(run on558c3545)ERP_Ln9.ne3pg2_ne3pg2_mt232.FHISTC_LTsotheta-lse_laplace_scalingERP_Ln9.ne3pg2_ne3pg2_mt232.FHISTC_LTsotheta-l_kokkosPET_Ln9_P24x2.ne3pg2_ne3pg2_mt232.FHISTC_LTsotheta-lCOMPARE_base_single_thread)ERP_Ln27.ne16_g17.FKESSLERtheta-lERP_Ln27.ne16_g17.FKESSLERtheta-l_kokkosERP_Ln9.ne30_ne30_mg17.F2000climo(se dycore)New baselines generated:
stormspeed_senh_pr5.Commits 3–4 change only
bld/(namelist definition text and tensor-sponge logic). Checked withpreview_namelists: the default case's namelist is unchanged;se_laplace_scaling = 1alone givesse_nu_top = 5.0e-7;se_laplace_scaling = 1withse_nu_top = 2.5e5stops with the error.GitHub CI
PASS