omatcopy#
Computes an out-of-place scaled matrix transpose or copy operation using a general matrix.
Description#
The omatcopy routine performs an out-of-place scaled
matrix copy or transposition.
The operation is defined as:
where:
op(
X) is one of op(X) =X, or op(X) =XT, or op(X) =XHalphais a scalarAandBare matricesAismxnmatrixBismxnmatrix ifopis non-transpose and annxmmatrix otherwise.
omatcopy supports the following precisions:
T |
|---|
|
|
|
|
omatcopy (Buffer Version)#
Syntax#
namespace oneapi::mkl::blas::column_major {
void omatcopy(sycl::queue &queue,
oneapi::mkl::transpose trans,
std::int64_t m,
std::int64_t n,
T alpha,
sycl::buffer<T, 1> &a,
std::int64_t lda,
sycl::buffer<T, 1> &b,
std::int64_t ldb);
}
namespace oneapi::mkl::blas::row_major {
void omatcopy(sycl::queue &queue,
oneapi::mkl::transpose trans,
std::int64_t m,
std::int64_t n,
T alpha,
sycl::buffer<T, 1> &a,
std::int64_t lda,
sycl::buffer<T, 1> &b,
std::int64_t ldb);
}
Input Parameters#
- queue
The queue where the routine will be executed.
- trans
Specifies op(
A), the transposition operation applied to the matrix A. See Data Types for more details.- m
Number of rows for the matrix
A. Must be at least zero.- n
Number of columns for the matrix
A. Must be at least zero.- alpha
Scaling factor for the matrix transposition or copy.
- a
Buffer holding the input matrix
A. Must have size at leastlda*nfor column-major and at leastlda*mfor row-major.- lda
Leading dimension of the matrix
A. If matrices are stored using column major layout,ldamust be at leastm. If matrices are stored using row major layout,ldamust be at leastn. Must be positive.- ldb
Leading dimension of the matrix
B. Must be positive.trans=transpose::nontranstrans=transpose::transortrans=transpose::conjtransColumn major
Must be at least
mMust be at least
nRow major
Must be at least
nMust be at least
m
Output Parameters#
- b
Output buffer, overwritten by
alpha* op(A).trans=transpose::nontranstrans=transpose::transortrans=transpose::conjtransColumn major
Bismxnmatrix. Size of arraybmust be at leastldb*nBisnxmmatrix. Size of arrayamust be at leastldb*mRow major
Bismxnmatrix. Size of arraybmust be at leastldb*mBisnxmmatrix. Size of arraybmust be at leastldb*n
omatcopy (USM Version)#
Syntax#
USM arrays:
namespace oneapi::mkl::blas::column_major {
sycl::event omatcopy(sycl::queue &queue,
oneapi::mkl::transpose trans,
std::int64_t m,
std::int64_t n,
oneapi::mkl::value_or_pointer<T> alpha,
const T *a,
std::int64_t lda,
T *b,
std::int64_t ldb,
const std::vector<sycl::event> &dependencies = {});
}
namespace oneapi::mkl::blas::row_major {
sycl::event omatcopy(sycl::queue &queue,
oneapi::mkl::transpose trans,
std::int64_t m,
std::int64_t n,
oneapi::mkl::value_or_pointer<T> alpha,
const T *a,
std::int64_t lda,
T *b,
std::int64_t ldb,
const std::vector<sycl::event> &dependencies = {});
}
Input Parameters#
- queue
The queue where the routine will be executed.
- trans
Specifies op(
A), the transposition operation applied to matrixA. See Data Types for more details.- m
Number of rows for the matrix
A. Must be at least zero.- n
Number of columns for the matrix
A. Must be at least zero.- alpha
Scaling factor for the matrix transposition or copy. See Scalar Arguments for more information on the
value_or_pointerdata type.- a
Pointer to input matrix
A. Must have size at leastlda*nfor column-major and at leastlda*mfor row-major.- lda
Leading dimension of the matrix
A. If matrices are stored using column major layout,ldamust be at leastm. If matrices are stored using row major layout,ldamust be at leastn. Must be positive.- ldb
Leading dimension of the matrix
B. Must be positive.trans=transpose::nontranstrans=transpose::transortrans=transpose::conjtransColumn major
Must be at least
mMust be at least
nRow major
Must be at least
nMust be at least
m- dependencies
List of events to wait for before starting computation, if any. If omitted, defaults to no dependencies.
Output Parameters#
- b
Pointer to output matrix
Boverwritten byalpha* op(A).trans=transpose::nontranstrans=transpose::transortrans=transpose::conjtransColumn major
Bismxnmatrix. Size of arraybmust be at leastldb*nBisnxmmatrix. Size of arrayamust be at leastldb*mRow major
Bismxnmatrix. Size of arraybmust be at leastldb*mBisnxmmatrix. Size of arraybmust be at leastldb*n
Return Values#
Output event to wait for to ensure computation is complete.