Initialisation order level list not perfect

Issue #173 resolved
David Dickinson created an issue

The init system in gs2 is supposed to be able to put the code in a certain state of initialisation. It’s primarily used for changing the time step and then recalculating dependent quantities. Currently changing the time step this way will result in le_grids being reinitialised despite it not depending on the time step in any way. Similarly we end up cleaning up gs2_transforms and then re-initialising it, this includes destroying and recreating all the fft plans and associated redistribute objects.

It would be good to improve on this to avoid excessive work. It may be possible to use the module dependencies list to more fully capture the initialisation order, although this will need care as there are special levels introduced, multiple initialisation points per module etc. It would be good if we could find a way to avoid needing to manually maintain the dependencies as much as possible.

Comments (1)

  1. Log in to comment