Main Content

GPU acceleration

Option to accelerate MATLAB function block on GPU by generating CUDA code

Model Configuration Pane: Simulation Target

Description

The GPU acceleration parameter speeds up the execution of MATLAB Function block on NVIDIA® GPUs by generating CUDA® code. This option requires a GPU Coder™ license.

Settings

off (default) | on
on

Enables simulation acceleration by using GPU Coder. When this option is on, the software generates CUDA MATLAB® executable (MEX) code from the block and dynamically links the generated code to Simulink® during simulation.

off

Disables simulation acceleration by using GPU Coder.

Recommended Settings

ApplicationSetting
DebuggingOn
TraceabilityNo impact
EfficiencyNo impact
Safety precautionOn

Programmatic Use

Parameter: GPUAcceleration
Type: character vector
Value: "on" | "off"
Default: "off"

Version History

Introduced in R2020b