Repository navigation
WW3 speed-up in coupled E3SM - #15
Merged
Merged
Conversation
1. Single-pass sea-point count (W3NMIN, w3wavemd.F90). The routine counted active sea points once per rank over all points, 44 million lookups per step at 447 ranks. One pass with a tally per rank gives the same counts. WW3 on the production layout: 51.5 -> 14.2 s per model day. 2. All-to-all spectral exchange (new routine W3XYA2A, w3wavemd.F90). The per-bin persistent-request gather/scatter, whose MPI_WAITALL hung three of three 47-node runs, is replaced by two MPI_ALLTOALLV calls moving the same values. Ten 47-node runs since, including a full year, with no hang. WW3_XY_ALLTOALL=0 restores the old path. 3. Suggested processor layout for 47 nodes, once 1 and 2 are in: CPL/ATM/ICE 1920@0, LND/ROF 256@1920, OCN 384@2176, WAV 448@2560. With WW3 off the critical path this gives 4.18 -> 8.61 simulated years per day (one year in 2 h 52 min). Optional; the code changes stand on their own. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016qnzCGE6PQFZXSrrFR8wEz
|
this PR has now been thoroughly tested.
|
erinethomas
approved these changes
Oct 29, 2026
sbrus89
approved these changes
Nov 20, 2026
sbrus89
left a comment
Collaborator
There was a problem hiding this comment.
Passes:
SMS_D_Ln3.TL319_EC30to60E2r2_wQU225EC30to60E2r2.GMPAS-JRA1p5-WW3.chrysalis_intel.ww3-jra_1958
SMS_D_Ln3.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL2010-WW3.chrysalis_intel
SMS_D_Ln3.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3.chrysalis_intel
PET_Ld1.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3.chrysalis_intel
ERS_Ld3.ne30pg2_IcoswISC30E3r5_wQU225Icos30E3r5.WCYCL1850-WW3.chrysalis_intel
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request Summary
This PR provides MPI updates to w3wavemd.F90 that speed up WW3 in coupled E3SM by nearly a factor of 4.
Description
This PR makes two changes to
model/src/w3wavemd.F90. Both are bit-for-bit.The active-sea-point count in
W3NMINis rewritten as a single pass. The routine looked up the owner of every sea point once per rank, every coupling step (NAPROC x NSEA lookups, 44 million per step on 447 ranks). It now makes one pass with a per-rank tally and produces the same counts.The per-bin spectral gather/scatter is replaced with an all-to-all exchange. The existing persistent-request exchange between the spatial and spectral decompositions hung three of three 47-node coupled runs, with one WAV rank stuck in
MPI_WAITALL. The new routineW3XYA2Amoves the same values with twoMPI_ALLTOALLVcalls. Ten 47-node runs since, including a full simulated year, have completed without a hang. Setting the environment variableWW3_XY_ALLTOALL=0restores the old exchange.Together with a rebalanced 47-node processor layout on the E3SM side (CPL/ATM/ICE 1920, LND/ROF 256, OCN 384, WAV 448), coupled throughput on Chrysalis went from 4.18 to 8.61 simulated years per day. The layout is an E3SM configuration setting and is not part of this PR.
WW3_explainer_slides.pdf