FluidNumerics / FluidNumerics/SELF

prescribed_bcs_enabled is dead: reads removed in #121, declaration and docs remain

Open
#179 0 comments 0 reactions 0 assignees View on GitHub
cleanup
Dominant language
Fortran
Stars
92
Forks
13
Avg merge
20h 38m
Merged PRs (30d)
7

Description

`Model%prescribed_bcs_enabled` (`src/SELF_Model.f90:107`) is read nowhere in `src/`, in any of the CPU, `gpu`, or `apu` variants.

Its three reads — one each in `SELF_DGModel1D_t`, `SELF_DGModel2D_t`, `SELF_DGModel3D_t` — were removed by 3fa444f (#121, "Add extensible boundary condition system") when the boundary-condition registry replaced hardcoded BC dispatch. The declaration was not.

It is still written in ~40 files under `examples/` and `test/`, and still documented as a working performance knob:

- `docs/Models/linear-euler-2d-model.md:231`
- `docs/Models/linear-euler-3d-model.md:219`

Both say setting it `.false.` "can improve the time-to-solution for your simulation by avoiding unnecessary host-device memory movement." It has no effect.

Downstream cost: a user writing a prescribed BC against the registry finds a flag named for exactly that feature, defaulting `.true.`, documented as live, and reasonably concludes it gates their BC.

Suggested: remove the declaration and the `examples/`/`test/` assignments, and drop the two doc paragraphs. If it is instead meant to come back as a registry-aware optimisation, a comment on the declaration saying so would be enough.

Contributor guide

Open the contributing guide

Research direction

Start at the declaration in src/SELF_Model.f90:107, then search the examples/ and test/ trees for assignments to prescribed_bcs_enabled. Remove the dead declaration and assignments, and remove the two documented performance-knob paragraphs in docs/Models/linear-euler-2d-model.md:231 and docs/Models/linear-euler-3d-model.md:219. Done means no remaining declaration, assignments, or claims that the flag is active.

Written by the indexing model from the issue text.

Assessment

Tech stack
fortran
Domain
documentation, hpc, performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.