--- layout: stdlib-reference --- # coopVecMatMulAddPacked ## Description ## Signature
/// Requires Capability Set 1:
CoopVec<T, M> coopVecMatMulAddPacked<T, int M, int PackedK, U>(
    CoopVec<U, PackedK> input,
    CoopVecComponentType inputInterpretation,
    int k,
    RWByteAddressBuffer matrix,
    int matrixOffset,
    CoopVecComponentType matrixInterpretation,
    RWByteAddressBuffer bias,
    int biasOffset,
    CoopVecComponentType biasInterpretation,
    CoopVecMatrixLayout memoryLayout,
    bool transpose,
    uint matrixStride)
    where T : __BuiltinArithmeticType
    where U : __BuiltinArithmeticType;

/// Requires Capability Set 1:
CoopVec<T, M> coopVecMatMulAddPacked<T, int M, int PackedK, U>(
    CoopVec<U, PackedK> input,
    CoopVecComponentType inputInterpretation,
    int k,
    ByteAddressBuffer matrix,
    int matrixOffset,
    CoopVecComponentType matrixInterpretation,
    ByteAddressBuffer bias,
    int biasOffset,
    CoopVecComponentType biasInterpretation,
    CoopVecMatrixLayout memoryLayout,
    bool transpose,
    uint matrixStride)
    where T : __BuiltinArithmeticType
    where U : __BuiltinArithmeticType;

/// Requires Capability Set 2:
CoopVec<T, M> coopVecMatMulAddPacked<T, int M, int PackedK, U, IgnoredBufferElementType, IgnoredBiasBufferElementType>(
    CoopVec<U, PackedK> input,
    CoopVecComponentType inputInterpretation,
    int k,
    RWStructuredBuffer<IgnoredBufferElementType, DefaultDataLayout> matrix,
    int matrixOffset,
    CoopVecComponentType matrixInterpretation,
    RWStructuredBuffer<IgnoredBiasBufferElementType, DefaultDataLayout> bias,
    int biasOffset,
    CoopVecComponentType biasInterpretation,
    CoopVecMatrixLayout memoryLayout,
    bool transpose,
    uint matrixStride)
    where T : __BuiltinArithmeticType
    where U : __BuiltinArithmeticType;

/// Requires Capability Set 2:
CoopVec<T, M> coopVecMatMulAddPacked<T, int M, int PackedK, U, IgnoredBufferElementType, IgnoredBiasBufferElementType>(
    CoopVec<U, PackedK> input,
    CoopVecComponentType inputInterpretation,
    int k,
    StructuredBuffer<IgnoredBufferElementType, DefaultDataLayout> matrix,
    int matrixOffset,
    CoopVecComponentType matrixInterpretation,
    StructuredBuffer<IgnoredBiasBufferElementType, DefaultDataLayout> bias,
    int biasOffset,
    CoopVecComponentType biasInterpretation,
    CoopVecMatrixLayout memoryLayout,
    bool transpose,
    uint matrixStride)
    where T : __BuiltinArithmeticType
    where U : __BuiltinArithmeticType;

/// Requires Capability Set 3:
CoopVec<T, M> coopVecMatMulAddPacked<T, int M, int PackedK, U>(
    CoopVec<U, PackedK> input,
    CoopVecComponentType inputInterpretation,
    int k,
    Ptr<void, Access.ReadWrite, AddressSpace.Device, DefaultDataLayout> matrixPtr,
    CoopVecComponentType matrixInterpretation,
    Ptr<void, Access.ReadWrite, AddressSpace.Device, DefaultDataLayout> biasPtr,
    CoopVecComponentType biasInterpretation,
    CoopVecMatrixLayout memoryLayout,
    bool transpose,
    uint matrixStride)
    where T : __BuiltinArithmeticType
    where U : __BuiltinArithmeticType;

## Generic Parameters #### T: [\_\_BuiltinArithmeticType](../interfaces/0_builtinarithmetictype-029j/index.html) #### M : int #### PackedK : int #### U: [\_\_BuiltinArithmeticType](../interfaces/0_builtinarithmetictype-029j/index.html) #### IgnoredBufferElementType #### IgnoredBiasBufferElementType ## Parameters #### input : [CoopVec](../types/coopvec-04/index.html)\ #### inputInterpretation : [CoopVecComponentType](../types/coopveccomponenttype-047g/index.html) #### k : int #### matrix : [RWByteAddressBuffer](../types/rwbyteaddressbuffer-0126d/index.html) #### matrixOffset : int #### matrixInterpretation : [CoopVecComponentType](../types/coopveccomponenttype-047g/index.html) #### bias : [RWByteAddressBuffer](../types/rwbyteaddressbuffer-0126d/index.html) #### biasOffset : int #### biasInterpretation : [CoopVecComponentType](../types/coopveccomponenttype-047g/index.html) #### memoryLayout : [CoopVecMatrixLayout](../types/coopvecmatrixlayout-047d/index.html) #### transpose : bool #### matrixStride : uint #### matrix : [ByteAddressBuffer](../types/byteaddressbuffer-04b/index.html) #### bias : [ByteAddressBuffer](../types/byteaddressbuffer-04b/index.html) #### matrix : [RWStructuredBuffer](../types/rwstructuredbuffer-012c/index.html)\ #### bias : [RWStructuredBuffer](../types/rwstructuredbuffer-012c/index.html)\ #### matrix : [StructuredBuffer](../types/structuredbuffer-0a/index.html)\ #### bias : [StructuredBuffer](../types/structuredbuffer-0a/index.html)\ #### matrixPtr : [Ptr](../types/ptr-0/index.html)\ #### biasPtr : [Ptr](../types/ptr-0/index.html)\ ## Availability and Requirements ### Capability Set 1 Defined for the following targets: #### hlsl Available in all stages. #### glsl Available in all stages. #### cpp Available in all stages. #### cuda Available in all stages. Requires capability: `optix_coopvec`. #### spirv Available in all stages. Requires capability: `spvCooperativeVectorNV`. ### Capability Set 2 Defined for the following targets: #### spirv Available in all stages. Requires capability: `spvCooperativeVectorNV`. #### cuda Available in all stages. Requires capability: `optix_coopvec`. ### Capability Set 3 Defined for the following targets: #### spirv Available in all stages. Requires capability: `spvCooperativeVectorNV`.