Main Content

Specify Generation of Reentrant Code

Specify Generation of Reentrant Code Using the MATLAB Coder App

  1. On the Generate Code page, click the Generate arrow .

  2. Set Build type to one of the following:

    • Source Code

    • Static Library (.lib)

    • Dynamic Library (.dll)

    • Executable (.exe)

  3. Click More Settings.

  4. On the Memory tab, select the Generate re-entrant code check box.

Specify Generation of Reentrant Code Using the Command-Line Interface

  1. Create a code configuration object for 'lib', 'dll', or 'exe'. For example:

    cfg = coder.config('lib'); % or dll or exe
    

  2. Set the MultiInstanceCode property to true. For example:

    cfg.MultiInstanceCode = true;
    

Related Examples

More About