How do I avoid 'compiler limit: compiler stack overflow' while building a model for rapid accelerator mode?

3 Ansichten (letzte 30 Tage)
I have a large Simulink model and I am using Rapid Accelerator mode to improvement simulation performance. The model runs fine in Accelerator mode, however, when the model builds for Rapid Accelerator mode, a compiler stack overflow error is thrown by the compiler.
ERROR: The error message indicates as follows:
'fatal error C1063: compiler limit: compiler stack overflow'

Akzeptierte Antwort

MathWorks Support Team
MathWorks Support Team am 1 Dez. 2020
Bearbeitet: MathWorks Support Team am 1 Dez. 2020

The error message is due to a limitation with the Microsoft compiler running out of stack.  For more information about the Microsoft compiler error C1063, please refer to following online documentation:

The root cause is that the code generated from a large Simulink model is too big and variables that are stored during compilation may end up using all of compiler stack. The default compiler stack size is 1 MB for a Microsoft compiler. Increasing the compiler stack size will resolve this error message. 
The following are few way to increase compiler stack size:
  1) Use EDITBIN on the "cl.exe" file to update the stack size as follows:
  • Open a command prompt as administrator mode from the following path:
Start > Microsoft Windows SDK 7.1 -> Open 'Windows SDK 7.1 Command Prompt'
  • In the command prompt, navigate to the path of the compiler used in Simulink:
>> cd C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin
  • Execute the following command to set the increase stack size:
>> editbin /STACK:10000000 cl.exe
>> cd amd64
>> editbin /STACK:10000000 cl.exe
2) Use Compiler flag - '/F <stack size>'

Weitere Antworten (0)

Kategorien

Mehr zu Multicore Processor Targets finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by