self_blas_matrixop_dim2_2d Subroutine

public subroutine self_blas_matrixop_dim2_2d(A, f, Af, beta, controldegree, targetdegree, nvars, nelems, handle)

Arguments

TypeIntentOptionalAttributesName
type(c_ptr), intent(in) :: A
real(kind=prec), intent(in), pointer:: f(:,:,:,:)
real(kind=prec), intent(inout), pointer:: Af(:,:,:,:)
real(kind=c_prec), intent(in) :: beta
integer, intent(in) :: controldegree
integer, intent(in) :: targetdegree
integer, intent(in) :: nvars
integer, intent(in) :: nelems
type(c_ptr), intent(inout) :: handle

Calls

proc~~self_blas_matrixop_dim2_2d~~CallsGraph proc~self_blas_matrixop_dim2_2d self_blas_matrixop_dim2_2d hipblasgemvstridedbatched hipblasgemvstridedbatched proc~self_blas_matrixop_dim2_2d->hipblasgemvstridedbatched proc~hipblascheck hipblasCheck proc~self_blas_matrixop_dim2_2d->proc~hipblascheck

Called by

proc~~self_blas_matrixop_dim2_2d~~CalledByGraph proc~self_blas_matrixop_dim2_2d self_blas_matrixop_dim2_2d proc~gradient_vector2d Gradient_Vector2D proc~gradient_vector2d->proc~self_blas_matrixop_dim2_2d proc~gridinterp_scalar2d GridInterp_Scalar2D proc~gridinterp_scalar2d->proc~self_blas_matrixop_dim2_2d proc~gridinterp_vector2d GridInterp_Vector2D proc~gridinterp_vector2d->proc~self_blas_matrixop_dim2_2d proc~gradient_scalar2d Gradient_Scalar2D proc~gradient_scalar2d->proc~self_blas_matrixop_dim2_2d

Contents


Source Code

                          subroutine self_blas_matrixop_dim2_2d(A,f,Af,beta,controldegree,targetdegree,nvars,nelems,handle)
                            type(c_ptr),intent(in) :: A
                            real(prec),pointer,intent(in) :: f(:,:,:,:)
                            real(prec),pointer,intent(inout) :: Af(:,:,:,:)
                            real(c_prec),intent(in) :: beta
                            integer,intent(in) :: controldegree,targetdegree,nvars,nelems
                            type(c_ptr),intent(inout) :: handle
                            ! Local
                            integer(c_int) :: m
                            integer(c_int) :: n
                            real(c_prec) :: alpha
                            integer(c_int) :: lda

                            integer :: i
                            integer(c_int64_t) :: strideA
                            integer(c_int) :: incx
                            integer(c_int64_t) :: stridex
                            integer(c_int) :: incy
                            integer(c_int64_t) :: stridey
                            integer(c_int) :: batchCount

                            m = controldegree+1 ! number of rows of A
                            n = targetdegree+1 ! number of columns of A
                            alpha = 1.0_c_prec
                            lda = m ! leading dimension of A
                            strideA = 0 ! stride for the batches of A (no stride)
                            incx = targetdegree+1 !
                            stridex = (controldegree+1)*(targetdegree+1)
                            incy = targetdegree+1
                            stridey = (targetdegree+1)*(targetdegree+1)
                            batchCount = nvars*nelems
                            do i = 0,targetdegree
                              call hipblasCheck(hipblasgemvStridedBatched(handle, &
                                                                          HIPBLAS_OP_T, &
                                                                          m,n,alpha, &
                                                                          A,lda,strideA, &
                                                                          c_loc(f(1+i,1,1,1)),incx,stridex,beta, &
                                                                          c_loc(Af(1+i,1,1,1)),incy,stridey,batchCount))
                            enddo

                          endsubroutine self_blas_matrixop_dim2_2d