Enable portable word sizes

Description

Allow portability across host and target processors that support different word sizes.

You can enable portable word sizes to support software-in-the-loop (SIL) testing of your generated code. For a SIL simulation, you use the top-model or Model block SIL simulation mode, or select SIL in the Configuration Parameters > Create block field.

Category: Code Generation > Verification

Settings

Default: off

On

Generate conditional processing macros to support compilation of generated code on a processor that supports a different word size than the target processor on which production code is run. This option allows you to use the same generated code for SIL testing on your development computer and production deployment on the target processor. For example, you can perform SIL testing on a 64-bit development computer and deploy the code on a 16-bit target processor.

Off

Does not generate portable code.

Dependencies

When you use this option, you should select Test hardware is the same as production hardware on the Hardware Implementation pane.

Command-Line Information

Parameter: PortableWordSizes
Type: character vector
Value: 'on' | 'off'
Default: 'off'

Recommended Settings

ApplicationSetting
DebuggingOn
TraceabilityOn
EfficiencyOff
Safety precautionNo impact

Related Topics