Shuffling contents of Grid3D::Update_Hydro_Grid
#352
Merged
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.
This PR shifts some of the contents of from
Grid3D::Update_Grid
intoGrid3D::Update_Hydro_Grid
.Overall, I think that this is a useful organizational change. I also need to do something like this on a local branch and it would be convenient to get this merged upstream as soon as we can since this modification seems like it could easily introduce lots of merge-conflicts.
I would recommend that the reviewer review the changes commit-by-commit:
The 1st commit literally moves everything after the Hydro-Integrator execution out of
Grid3D::Update_Grid
into the body ofGrid3D::Update_Hydro_Grid
(after the spot where it callsGrid3D::Update_Grid
). I think this should be very non-controversial.The 2nd commit renames
Grid3D::Update_Grid
toGrid3D::Execute_Hydro_Integrator
, which is a more descriptive & self-explanatory name, (I'm obviously happy to name it something else).The 3rd commit moves Slow-Cell-Averaging & timestep-calculation to after the invocation of Grackle. They were already performed after other forms of cooling/chemistry; this is now more consistent and "correct". This is the only structural change to the control flow.
Hydro
timing-region (this includes theHydro_Integrator
timing-region). This is addressed in the next commitThe 4th commit includes slow-cell-averaging & timestep-calculation back inside of the
Hydro
timing-region. The timing-regions are now consistent with the current version of dev.ifdef
regions down to 2.To summarize: commit 1 is the most important change & commit 3 makes the only change to the control-flow.
If you take issue with any of the changes, I'm happy to update the PR to just include the first commit (or first 2 commits)