Main Content

Pack Boolean data into bitfields

Description

Specify whether Boolean signals are stored as one–bit bitfields or as a Boolean data type.

Category: Optimization

Note

You cannot use this optimization when you generate code for a target that specifies an explicit structure alignment.

Settings

Default: Off

On

Stores Boolean signals into one–bit bitfields in global block I/O structures or DWork vectors. This will reduce RAM, but might cause more executable code.

Off

Stores Boolean signals as a Boolean data type in global block I/O structures or DWork vectors.

Dependencies

This parameter:

  • Requires a Embedded Coder® license.

  • Appears only for ERT-based targets.

Command-Line Information

Parameter: BooleansAsBitfields
Value: 'on' | 'off'
Default: 'off'

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyOff (execution, ROM), On (RAM)
Safety precautionNo impact

Related Topics