muBLAS API Reference
This document describes the muBLAS APIs supported in MUSA SDK 5.2. It starts with the muBLAS programming model, then documents the supported APIs in the order readers typically use them.
1. Introduction
1.1 What Is muBLAS
muBLAS is the MUSA Basic Linear Algebra Subprograms library. It provides GPU-accelerated helper routines, Level 1, Level 2, and Level 3 BLAS operations, and a small set of BLAS-like extension APIs for MTGPU devices.
1.2 Document Scope in MUSA SDK 5.2
This reference describes the muBLAS APIs supported in MUSA SDK 5.2. Use it as the compatibility reference for the functions, types, and status values documented here.
Note: Some muBLAS declarations may appear in
mublas_auxiliary.hormublas_functions.hbut are not described in this reference. These declarations are experimental in MUSA SDK 5.2 and are provided for reference only.
1.3 Supported API Families
| API family | Representative APIs |
|---|---|
| Helper and context management | mublasCreate, mublasSetStream, mublasSetPointerMode |
| Level 1 BLAS | mublasSaxpy, mublasSnrm2, mublasSscal |
| Level 2 BLAS | mublasSgemv, mublasStrsv, mublasChemv |
| Level 3 BLAS | mublasSgemm, mublasStrsm, mublasCherk |
| BLAS-like extensions | mublasSgemmEx, mublasGemmEx, mublasGemmGroupedBatchedEx |
1.4 How to Use This Document
Start with Chapter 2 for the usage model and configuration concepts. Use Chapter 3 to check status values, datatypes, function signatures, parameter lists, return values, or supported API entries.
2. Using the muBLAS API
2.1 Error Status
The supported muBLAS APIs return mublasStatus. Check the return value after each library call, especially for handle creation, stream setup, data movement helpers, and Level 2 or Level 3 compute calls that depend on size, layout, and pointer parameters. For status values, see 3.1 Return Value mublasStatus.
2.2 muBLAS Context
Most supported muBLAS routines take a mublasHandle_t. Create the handle with mublasCreate, configure it as needed, reuse it across related calls, and release it with mublasDestroy when the context is no longer needed.
Use the helper APIs to query or configure handle state before dispatching compute work. MUSA SDK 5.2 includes helper APIs for version and property queries, stream association, pointer mode, atomics mode, math mode, emulation controls, and logging configuration.
2.3 Scalar Parameters
Many BLAS routines use scalar parameters such as alpha and beta. Some helper APIs also return scalar results, such as version, property, or index values. Pointer location is part of the programming model, so use mublasSetPointerMode and mublasGetPointerMode when you need explicit control over scalar parameters or scalar results.
2.4 Parallelism with Streams
Use mublasSetStream to associate a handle with a MUstream, and use mublasGetStream to query the current association. Asynchronous transfer helpers, such as mublasSetVectorAsync, mublasGetVectorAsync, mublasSetMatrixAsync, and mublasGetMatrixAsync, queue transfers on the supplied stream.
When you overlap data movement and compute, keep stream ownership clear and reuse handles consistently with the intended execution stream.
2.5 Batching Kernels
MUSA SDK 5.2 supports batched, strided-batched, and grouped-batched entry points in several BLAS families. These routines extend the single-operation model to repeated operations that share an API family but differ in memory layout, pointer organization, or grouping.
Use pointer-array batched interfaces when each operand instance is addressed independently. Use strided-batched interfaces when instances are stored at regular intervals in memory. Use grouped-batched interfaces when a single call must cover multiple operation groups with separate shape arrays.
2.6 Math, Atomics, and Emulation Controls
MUSA SDK 5.2 includes helper APIs such as mublasSetMathMode, mublasGetMathMode, mublasSetAtomicsMode, mublasGetAtomicsMode, and the documented emulation-control APIs. These routines configure library behavior instead of performing linear algebra directly, so call them before dependent compute work.
Logging and emulation support controls are configuration APIs. Use them only for corresponding supported 5.2 reference entries included in this document.
3. API Reference
This chapter describes muBLAS status values, datatypes, and library functions. Function entries include signatures, parameters, return values, and descriptions derived from public header comments. APIs that may appear in the public headers but are not documented here should be treated as experimental and for reference only in this release.
3.1 Return Value mublasStatus
Most supported muBLAS APIs return mublasStatus. A return value of MUBLAS_STATUS_SUCCESS indicates that the call completed successfully. Any other value indicates that the call did not complete as requested.
The following table lists the status values used by muBLAS.
| Status value | Meaning |
|---|---|
MUBLAS_STATUS_SUCCESS | The operation completed successfully. |
MUBLAS_STATUS_INVALID_HANDLE | The handle is not initialized, invalid, or null. |
MUBLAS_STATUS_NOT_IMPLEMENTED | The requested function is not implemented. |
MUBLAS_STATUS_INVALID_POINTER | A pointer argument is invalid. |
MUBLAS_STATUS_INVALID_SIZE | A size, dimension, leading dimension, increment, or batch-count argument is invalid. |
MUBLAS_STATUS_MEMORY_ERROR | An internal memory allocation, copy, or deallocation failed. |
MUBLAS_STATUS_INTERNAL_ERROR | The library encountered an internal failure. |
MUBLAS_STATUS_PERF_DEGRADED | The operation completed with degraded performance, typically because available device memory was low. |
MUBLAS_STATUS_SIZE_QUERY_MISMATCH | A device-memory size query start or stop operation is not matched with the expected query state. |
MUBLAS_STATUS_SIZE_INCREASED | The queried device-memory size increased. |
MUBLAS_STATUS_SIZE_UNCHANGED | The queried device-memory size did not change. |
MUBLAS_STATUS_INVALID_VALUE | An argument value is not valid for the requested operation. |
MUBLAS_STATUS_CONTINUE | No status condition prevents the function from proceeding. |
MUBLAS_STATUS_CHECK_NUMERICS_FAIL | A vector or matrix numerics check detected a NaN or infinity. |
3.2 muBLAS Datatypes Reference
This section summarizes the muBLAS-specific types that appear in the supported MUSA SDK 5.2 API signatures.
| Type | Purpose |
|---|---|
mublasHandle_t | Library context handle passed to most supported muBLAS routines. |
mublasStatus | Return type used by the supported muBLAS APIs. |
mublasOperation_t | Operation selector used by Level 2, Level 3, and extension routines to control transpose behavior. |
mublasFillMode_t | Storage selector used by symmetric, Hermitian, triangular, and packed-matrix routines. |
mublasDiagType_t | Diagonal-mode selector used by triangular routines. |
mublasSideMode_t | Side selector used by routines where the matrix operand appears on the left or right. |
mublasPointerMode_t | Pointer-location selector used for scalar parameters and scalar result handling. |
mublasAtomicsMode_t | Atomics-mode selector used by atomics configuration helpers. |
mublasMath_t | Math-mode selector used by math configuration helpers. |
mublasComputeType_t | Compute-precision selector used by extension GEMM APIs. |
mublasGemmAlgo_t | Algorithm selector used by extension GEMM APIs. |
mublasEmulationStrategy_t | Emulation-strategy selector used by emulation configuration helpers. |
mublasLogCallback | Callback-function type used by logging helper APIs. |
3.3 MUSA Datatypes Reference
This section summarizes the non-muBLAS public types that appear directly in the supported MUSA SDK 5.2 API signatures.
| Type | Purpose |
|---|---|
MUstream | Stream handle used by stream-association helpers and asynchronous vector or matrix transfer helpers. |
libraryPropertyType_t | Property selector used by mublasGetProperty. |
musaDataType_t | Storage-type selector used by extension GEMM APIs. |
musaEmulationSpecialValuesSupport | Mask type used by emulation special-values helpers. |
musaEmulationMantissaControl | Control type used by mantissa-configuration helpers. |
muComplex | Single-precision complex scalar type used by complex BLAS routines. |
muDoubleComplex | Double-precision complex scalar type used by complex BLAS routines. |
3.4 muBLAS Helper Function Reference
This section covers helper and context-management APIs for handle lifecycle, stream association, host-device data movement, math and atomics modes, emulation controls, and logging configuration.
mublasCreate
mublasStatus mublasCreate(mublasHandle_t *handle)
Description
- Creates a muBLAS handle.
Parameters
handle(mublasHandle_t *)
Returns
mublasDestroy
mublasStatus mublasDestroy(mublasHandle_t handle)
Description
- Destroys a muBLAS handle.
Parameters
handle(mublasHandle_t)
Returns
mublasGetVersion
mublasStatus mublasGetVersion(mublasHandle_t handle, int *version)
Description
- Gets the muBLAS version.
Parameters
handle(mublasHandle_t)version(int *)
Returns
mublasGetProperty
mublasStatus mublasGetProperty(libraryPropertyType_t type, int *value)
Description
- Gets the value of the requested property.
Parameters
type(libraryPropertyType_t)value(int *)
Returns
mublasSetStream
mublasStatus mublasSetStream(mublasHandle_t handle, MUstream stream)
Description
- Sets the stream for the handle.
Parameters
handle(mublasHandle_t)stream(MUstream)
Returns
mublasGetPointerMode
mublasStatus mublasGetPointerMode(mublasHandle_t handle, mublasPointerMode_t *pointer_mode)
Description
- Gets the pointer mode.
Parameters
handle(mublasHandle_t)pointer_mode(mublasPointerMode_t *)
Returns
mublasSetPointerMode
mublasStatus mublasSetPointerMode(mublasHandle_t handle, mublasPointerMode_t pointer_mode)
Description
- Sets the pointer mode.
Parameters
handle(mublasHandle_t)pointer_mode(mublasPointerMode_t)
Returns
mublasSetVector
mublasStatus mublasSetVector(int n, int elem_size, const void *x, int incx, void *y, int incy)
Description
- Copies a vector from host memory to device memory.
Parameters
n(int): number of elements in the vectorelem_size(int): number of bytes per elementx(const void *): host pointer to the vectorincx(int): specifies the increment for elements of the vectory(void *): device pointer to the vectorincy(int): specifies the increment for elements of the vector
Returns
mublasGetVector
mublasStatus mublasGetVector(int n, int elem_size, const void *x, int incx, void *y, int incy)
Description
- Copies a vector from device memory to host memory.
Parameters
n(int): number of elements in the vectorelem_size(int): number of bytes per elementx(const void *): device pointer to the vectorincx(int): specifies the increment for elements of the vectory(void *): host pointer to the vectorincy(int): specifies the increment for elements of the vector
Returns
mublasSetMatrix
mublasStatus mublasSetMatrix(int rows, int cols, int elem_size, const void *a, int lda, void *b, int ldb)
Description
- Copies a matrix from host memory to device memory.
Parameters
rows(int): number of rows in matricescols(int): number of columns in matriceselem_size(int): number of bytes per elementa(const void *): host pointer to the matrixlda(int): specifies the leading dimension of A, lda >= rowsb(void *): device pointer to the matrixldb(int): specifies the leading dimension of B, ldb >= rows
Returns
mublasGetMatrix
mublasStatus mublasGetMatrix(int rows, int cols, int elem_size, const void *a, int lda, void *b, int ldb)
Description
- Copies a matrix from device memory to host memory.
Parameters
rows(int): number of rows in matricescols(int): number of columns in matriceselem_size(int): number of bytes per elementa(const void *): device pointer to the matrixlda(int): specifies the leading dimension of A, lda >= rowsb(void *): host pointer to the matrixldb(int): specifies the leading dimension of B, ldb >= rows
Returns
mublasSetVectorAsync
mublasStatus mublasSetVectorAsync(int n, int elem_size, const void *x, int incx, void *y, int incy, MUstream stream)
Description
- Copies a vector asynchronously from host memory to device memory.
Parameters
n(int): number of elements in the vectorelem_size(int): number of bytes per elementx(const void *): host pointer to the vectorincx(int): specifies the increment for elements of the vectory(void *): device pointer to the vectorincy(int): specifies the increment for elements of the vectorstream(MUstream): specifies the stream where the transfer is queued
Returns
mublasGetVectorAsync
mublasStatus mublasGetVectorAsync(int n, int elem_size, const void *x, int incx, void *y, int incy, MUstream stream)
Description
- Copies a vector asynchronously from device memory to host memory.
Parameters
n(int): number of elements in the vectorelem_size(int): number of bytes per elementx(const void *): device pointer to the vectorincx(int): specifies the increment for elements of the vectory(void *): host pointer to the vectorincy(int): specifies the increment for elements of the vectorstream(MUstream): specifies the stream where the transfer is queued
Returns
mublasSetMatrixAsync
mublasStatus mublasSetMatrixAsync(int rows, int cols, int elem_size, const void *a, int lda, void *b, int ldb, MUstream stream)
Description
- Copies a matrix asynchronously from host memory to device memory.
Parameters
rows(int): number of rows in matricescols(int): number of columns in matriceselem_size(int): number of bytes per elementa(const void *): host pointer to the matrixlda(int): specifies the leading dimension of A, lda >= rowsb(void *): device pointer to the matrixldb(int): specifies the leading dimension of B, ldb >= rowsstream(MUstream): specifies the stream where the transfer is queued
Returns
mublasGetMatrixAsync
mublasStatus mublasGetMatrixAsync(int rows, int cols, int elem_size, const void *a, int lda, void *b, int ldb, MUstream stream)
Description
- Copies a matrix asynchronously from device memory to host memory.
Parameters
rows(int): number of rows in matricescols(int): number of columns in matriceselem_size(int): number of bytes per elementa(const void *): device pointer to the matrixlda(int): specifies the leading dimension of A, lda >= rowsb(void *): host pointer to the matrixldb(int): specifies the leading dimension of B, ldb >= rowsstream(MUstream): specifies the stream where the transfer is queued
Returns
mublasSetAtomicsMode
mublasStatus mublasSetAtomicsMode(mublasHandle_t handle, mublasAtomicsMode_t atomics_mode)
Description
- Sets the atomics mode.
Parameters
handle(mublasHandle_t)atomics_mode(mublasAtomicsMode_t)
Returns
mublasGetAtomicsMode
mublasStatus mublasGetAtomicsMode(mublasHandle_t handle, mublasAtomicsMode_t *atomics_mode)
Description
- Gets the atomics mode.
Parameters
handle(mublasHandle_t)atomics_mode(mublasAtomicsMode_t *)
Returns
mublasSetMathMode
mublasStatus mublasSetMathMode(mublasHandle_t handle, mublasMath_t math_mode)
Description
- Sets the math mode.
Parameters
handle(mublasHandle_t)math_mode(mublasMath_t)
Returns
mublasGetMathMode
mublasStatus mublasGetMathMode(mublasHandle_t handle, mublasMath_t *math_mode)
Description
- Gets the math mode.
Parameters
handle(mublasHandle_t)math_mode(mublasMath_t *)
Returns
mublasSetEmulationStrategy
mublasStatus mublasSetEmulationStrategy(mublasHandle_t handle, mublasEmulationStrategy_t emulationStrategy)
Parameters
handle(mublasHandle_t)emulationStrategy(mublasEmulationStrategy_t)
Returns
mublasGetEmulationStrategy
mublasStatus mublasGetEmulationStrategy(mublasHandle_t handle, mublasEmulationStrategy_t *emulationStrategy)
Parameters
handle(mublasHandle_t)emulationStrategy(mublasEmulationStrategy_t *)
Returns
mublasGetEmulationSpecialValuesSupport
mublasStatus mublasGetEmulationSpecialValuesSupport(mublasHandle_t handle, musaEmulationSpecialValuesSupport *mask)
Parameters
handle(mublasHandle_t)mask(musaEmulationSpecialValuesSupport *)
Returns
mublasSetEmulationSpecialValuesSupport
mublasStatus mublasSetEmulationSpecialValuesSupport(mublasHandle_t handle, musaEmulationSpecialValuesSupport mask)
Parameters
handle(mublasHandle_t)mask(musaEmulationSpecialValuesSupport)
Returns
mublasGetFixedPointEmulationMantissaBitCountPointer
mublasStatus mublasGetFixedPointEmulationMantissaBitCountPointer(mublasHandle_t handle, int **mantissaBitCount)
Parameters
handle(mublasHandle_t)mantissaBitCount(int **)
Returns
mublasSetFixedPointEmulationMantissaBitCountPointer
mublasStatus mublasSetFixedPointEmulationMantissaBitCountPointer(mublasHandle_t handle, int *mantissaBitCount)
Parameters
handle(mublasHandle_t)mantissaBitCount(int *)
Returns
mublasGetFixedPointEmulationMantissaControl
mublasStatus mublasGetFixedPointEmulationMantissaControl(mublasHandle_t handle, musaEmulationMantissaControl *mantissaControl)
Parameters
handle(mublasHandle_t)mantissaControl(musaEmulationMantissaControl *)
Returns
mublasSetFixedPointEmulationMantissaControl
mublasStatus mublasSetFixedPointEmulationMantissaControl(mublasHandle_t handle, musaEmulationMantissaControl mantissaControl)
Parameters
handle(mublasHandle_t)mantissaControl(musaEmulationMantissaControl)
Returns
mublasSetFixedPointEmulationMaxMantissaBitCount
mublasStatus mublasSetFixedPointEmulationMaxMantissaBitCount(mublasHandle_t handle, int maxMantissaBitCount)
Parameters
handle(mublasHandle_t)maxMantissaBitCount(int)
Returns
mublasGetFixedPointEmulationMaxMantissaBitCount
mublasStatus mublasGetFixedPointEmulationMaxMantissaBitCount(mublasHandle_t handle, int *maxMantissaBitCount)
Parameters
handle(mublasHandle_t)maxMantissaBitCount(int *)
Returns
mublasSetFixedPointEmulationMantissaBitOffset
mublasStatus mublasSetFixedPointEmulationMantissaBitOffset(mublasHandle_t handle, int mantissaBitOffset)
Parameters
handle(mublasHandle_t)mantissaBitOffset(int)
Returns
mublasGetFixedPointEmulationMantissaBitOffset
mublasStatus mublasGetFixedPointEmulationMantissaBitOffset(mublasHandle_t handle, int *mantissaBitOffset)
Parameters
handle(mublasHandle_t)mantissaBitOffset(int *)
Returns
mublasLoggerConfigure
mublasStatus mublasLoggerConfigure(int logIsOn, int logToStdOut, int logToStdErr, const char *logFileName)
Description
- Configures runtime logging.
Parameters
logIsOn(int)logToStdOut(int)logToStdErr(int)logFileName(const char *)
Returns
mublasGetLoggerCallback
mublasStatus mublasGetLoggerCallback(mublasLogCallback *userCallback)
Description
- Retrieves the function pointer for the custom user-defined callback previously installed with
mublasSetLoggerCallback, or zero if no callback is installed.
Parameters
userCallback(mublasLogCallback *): Pointer to a user-defined callback function.
Returns
mublasSetLoggerCallback
mublasStatus mublasSetLoggerCallback(mublasLogCallback userCallback)
Description
- Installs a custom user-defined callback function through the muBLAS C API.
Parameters
userCallback(mublasLogCallback): Pointer to a user-defined callback function.
Returns
3.5 muBLAS Level-1 Function Reference
This section covers the supported Level 1 BLAS vector operations in MUSA SDK 5.2, including index, norm, scale, swap, copy, dot, and rotation routines.
mublasIsamax
mublasStatus mublasIsamax(mublasHandle_t handle, int n, const float *x, int incx, int *result)
Description
- BLAS Level 1 API.
- Finds the first index of the element with the maximum magnitude in vector x.
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector.result(int *): device or host pointer to store the amax index. Returns 0 ifn <= 0orincx <= 0.
Returns
mublasIdamax
mublasStatus mublasIdamax(mublasHandle_t handle, int n, const double *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const double *)incx(int)result(int *)
Returns
mublasIcamax
mublasStatus mublasIcamax(mublasHandle_t handle, int n, const muComplex *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const muComplex *)incx(int)result(int *)
Returns
mublasIzamax
mublasStatus mublasIzamax(mublasHandle_t handle, int n, const muDoubleComplex *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const muDoubleComplex *)incx(int)result(int *)
Returns
mublasIsamin
mublasStatus mublasIsamin(mublasHandle_t handle, int n, const float *x, int incx, int *result)
Description
- BLAS Level 1 API.
- Finds the first index of the element with the minimum magnitude in vector x.
- vector
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector.result(int *): device or host pointer to store the amin index. Returns 0 ifn <= 0orincx <= 0.
Returns
mublasIdamin
mublasStatus mublasIdamin(mublasHandle_t handle, int n, const double *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const double *)incx(int)result(int *)
Returns
mublasIcamin
mublasStatus mublasIcamin(mublasHandle_t handle, int n, const muComplex *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const muComplex *)incx(int)result(int *)
Returns
mublasIzamin
mublasStatus mublasIzamin(mublasHandle_t handle, int n, const muDoubleComplex *x, int incx, int *result)
Parameters
handle(mublasHandle_t)n(int)x(const muDoubleComplex *)incx(int)result(int *)
Returns
mublasSasum
mublasStatus mublasSasum(mublasHandle_t handle, int n, const float *x, int incx, float *result)
Description
- BLAS Level 1 API.
- Computes the sum of element magnitudes for a real vector x, or the sum of real and imaginary component magnitudes for a complex vector x.
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x and y.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector. incx must be > 0.result(float *): device or host pointer to store the asum product. Returns 0 ifn <= 0.
Returns
mublasDasum
mublasStatus mublasDasum(mublasHandle_t handle, int n, const double *x, int incx, double *result)
Parameters
handle(mublasHandle_t)n(int)x(const double *)incx(int)result(double *)
Returns
mublasScasum
mublasStatus mublasScasum(mublasHandle_t handle, int n, const muComplex *x, int incx, float *result)
Parameters
handle(mublasHandle_t)n(int)x(const muComplex *)incx(int)result(float *)
Returns
mublasDzasum
mublasStatus mublasDzasum(mublasHandle_t handle, int n, const muDoubleComplex *x, int incx, double *result)
Parameters
handle(mublasHandle_t)n(int)x(const muDoubleComplex *)incx(int)result(double *)
Returns
mublasSaxpy
mublasStatus mublasSaxpy(mublasHandle_t handle, int n, const float *alpha, const float *x, int incx, float *y, int incy)
Description
- BLAS Level 1 API.
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x and y.alpha(const float *): device or host pointer to specify the scalar alpha.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector.y(float *): device pointer to vector y.incy(int): specifies the increment for elements of the vector.
Returns
mublasDaxpy
mublasStatus mublasDaxpy(mublasHandle_t handle, int n, const double *alpha, const double *x, int incx, double *y, int incy)
Parameters
handle(mublasHandle_t)n(int)alpha(const double *)x(const double *)incx(int)y(double *)incy(int)
Returns
mublasCaxpy
mublasStatus mublasCaxpy(mublasHandle_t handle, int n, const muComplex *alpha, const muComplex *x, int incx, muComplex *y, int incy)
Parameters
handle(mublasHandle_t)n(int)alpha(const muComplex *)x(const muComplex *)incx(int)y(muComplex *)incy(int)
Returns
mublasZaxpy
mublasStatus mublasZaxpy(mublasHandle_t handle, int n, const muDoubleComplex *alpha, const muDoubleComplex *x, int incx, muDoubleComplex *y, int incy)
Parameters
handle(mublasHandle_t)n(int)alpha(const muDoubleComplex *)x(const muDoubleComplex *)incx(int)y(muDoubleComplex *)incy(int)
Returns
mublasScopy
mublasStatus mublasScopy(mublasHandle_t handle, int n, const float *x, int incx, float *y, int incy)
Description
- BLAS Level 1 API.
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x to be copied to y.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector.y(float *): device pointer to vector y.incy(int): specifies the increment for elements of the vector.
Returns
mublasDcopy
mublasStatus mublasDcopy(mublasHandle_t handle, int n, const double *x, int incx, double *y, int incy)
Parameters
handle(mublasHandle_t)n(int)x(const double *)incx(int)y(double *)incy(int)
Returns
mublasCcopy
mublasStatus mublasCcopy(mublasHandle_t handle, int n, const muComplex *x, int incx, muComplex *y, int incy)
Parameters
handle(mublasHandle_t)n(int)x(const muComplex *)incx(int)y(muComplex *)incy(int)
Returns
mublasZcopy
mublasStatus mublasZcopy(mublasHandle_t handle, int n, const muDoubleComplex *x, int incx, muDoubleComplex *y, int incy)
Parameters
handle(mublasHandle_t)n(int)x(const muDoubleComplex *)incx(int)y(muDoubleComplex *)incy(int)
Returns
mublasSdot
mublasStatus mublasSdot(mublasHandle_t handle, int n, const float *x, int incx, const float *y, int incy, float *result)
Description
- BLAS Level 1 API.
Parameters
handle(mublasHandle_t): handle to the muBLAS library context.n(int): the number of elements in x and y.x(const float *): device pointer to vector x.incx(int): specifies the increment for elements of the vector.y(const float *): device pointer to vector y.incy(int): specifies the increment for elements of the vector.result(float *): device or host pointer to store the dot product. Returns 0 ifn <= 0.
Returns