Main Content

Improving Compilation Performance

Workflows, techniques, and examples of speeding up compilation of large models

Optimization techniques for speeding up compilation of large models include scalable compilation, incremental compilation, and memory caching for model compilation artifacts.

Scalable compilation helps reduce compilation time for models that consist of a pattern of repeated components, such as transmission lines or battery packs, by compiling a repeated component once and then reusing these compilation artifacts for other instances of the same component. Scalable compilation improves compilation performance, it does not reduce the simulation time of the model.

Incremental compilation reuses compilation artifacts of reusable components for subsequent compilations within the same MATLAB® session, unless the component has been modified between simulation runs. Incremental compilation and memory caching result in improved performance for repeated model simulations and block diagram updates.

Memory caching is performed automatically. To take advantage of scalable and incremental compilation, you need to designate reusable components and enable component reuse.


Component Reuse

Scalable Compilation