11 namespace linearAlgebra
18 template <
typename ValueType1,
62 const ValueType1 alpha,
142 const ValueType1 * dA,
143 const ValueType2 * dB,
176 const ValueType1 * A,
177 const ValueType2 * B,
193 const ValueType1 * x,
195 const ValueType2 * y,
213 const ValueType1 * x,
216 const ValueType2 * y,
241 const ValueType1 * multiVecDataX,
242 const ValueType2 * multiVecDataY,
249 template <
typename ValueType, dftefe::utils::MemorySpace memorySpace>
262 static std::vector<double>
265 ValueType
const * multiVecData,
277 static std::vector<double>
280 const ValueType * multiVecData,
284 template <
typename ValueType, dftefe::utils::MemorySpace memorySpace>
290 template <
typename ValueType1,
303 const ValueType1 * copyFromVec,
304 ValueType2 * copyToVec,
309 const ValueType1 *valueType1Arr,
310 ValueType2 * valueType2Arr,
323 const ValueType1 *copyFromVec,
324 ValueType2 * copyToVec,
328#ifdef DFTEFE_WITH_DEVICE
329 template <
typename ValueType>
336 template <
typename ValueType1,
typename ValueType2>
337 class KernelsTwoValueTypes<ValueType1,
345 const ValueType2 * x,
346 scalar_type<ValueType1, ValueType2> * z,
352 const ValueType2 * x,
355 scalar_type<ValueType1, ValueType2> * z,
366 const ValueType1 alpha,
367 const ValueType2 * x,
368 scalar_type<ValueType1, ValueType2> * z,
374 const ValueType1 * x,
375 const ValueType2 * y,
376 scalar_type<ValueType1, ValueType2> * z,
382 const ValueType1 * x,
383 const ValueType2 * y,
386 scalar_type<ValueType1, ValueType2> * z,
401 const ValueType1 * dA,
402 const ValueType2 * dB,
403 scalar_type<ValueType1, ValueType2> * dC,
412 const ValueType1 * A,
413 const ValueType2 * B,
414 scalar_type<ValueType1, ValueType2> * Z,
419 scalar_type<ValueType1, ValueType2> alpha,
420 const ValueType1 * x,
421 scalar_type<ValueType1, ValueType2> beta,
422 const ValueType2 * y,
423 scalar_type<ValueType1, ValueType2> * z,
430 const scalar_type<ValueType1, ValueType2> alpha1,
431 const scalar_type<ValueType1, ValueType2> * alpha,
432 const ValueType1 * x,
433 const scalar_type<ValueType1, ValueType2> beta1,
434 const scalar_type<ValueType1, ValueType2> * beta,
435 const ValueType2 * y,
436 scalar_type<ValueType1, ValueType2> * z,
443 const ValueType1 * multiVecDataX,
444 const ValueType2 * multiVecDataY,
447 scalar_type<ValueType1, ValueType2> *multiVecDotProduct,
451 template <
typename ValueType>
455 static std::vector<double>
459 ValueType
const * multiVecData,
460 LinAlgOpContext<dftefe::utils::MemorySpace::DEVICE> &context);
463 static std::vector<double>
467 const ValueType * multiVecData,
468 LinAlgOpContext<dftefe::utils::MemorySpace::DEVICE> &context);
471 template <
typename ValueType1,
typename ValueType2>
472 class CopyKernelTwoValueTypes<ValueType1,
485 const ValueType1 * copyFromVec,
486 ValueType2 * copyToVec,
487 LinAlgOpContext<dftefe::utils::MemorySpace::DEVICE> &context);
492 const ValueType1 * valueType1Arr,
493 ValueType2 * valueType2Arr,
494 LinAlgOpContext<dftefe::utils::MemorySpace::DEVICE> &context);
507 const ValueType1 *copyFromVec,
508 ValueType2 * copyToVec,
509 LinAlgOpContext<dftefe::utils::MemorySpace::DEVICE> &context);
Definition: LinAlgOpContext.h:52
Definition: BlasLapackKernels.h:286
Definition: BlasLapackKernels.h:294
static void varBatchedStridedBlockCopy(const size_type numBatch, const size_type *strideSrc, const size_type *strideDst, const size_type *vecSizeArr, const size_type *numVecArr, const size_type *srcLeadingDimArr, const size_type *srcBlockStartIdArr, const size_type *dstLeadingDimArr, const size_type *dstBlockStartIdArr, const ValueType1 *copyFromVec, ValueType2 *copyToVec, LinAlgOpContext< memorySpace > &context)
Definition: BlasLapackKernels.cpp:619
static void stridedBlockCopy(const size_type vecSize, const size_type numVec, const size_type srcLeadingDim, const size_type srcBlockStartId, const size_type dstLeadingDim, const size_type dstBlockStartId, const ValueType1 *copyFromVec, ValueType2 *copyToVec, LinAlgOpContext< memorySpace > &context)
Definition: BlasLapackKernels.cpp:565
static void copyValueType1ArrToValueType2Arr(const size_type size, const ValueType1 *valueType1Arr, ValueType2 *valueType2Arr, LinAlgOpContext< memorySpace > &context)
Definition: BlasLapackKernels.cpp:662
Definition: BlasLapackKernels.h:251
static std::vector< double > nrms2MultiVector(size_type vecSize, size_type numVec, const ValueType *multiVecData, LinAlgOpContext< memorySpace > &context)
Template for computing norms of all the numVec vectors in a multi Vector.
Definition: BlasLapackKernels.cpp:542
static std::vector< double > amaxsMultiVector(const size_type vecSize, const size_type numVec, ValueType const *multiVecData, LinAlgOpContext< memorySpace > &context)
Template for computing norms of all the numVec vectors in a multi Vector.
Definition: BlasLapackKernels.cpp:514
namespace class for BlasLapack kernels not present in blaspp.
Definition: BlasLapackKernels.h:22
static void scaleStridedVarBatched(const size_type numMats, const Layout layout, const ScalarOp &scalarOpA, const ScalarOp &scalarOpB, const size_type *stridea, const size_type *strideb, const size_type *stridec, const size_type *m, const size_type *n, const size_type *k, const ValueType1 *dA, const ValueType2 *dB, scalar_type< ValueType1, ValueType2 > *dC, LinAlgOpContext< memorySpace > &context)
Template for performing hadamard product of two columns of batches of matrix A and B having num col A...
Definition: BlasLapackKernels.cpp:264
static void axpby(size_type size, scalar_type< ValueType1, ValueType2 > alpha, const ValueType1 *x, scalar_type< ValueType1, ValueType2 > beta, const ValueType2 *y, scalar_type< ValueType1, ValueType2 > *z, LinAlgOpContext< memorySpace > &context)
Template for performing .
Definition: BlasLapackKernels.cpp:373
static void ascale(size_type size, ValueType1 alpha, const ValueType2 *x, const ScalarOp &opalpha, const ScalarOp &opx, scalar_type< ValueType1, ValueType2 > *z, LinAlgOpContext< memorySpace > &context)
Template for performing alpha z = \alpha x$.
Definition: BlasLapackKernels.cpp:91
static void hadamardProduct(size_type size, const ValueType1 *x, const ValueType2 *y, scalar_type< ValueType1, ValueType2 > *z, LinAlgOpContext< memorySpace > &context)
Template for performing z_i = x_i * y_i$.
Definition: BlasLapackKernels.cpp:187
static void dotMultiVector(size_type vecSize, size_type numVec, const ValueType1 *multiVecDataX, const ValueType2 *multiVecDataY, const ScalarOp &opX, const ScalarOp &opY, scalar_type< ValueType1, ValueType2 > *multiVecDotProduct, LinAlgOpContext< memorySpace > &context)
Template for computing dot products numVec vectors in a multi Vector.
Definition: BlasLapackKernels.cpp:427
static void axpbyBlocked(const size_type size, const size_type blockSize, const scalar_type< ValueType1, ValueType2 > alpha1, const scalar_type< ValueType1, ValueType2 > *alpha, const ValueType1 *x, const scalar_type< ValueType1, ValueType2 > beta1, const scalar_type< ValueType1, ValueType2 > *beta, const ValueType2 *y, scalar_type< ValueType1, ValueType2 > *z, LinAlgOpContext< memorySpace > &context)
Template for performing .
Definition: BlasLapackKernels.cpp:395
static void khatriRaoProduct(const Layout layout, const size_type sizeI, const size_type sizeJ, const size_type sizeK, const ValueType1 *A, const ValueType2 *B, scalar_type< ValueType1, ValueType2 > *Z, LinAlgOpContext< memorySpace > &context)
Template for performing In column major storage format: , where is matrix, is ,...
Definition: BlasLapackKernels.cpp:340
void reciprocalX(size_type n, const ValueType1 alpha, ValueType2 const *x, scalar_type< ValueType1, ValueType2 > *y, LinAlgOpContext< memorySpace > &context)
Template for computing the multiplicative inverse of all the elements of x, does not check if any ele...
Definition: BlasLapack.t.cpp:78
Layout
Definition: BlasLapackTypedef.h:161
typeInternal::scalar_type< ValueType1, ValueType2 > scalar_type
Definition: BlasLapackTypedef.h:183
ScalarOp
Definition: BlasLapackTypedef.h:169
MemorySpace
Definition: MemorySpaceType.h:37
dealii includes
Definition: AtomFieldDataSpherical.cpp:31
std::uint64_t size_type
Definition: TypeConfig.h:9