Castro icon indicating copy to clipboard operation
Castro copied to clipboard

implement reference counting system for eos state

Open zingale opened this issue 5 years ago • 2 comments

We should use a reference count-like system to keep track of the EOS state. Anytime an operation does something that we believe breaks thermodynamic consistency, we increment the counter. If the counter > 0, then we know not to trust the state, and instead need to call clean_state.

This will let us be more consistent with the EOS calls.

zingale avatar Sep 27 '18 19:09 zingale

This would address #392. Also, I suppose it doesn't need to be a counter, it can just be a bool (either consistent or inconsistent).

maxpkatz avatar Sep 27 '18 19:09 maxpkatz

one way to do this is to attach meta data to the MFs, using SetTag in MFInfo

https://github.com/AMReX-Codes/amrex/blob/development/Src/Base/AMReX_FabArray.H#L116-L140

zingale avatar Apr 30 '22 14:04 zingale