When the target computer is unable to finish all the required calculations for a time step before the next time step started, a CPU overload occurs. If you see the message "Overload limit (x) exceeded," this indicates that the number of missed deadlines has surpassed the maximum allowed by your model's configuration. If your model contains no SLRT Overload Options block, then no overloads are allowed. See the following documentation for details:
To resolve this issue, consider one of the following solutions:
1. Try to Compile with GCC -ffast-math
Turn on Compile with GCC -ffast-math. The code will run faster, but this could come at the cost of accuracy. The documentation page explains more about that. I’d recommend verifying your results if you use this option. 2. Allow overloads during initialization or for debugging
Add an 'SLRT Overload Options' block to your model to allow a small number of overloads to occur via the 'Max Overloads' parameter. This is good for uses where the given application needs a longer initialization time, and is tolerant and won't lose a significant amount of data. However, allowing overloads can cause incorrect results. See SLRT Overload Options. 3. Use Execution Profiling to identify bottlenecks
4. Concurrent execution with Explicit Partitioning
5. Remove incompatible blocks
Make sure your model does not contain incompatible blocks that aren't recommended for production code generation, such as To File blocks. 6. Overloads when loading parameter sets
7. Increase model step size
Increase the model step size until the model is able to simulate on the target machine. Note that different Speedgoat machines have different CPUs, so a step size that works on one target machine might not always be able to run on another one. If you have multiple rates in your model, consider increasing the step size for each rate. Use the Timing Legend to visualize the rates in your model. 8. Turn off execution time measurement when not profiling
Finally, if you are no longer profiling the real-time execution of your model, configure 'Measure function execution times' to be 'Off' under Code Generation > Verification in the model configuration parameters. This reduces overhead and improves performance.