Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Re-use memory in fmi3SetX / fmi3GetX functions #515
Currently all requested values are copied twice for every call of fmi3GetX / fmi3SetX which is inefficient in terms of bandwidth and memory usage. This can be avoided by re-using the memory for subsequent calls of the getters and setters.
The FMU allocates the memory for all variables during
The value references are provided to allow optimizations if only a small number of variables are set / retrieved.
The FMU re-allocates the memory using the callbacks provided by the environment. The memory layout changes according to the structural parameters.
In fmi3Terminate() the FMU frees the memory using fmi3Free()