Kernel Creation from MATLAB Code - MATLAB & Simulink (original) (raw)

Main Content

MATLAB code structures and patterns that create CUDA® GPU kernels

GPU Coder™ generates and executes optimized CUDA kernels for specific algorithm structures and patterns in your MATLAB® code. The generated code calls optimized NVIDIA® CUDA libraries, including cuFFT, cuSolver, cuBLAS, cuDNN, and TensorRT. The generated code can be integrated into your project as source code, static libraries, or dynamic libraries, and can be compiled for desktops, servers, and GPUs embedded on NVIDIA Jetson, DRIVE, and other platforms. GPU Coder lets you incorporate handwritten CUDA code into your algorithms and into the generated code.

Apps

Functions

expand all

gpucoder.atomicAdd Atomically add a specified value to a variable in global or shared memory (Since R2021b)
gpucoder.atomicAnd Atomically perform bit-wise AND between a specified value and a variable in global or shared memory (Since R2021b)
gpucoder.atomicCAS Atomically compare and swap the value of a variable in global or shared memory (Since R2021b)
gpucoder.atomicDec Atomically decrement a variable in global or shared memory within a specified upper bound (Since R2021b)
gpucoder.atomicExch Atomically exchange a variable in global or shared memory with the specified value (Since R2021b)
gpucoder.atomicInc Atomically increment a variable in global or shared memory within a specified upper bound (Since R2021b)
gpucoder.atomicMax Atomically find the maximum between a specified value and a variable in global or shared memory (Since R2021b)
gpucoder.atomicMin Atomically find the minimum between a specified value and a variable in global or shared memory (Since R2021b)
gpucoder.atomicOr Atomically perform bit-wise OR between a specified value and a variable in global or shared memory (Since R2021b)
gpucoder.atomicSub Atomically subtract a specified value from a variable in global or shared memory (Since R2021b)
gpucoder.atomicXor Atomically perform bit-wise XOR between a specified value and a variable in global or shared memory (Since R2021b)

Code Configuration Settings

Topics