sst-core
sst-core copied to clipboard
Trac: #408 Simulation runtime parameters are not available to lower level objects
At startup of simulation, main() creates a Config object that decodes the runtime parameters. A pointer to this object is passed to the SimulationBase, but is not stored. When lower level objects want access to runtime parameters, they must go through various methods (either storing a parameter in simulation or passing a ptr to the config object) to get access.
If SimulationBase stored the pointer to the config object (which never goes away in main), and provided a getConfig() method, then objects could easily retrieve the runtime parameters.
We need a concrete use case for this. Otherwise it will be a wont-fix.
The Config object has some functions that we don't really want to be part of the public API. We may be able to create a user visible Config object with public const data members that the user can get a hold of. The other option is to figure out which configuration options we want available to the elements and add functions in BaseComponent to allow access to them.