Developer Reference for Intel® oneAPI Math Kernel Library for C

ID 766684
Date 12/16/2022
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

cblas_?copy_batch_strided

Computes a group of vector copies.

void cblas_scopy_batch_strided (const MKL_INT n, const float *x, const MKL_INT incx, const MKL_INT stridex, float *y, const MKL_INT incy, const MKL_INT stridey, const MKL_INT batch_size);

void cblas_dcopy_batch_strided (const MKL_INT n, const double *x, const MKL_INT incx, const MKL_INT stridex, double *y, const MKL_INT incy, const MKL_INT stridey, const MKL_INT batch_size);

void cblas_ccopy_batch_strided (const MKL_INT n, const void *x, const MKL_INT incx, const MKL_INT stridex, void *y, const MKL_INT incy, const MKL_INT stridey, const MKL_INT batch_size);

void cblas_zcopy_batch_strided (const MKL_INT n, const void *x, const MKL_INT incx, const MKL_INT stridex, void *y, const MKL_INT incy, const MKL_INT stridey, const MKL_INT batch_size);

Description

The cblas_?copy_batch_strided routines perform a series of vector copies. They are similar to their cblas_?copy routine counterparts, but the cblas_?copy_batch_strided routines perform vector operations with a group of vectors.

All vectors x and y have the same parameters (size, increments) and are stored at constant distance stridex (respectively, stridey) from each other. The operation is defined as follows:

for i = 0 … batch_size – 1
    X and Y are vectors at offset i * stridex and i * stridey in x and y
    Y = X
end for
Input Parameters
n
Number of elements in vectors x and y. Must be at least 0.
x
Array containing the input vectors. Must be of size at least (1 + (n-1)*abs(incx)) + (batch_size – 1) * stridex.
incx
Increment between two consecutive elements of a single vector in x.
stridex
Stride between two consecutive vectors in x. Must be at least (1 + (n-1)*abs(incx)).
y
Array holding the output vectors. Must be of size at least (1 + (n-1)*abs(incy)) + (batch_size – 1) * stridey.
incy
Increment between two consecutive elements of a single vector in y.
stridey
Stride between two consecutive y vectors. Must be at least (1 + (n-1)*abs(incy)).
batch_size
Number of copy computations to perform; also the number of x and y vectors. Must be at least 0.
Output Parameters
y
Array holding the batch_size copied vectors y.