Why model compilation takes more time for first compilation than subsequent?

4 Ansichten (letzte 30 Tage)
I tried compiling different models concecutively and observed that second compilation takes more time than first. I would like to know why it is happening. I observed that for some models 'slprj' folder is created and if I delete it simulation takes longer time but all models are not generating 'slprj' folder.

Antworten (1)

Jesús Zambrano
Jesús Zambrano am 7 Feb. 2020
Hi Jithu,
The slprj folder contains information about workspace variables and build artifacts. If your Simulink model includes model references in accelerated mode, Simulink first builds the compiler version of that model. This only happens once, unless you change the model. When referencing models in accelerated mode, only the compared version of the model is loaded, which reduces the memory used and it can also potentially increase the simulation speed.
Best,
Jesús

Kategorien

Mehr zu Create Large-Scale Model Components finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by