rocblas_chpr2 Interface Reference

rocblas_chpr2 Interface Reference#

HIPFORT API Reference: hipfort_rocblas::rocblas_chpr2 Interface Reference
hipfort_rocblas::rocblas_chpr2 Interface Reference

BLAS Level 2 API. More...

Public Member Functions

integer(kind(rocblas_status_success)) function rocblas_chpr2_ (handle, uplo, n, alpha, x, incx, y, incy, ap)
 
integer(kind(rocblas_status_success)) function rocblas_chpr2_rank_0 (handle, uplo, n, alpha, x, incx, y, incy, ap)
 
integer(kind(rocblas_status_success)) function rocblas_chpr2_rank_1 (handle, uplo, n, alpha, x, incx, y, incy, ap)
 

Detailed Description

BLAS Level 2 API.

The hpr2 functions perform the matrix-vector operations:

A := A + alpha*x*y**H + conj(alpha)*y*x**H

where alpha is a complex scalar, x and y are vectors, and A is an n by n Hermitian matrix, supplied in packed form.

Parameters
[in]handle- [rocblas_handle] handle to the rocBLAS library context queue.
[in]uplo- [rocblas_fill] specifies either upper (rocblas_fill_upper) or lower (rocblas_fill_lower).
  • rocblas_fill_upper: The upper triangular part of A is supplied in AP.
  • rocblas_fill_lower: The lower triangular part of A is supplied in AP.
[in]n- [rocblas_int] the number of rows and columns of matrix A. Must be at least 0.
[in]alphadevice pointer or host pointer to scalar alpha.
[in]x- device pointer storing vector x.
[in]incx- [rocblas_int] specifies the increment for the elements of x.
[in]y- device pointer storing vector y.
[in]incy- [rocblas_int] specifies the increment for the elements of y.
[in,out]AP- device pointer storing the packed version of the specified triangular portion of the Hermitian matrix A. Of at least size ((n * (n + 1)) / 2).
  if uplo == rocblas_fill_upper:
      The upper triangular portion of the Hermitian matrix A is supplied.
      The matrix is compacted so that AP contains the triangular portion
      column-by-column
      so that:
      AP(0) = A(0,0)
      AP(1) = A(0,1)
      AP(2) = A(1,1), etc.
      Ex: (rocblas_fill_upper; n = 3)
          (1, 0) (2, 1) (4,9)
          (2,-1) (3, 0) (5,3) ---> [(1,0),(2,1),(3,0),(4,9),(5,3),(6,0)]
          (4,-9) (5,-3) (6,0)

  if uplo == rocblas_fill_lower:
      The lower triangular portion of the Hermitian matrix A is supplied.
      The matrix is compacted so that AP contains the triangular portion
      column-by-column
      so that:
      AP(0) = A(0,0)
      AP(1) = A(1,0)
      AP(2) = A(2,1), etc.
      Ex: (rocblas_fill_lower; n = 3)
          (1, 0) (2, 1) (4,9)
          (2,-1) (3, 0) (5,3) ---> [(1,0),(2,-1),(4,-9),(3,0),(5,-3),(6,0)]
          (4,-9) (5,-3) (6,0)
Note that the imaginary parts of the diagonal elements are not accessed and are assumed to be 0.

Member Function/Subroutine Documentation

◆ rocblas_chpr2_()

integer(kind(rocblas_status_success)) function hipfort_rocblas::rocblas_chpr2::rocblas_chpr2_ ( type(c_ptr), value  handle,
integer(kind(rocblas_fill_upper)), value  uplo,
integer(c_int), value  n,
complex(c_float_complex)  alpha,
type(c_ptr), value  x,
integer(c_int), value  incx,
type(c_ptr), value  y,
integer(c_int), value  incy,
type(c_ptr), value  ap 
)

◆ rocblas_chpr2_rank_0()

integer(kind(rocblas_status_success)) function hipfort_rocblas::rocblas_chpr2::rocblas_chpr2_rank_0 ( type(c_ptr)  handle,
integer(kind(rocblas_fill_upper))  uplo,
integer(c_int)  n,
complex(c_float_complex)  alpha,
complex(c_float_complex), target  x,
integer(c_int)  incx,
complex(c_float_complex), target  y,
integer(c_int)  incy,
complex(c_float_complex), target  ap 
)

◆ rocblas_chpr2_rank_1()

integer(kind(rocblas_status_success)) function hipfort_rocblas::rocblas_chpr2::rocblas_chpr2_rank_1 ( type(c_ptr)  handle,
integer(kind(rocblas_fill_upper))  uplo,
integer(c_int)  n,
complex(c_float_complex)  alpha,
complex(c_float_complex), dimension(:), target  x,
integer(c_int)  incx,
complex(c_float_complex), dimension(:), target  y,
integer(c_int)  incy,
complex(c_float_complex), dimension(:), target  ap 
)

The documentation for this interface was generated from the following file: