https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112828
--- Comment #2 from Rich Townsend <townsend at astro dot wisc.edu> --- The problem manifests with gfortran 13.1.0 on Linux/x86_64. I've run into similar looking problems on MacOS/Arm, but the MWE I provided seems to work OK on Arm.