gpucoder.stridedMatrixMultiplyAdd
Optimized GPU implementation of strided, batched matrix multiply with add operation
Since R2020a
Syntax
Description
performs strided matrix-matrix multiplication and add of a batch of matrices. The input
matrices D
= gpucoder.stridedMatrixMultiplyAdd(A
,B
,C
)A
, B
, and C
for each
instance of the batch are located at fixed address offsets from their addresses in the
previous instance. The gpucoder.stridedMatrixMultiplyAdd
function
performs matrix-matrix multiplication of the form:
where and are scalar multiplication factors, A
,
B
, C
, and D
are matrices with
dimensions m
-by-k
,
k
-by-n
,
m
-by-n
, and
m
-by-n
respectively. A
and
B
can optionally be transposed or hermitian-conjugated. By default, and are set to one and the matrices are not transposed. To specify a different
scalar multiplication factor and perform transpose operations on the input matrices, use the
Name,Value
pair arguments.
All the batches passed to the
gpucoder.stridedMatrixMultiplyAdd
function must be uniform. That is,
all instances must have the same dimensions
m,n,k
.
___ = gpucoder.stridedMatrixMultiplyAdd(___,
performs batched matrix multiply and add operation by using the options specified by one or
more Name,Value
)Name,Value
pair arguments.
Examples
Input Arguments
Output Arguments
Version History
Introduced in R2020a
See Also
Apps
Functions
codegen
|coder.gpu.kernel
|coder.gpu.kernelfun
|gpucoder.stridedMatrixMultiply
|gpucoder.batchedMatrixMultiply
|gpucoder.batchedMatrixMultiplyAdd