Here is a list of factors known to cause spikes in the task execution time:
- BIOS Power save options are enabled
- BIOS Legacy USB controllers are enabled
- Using the Simulink Real-Time Graphical interface
- System Management Interrupts (SMI)
- Cache misses when loading states into memory at the beginning of model execution
- Cache misses when background tasks move lots of data
To eliminate the spikes in the Simulink Real-Time TET log, please do the following:
- Turn the Power save option in the BIOS off
- Turn USB Controllers off
- Use text mode rather than Simulink Real-Time Graphical interface
- To ensure best performance, confirm that the custom target computer BIOS settings match those specified in the Simulink Real-Time documentation. You can find the documentation page for this by executing the following command in the MATLAB command prompt:
web(fullfile(docroot, 'xpc/gs/bios-settings.html'))
Note that real-time target machines provided by Speedgoat (exclusively supported with Simulink Real-Time since R2018a) are already configured and optimized to minimize and eliminate these BIOS effects.