Speed Rapid Acc. vs. Normal Mode

1 view (last 30 days)
I'm using the outputs of my Simulink model for a Genetic Algorithm. Each run I update the tunable parameters using 'paramSet' ( see this link ) to avoid rebuilding my target.
However, I noticed that the rapid accelerator is slower than my normal mode simulation, even if I don't update any parameters!. I did some speed tests on the same model without changing any parameters:
  • Normal Mode (sim = 1000 sec) : Elapsed = 2.89 sec
  • Normal Mode (sim = 10000 sec): Elapsed = 12.78 sec
  • Rapid Mode (sim = 10 sec) : Elapsed = 4.72 sec
  • Rapid Mode (sim = 100 sec) : Elapsed = 4.96 sec
  • Rapid Mode (sim = 1000 sec) : Elapsed = 5.44 sec
  • Rapid Mode (sim = 10000 sec): Elapsed = 7.55 sec
So my rapid accelerator is faster when simulation time is long but it seems that it needs some time (I guess ~4.5 sec) in each run to build/check the target. Why is this happening? I built the target beforehand so it should not rebuild it each time (which it isn't because this takes much longer than the 4.5 sec). What is Simulink doing in those first 4.5 seconds?
%%% EDIT
I already saved some time by using the 'RapidAcceleratorUpToDateCheck','off' option. Now the test are approx 1 sec faster. But still not faster than Normal Mode for short simulation times. Is this as expected?

Accepted Answer

J. van Delft
J. van Delft on 10 Sep 2015
Problem solved. I recently upgraded to gcc-5.1 but this compiler is not supported by MATLAB. Apparently this messes with the rapid accelerator. Downgraded to gcc-4.7 and all works well again.

More Answers (0)


Find more on Acceleration in Help Center and File Exchange


Community Treasure Hunt

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

Start Hunting!