Skip to content

src_compressible_stag: always consume the spatialCrossVec header block on restart - #267

Merged
isriva merged 1 commit into
AMReX-FHD:mainfrom
isriva:fix-compstag-checkpoint-header-desync
Sep 22, 2026
Merged

isriva merged 1 commit into
AMReX-FHD:mainfrom
isriva:fix-compstag-checkpoint-header-desync

Conversation

@isriva

@isriva isriva commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

WriteCheckPoint always emits the spatialCrossVec block into the header when
plot_cross is set. ReadCheckPoint skipped reading it when reset_stats == 1
but did not skip over it in the stream, so the turbulent-forcing block that
follows was parsed starting from the spatial-cross numbers.

With plot_cross = 1, reset_stats = 1, turbForcing > 1 and turbRestartRun = 1 the
first 264 accumulated correlation values were loaded as OU forcing amplitudes.
Since nothing further is read from the header the stream never resynchronised
and the failure was completely silent -- outcomes ranged from a harmless
perturbation to an immediately unstable run.

Consume the block unconditionally and discard it when resetting.

…k on restart

WriteCheckPoint always emits the spatialCrossVec block into the header when
plot_cross is set.  ReadCheckPoint skipped *reading* it when reset_stats == 1
but did not skip *over* it in the stream, so the turbulent-forcing block that
follows was parsed starting from the spatial-cross numbers.

With plot_cross = 1, reset_stats = 1, turbForcing > 1 and turbRestartRun = 1 the
first 264 accumulated correlation values were loaded as OU forcing amplitudes.
Since nothing further is read from the header the stream never resynchronised
and the failure was completely silent -- outcomes ranged from a harmless
perturbation to an immediately unstable run.

Consume the block unconditionally and discard it when resetting.
@isriva
isriva merged commit 92a9dc7 into AMReX-FHD:main Sep 22, 2026
18 checks passed
@isriva
isriva deleted the fix-compstag-checkpoint-header-desync branch September 22, 2026 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant