When there is a very large tunable parameter in the model, the Real-Time Workshop Embedded Coder 5.3 (R2009a) generates C++ code that has huge block parameter data taking huge memory. The Microsoft Visual C++ 2008 (MSVC++) compiler by default can not handle this huge block parameter.
To work around this issue, you can follow the hints suggested by Microsoft:
Basically, the user just needs to supply the /bigobj switch on the compilation command line. One way to achieve this is to right-click the project in Visual Studio, select Properties, and in the pop-up dialog box, select Configuration Properties -> C/C++ -> Command Line, and then add /bigobj to the end of “Additional options:” text box.While this avoids the occurring error, the compilation will last very long anyway.
Another workaround would be to use another compiler. I.e. you could compile the code on a Linux machine, which uses the GNU C++ compiler.