The dependency graph is traversed every timestep, which may be suboptimal given Julia's dispatcher is called, and some recursive calls to run! functions are made.
It is possible unrolling the whole dependency graph into its independent subgraphs, enabling direct traversal and calling only the models' run! functions could lead to performance improvements, both in terms of compilation optimisations and less complex runtime function calls.
It might be worth consulting with Julia experts on this topic.
This unrolling could possibly be useful to modelers and users, as well.
The dependency graph is traversed every timestep, which may be suboptimal given Julia's dispatcher is called, and some recursive calls to run! functions are made.
It is possible unrolling the whole dependency graph into its independent subgraphs, enabling direct traversal and calling only the models' run! functions could lead to performance improvements, both in terms of compilation optimisations and less complex runtime function calls.
It might be worth consulting with Julia experts on this topic.
This unrolling could possibly be useful to modelers and users, as well.