Main Content

Signal Storage Reuse

Optimize memory by reusing memory storage locations

Model Configuration Pane: PLC Code Generation / Optimization


The Signal storage reuse parameter reuses signal memory.


on (default) | off

Default: on


Reuses memory buffers allocated to store block input and output signals, reducing the memory requirement of your real-time program.


Allocates a separate memory buffer for each block's outputs. This allocation makes block outputs global and unique, which in many cases significantly increases RAM and ROM usage.


  • This option applies only to signals with storage class Auto.

  • Signal storage reuse can occur among only signals that have the same data type.

  • Clearing this option can substantially increase the amount of memory required to simulate large models.

  • Clear this option if you want to:

    • Debug a C-MEX S-function.

    • Use a Floating Scope or a Display block with the Floating display option selected to inspect signals in a model that you are debugging.

  • If you select Signal storage reuse and attempt to use a Floating Scope or floating Display block to display a signal whose buffer has been reused, an error dialog box opens.

Recommended Settings

DebuggingNo impact
TraceabilityNo impact
Safety precautionNo impact

Programmatic Use

Type: string
Value: 'on' | 'off'
Default: 'on'

Version History

Introduced in R2012b