Limitations for Coverage in Accelerator Mode
R2026bYou can collect coverage for models in accelerator mode, but some coverage metrics, blocks, and model configurations have limitations. These limitations can cause differences between coverage results collected in normal and accelerator modes.
Unsupported Coverage Metrics
These coverage metrics are not supported in accelerator mode.
Relational boundary coverage
Saturation on integer overflow coverage
Lookup table coverage
Signal size coverage
Signal range coverage
Simulink® Design Verifier™ objectives and constraints coverage
The coverage report does not include unsupported metrics.
Modeling and Model Configuration Limitations
Collecting coverage for models in accelerator mode has some limitations related to specific actions or model configurations.
Model Reference Hierarchies That Use Both Normal and Accelerator Modes
Simulink Coverage™ only collects coverage if all models in the model reference hierarchy, including the top model, use accelerator mode. If the top model simulates in normal mode, Simulink Coverage only collects coverage for normal-mode model references.
Aggregating Coverage from Normal and Accelerator Simulations
You cannot aggregate coverage data from a normal-mode simulation and an accelerator-mode simulation of the same model. Attempting to combine these coverage results produces a checksum mismatch error.
Custom Code Coverage in Model References with Parallel Build
If you enable custom code coverage for model references in a model hierarchy, and enable parallel build, the build process uses serial build and issues a warning message. To use parallel build, disable custom code coverage for the model references that have custom code enabled.
Building Model Reference Simulation Target with slbuild
If you call the slbuild function with the
buildSpec argument set to ModelReferenceSimTarget,
the slbuild function ignores coverage settings, and the built
executable does not generate coverage results.
Inactive Choices of Variant Blocks
When you analyze coverage for variant blocks in accelerator mode, Simulink
Coverage reports coverage for choices of startup and Stateflow® variants. The Exclude inactive
choices of variants model configuration parameter and excludeInactiveVariants property of cvdata objects are not
supported in accelerator mode. If you attempt to set the
excludeInactiveVariants property to a nonzero value on a
cvdata object associated with accelerator mode coverage results, you
receive a warning message. To exclude inactive choices of variants, use normal simulation
mode or create exclusion filters for the inactive variant choices.
Block-Specific Limitations
Some blocks have limitations when collecting coverage in accelerator mode.
Multiport Switch Block
If a Multiport Switch block has a single data input port, and the signal is a scalar, the block does not receive coverage in accelerator mode. When you simulate in accelerator mode, the compiler removes this block during model optimization because the output is always the same as the scalar input signal, regardless of the signal from the control signal port. These blocks appear in the Blocks Eliminated from Coverage Analysis section of the coverage report.
Relay Block with Frame-Based Input
The Relay block does not receive coverage in accelerator mode if the
Input processing block parameter is Columns as
channels (frame based). These blocks appear in the Blocks
Eliminated from Coverage Analysis section of the coverage report. To collect
coverage, set the Input processing block parameter to
Elements as channels (sample based).
Relational Operator Block with isInf,
isNaN, or isFinite
The Relational Operator block does not receive coverage in accelerator
mode if the Relational operator block parameter is
isInf, isNaN, or
isFinite.
Logical Operator and MinMax Blocks with Variable-Size Signals
A Logical Operator or MinMax block that has a single input port driven by a variable-size signal does not report coverage in accelerator mode. These blocks appear in the Blocks Eliminated from Coverage Analysis section of the coverage report.
Message Triggered Subsystem Blocks
Message-triggered subsystems do not report decision coverage in accelerator mode.
Constant Block
Constant blocks do not report block execution coverage in accelerator mode.
Multi-rate Blocks
Multi-rate blocks might show different coverage results in accelerator mode simulations than in normal mode simulations. Multi-rate blocks are blocks that can have multiple input and/or output signals that have different sample times. Example of multi-rate blocks include Rate Transition block, Upsample and Downsample blocks, and Buffer block.
Model Blocks
Model blocks do not receive execution coverage when the model block is empty or when the model block is in the top model and contains an algebraic loop.
Disabled Assertion Blocks
In accelerator mode, Simulink Coverage analyzes structural coverage for blocks connected to disabled Assertion blocks. In normal mode, Simulink Coverage excludes those blocks from coverage analysis. This can result in a difference in the number of coverage objectives between accelerator mode and normal mode simulations.
S-Function Coverage
S-functions that you inline by using Target Language Compiler (TLC) files do not receive coverage in accelerator mode.
To collect coverage for code that is implemented using TLC-inlined S-functions, consider
converting the S-function to use custom code or using slcovmex to compile a MEX-based S-function.
Coverage Differences Due to Code Optimizations
When you simulate a model in accelerator mode, the code generator can apply optimizations that remove or simplify blocks. These optimizations can cause differences between the coverage results collected in normal mode and accelerator mode.
Coverage results might not be numerically identical between normal and accelerator modes. If the code generator removes a block as part of optimization, the block appears in the coverage report as an optimized-out block instead of an uncovered objective.
Simulink Design Verifier
If you use Simulink Design Verifier to analyze a model in accelerator mode, the analysis uses normal mode instead. This change can result in Simulink Design Verifier generating results for coverage metrics that are not supported in accelerator mode, such as relational boundary coverage.