Real-Time Application Execution Produces CPU Overloads

A CPU overload indicates that the CPU is unable to complete processing a model time step before restarting for the next time step. When this error occurs, the target object property CPUoverload changes from none to detected. One of the following can happen:

  • The Simulink® Real-Time™ kernel halts model execution.

  • If you allow the overload, model execution continues until a predefined event occurs (see Allow CPU Overloads). If the model continues to run after a CPU overload, the time step lasts as long as the time required to finish the execution. This behavior delays the next time step.

For more information and test models, see

Your real-time application can experience real and spurious CPU overloads.

Real CPU Overloads

Model design or target computer resources cause real CPU overloads. Possible reasons are:

  • The target computer is too slow or the model sample time is too small (see Limits on Sample Time).

  • The model is too complex (algorithmic complexity).

  • The model does disk I/O on the target computer hard drive.

  • I/O latency, where each I/O channel used introduces latency into the system. I/O latency can cause the execution time to exceed the model time step.

    To find latency values for a board supported by the Simulink Real-Time block library, consult the vendor data sheet. To find a link to the vendor website, see:

    To find latency values for Speedgoat boards, contact Speedgoat technical support.

    For example, your real-time application includes the National Instruments® PCI-6713 board, which the Simulink Real-Time block library supports. Assuming that you want to use four outputs:

    1. From the vendor data sheet, the D/A latency is 1 + 2.4 × N.

    2. To get the latency for four outputs, calculate the latency:

      1 + (2.4 × 4) = 10.6 microseconds

    3. Include this value in your sample time calculations.

Spurious CPU Overloads

Properties in the BIOS commonly cause spurious CPU overloads. Such properties include:

  • Advanced Power Management

  • Plug-and-Play (PnP) operating system

  • System Management Interrupts (SMIs)

Enabling these properties can cause non-real-time behavior from the target computer. To run the application as a real-time application, disable these BIOS properties for the target computer. See BIOS Settings.

For some BIOS configurations, you cannot disable SMIs. However, for some chip sets, you can programmatically prevent or disable SMIs. For a solution to disabling SMIs in the Intel® ICH5 family, see".

Was this topic helpful?