Commit f46f93d8 authored by Pavel Kus's avatar Pavel Kus

interface to symv added

parent 1427731f
......@@ -411,6 +411,62 @@ module cuda_functions
end interface
interface
subroutine cublas_dsymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy) bind(C,name='cublasDsymv')
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT),value :: n
integer(kind=C_INT), intent(in), value :: lda,incx,incy
real(kind=C_DOUBLE),value :: alpha,beta
integer(kind=C_intptr_T), value :: a, x, y
end subroutine cublas_dsymv_c
end interface
interface
subroutine cublas_ssymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy) bind(C,name='cublasSsymv')
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT),value :: n
integer(kind=C_INT), intent(in), value :: lda,incx,incy
real(kind=C_FLOAT),value :: alpha,beta
integer(kind=C_intptr_T), value :: a, x, y
end subroutine cublas_ssymv_c
end interface
! interface
! subroutine cublas_zsymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy) bind(C,name='cublasZsymv')
!
! use iso_c_binding
!
! implicit none
! character(1,C_CHAR),value :: cta
! integer(kind=C_INT),value :: n
! integer(kind=C_INT), intent(in), value :: lda,incx,incy
! complex(kind=C_DOUBLE),value :: alpha,beta
! integer(kind=C_intptr_T), value :: a, x, y
! end subroutine cublas_zsymv_c
! end interface
!
! interface
! subroutine cublas_csymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy) bind(C,name='cublasCsymv')
!
! use iso_c_binding
!
! implicit none
! character(1,C_CHAR),value :: cta
! integer(kind=C_INT),value :: n
! integer(kind=C_INT), intent(in), value :: lda,incx,incy
! complex(kind=C_FLOAT),value :: alpha,beta
! integer(kind=C_intptr_T), value :: a, x, y
! end subroutine cublas_csymv_c
! end interface
contains
......@@ -797,4 +853,61 @@ module cuda_functions
end subroutine cublas_cgemv
subroutine cublas_dsymv(cta, n, alpha, a, lda, x, incx, beta, y, incy)
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT) :: n
integer(kind=C_INT), intent(in) :: lda,incx,incy
real(kind=C_DOUBLE) :: alpha,beta
integer(kind=C_intptr_T) :: a, x, y
#ifdef WITH_GPU_VERSION
call cublas_dsymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy)
#endif
end subroutine cublas_dsymv
subroutine cublas_ssymv(cta, n, alpha, a, lda, x, incx, beta, y, incy)
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT) :: n
integer(kind=C_INT), intent(in) :: lda,incx,incy
real(kind=C_FLOAT) :: alpha,beta
integer(kind=C_intptr_T) :: a, x, y
#ifdef WITH_GPU_VERSION
call cublas_ssymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy)
#endif
end subroutine cublas_ssymv
subroutine cublas_zsymv(cta, n, alpha, a, lda, x, incx, beta, y, incy)
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT) :: n
integer(kind=C_INT), intent(in) :: lda,incx,incy
complex(kind=C_DOUBLE) :: alpha,beta
integer(kind=C_intptr_T) :: a, x, y
#ifdef WITH_GPU_VERSION
! call cublas_zsymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy)
#endif
end subroutine cublas_zsymv
subroutine cublas_csymv(cta, n, alpha, a, lda, x, incx, beta, y, incy)
use iso_c_binding
implicit none
character(1,C_CHAR),value :: cta
integer(kind=C_INT) :: n
integer(kind=C_INT), intent(in) :: lda,incx,incy
complex(kind=C_FLOAT) :: alpha,beta
integer(kind=C_intptr_T) :: a, x, y
#ifdef WITH_GPU_VERSION
! call cublas_csymv_c(cta, n, alpha, a, lda, x, incx, beta, y, incy)
#endif
end subroutine cublas_csymv
end module cuda_functions
......@@ -32,6 +32,7 @@
#undef cublas_PRECISION_GEMM
#undef cublas_PRECISION_TRMM
#undef cublas_PRECISION_GEMV
#undef cublas_PRECISION_SYMV
#undef PRECISION_SUFFIX
#undef CONST_0_0
......@@ -79,6 +80,7 @@
#define cublas_PRECISION_GEMM cublas_DGEMM
#define cublas_PRECISION_TRMM cublas_DTRMM
#define cublas_PRECISION_GEMV cublas_DGEMV
#define cublas_PRECISION_SYMV cublas_DSYMV
#define CONST_0_0 0.0_rk8
#define CONST_0_5 0.5_rk8
#define CONST_1_0 1.0_rk8
......@@ -122,6 +124,7 @@
#define cublas_PRECISION_GEMM cublas_SGEMM
#define cublas_PRECISION_TRMM cublas_STRMM
#define cublas_PRECISION_GEMV cublas_SGEMV
#define cublas_PRECISION_SYMV cublas_SSYMV
#define CONST_0_0 0.0_rk4
#define CONST_0_5 0.5_rk4
#define CONST_1_0 1.0_rk4
......@@ -170,6 +173,7 @@
#undef cublas_PRECISION_GEMM
#undef cublas_PRECISION_TRMM
#undef cublas_PRECISION_GEMV
#undef cublas_PRECISION_SYMV
#undef PRECISION_SUFFIX
#undef MPI_COMPLEX_PRECISION
#undef MPI_COMPLEX_EXPLICIT_PRECISION
......@@ -227,6 +231,7 @@
#define cublas_PRECISION_GEMM cublas_ZGEMM
#define cublas_PRECISION_TRMM cublas_ZTRMM
#define cublas_PRECISION_GEMV cublas_ZGEMV
#define cublas_PRECISION_SYMV cublas_ZSYMV
#define MPI_COMPLEX_PRECISION MPI_DOUBLE_COMPLEX
#define MPI_COMPLEX_EXPLICIT_PRECISION MPI_COMPLEX16
#define MPI_REAL_PRECISION MPI_REAL8
......@@ -280,6 +285,7 @@
#define cublas_PRECISION_GEMM cublas_CGEMM
#define cublas_PRECISION_TRMM cublas_CTRMM
#define cublas_PRECISION_GEMV cublas_CGEMV
#define cublas_PRECISION_SYMV cublas_CSYMV
#define MPI_COMPLEX_PRECISION MPI_COMPLEX
#define MPI_COMPLEX_EXPLICIT_PRECISION MPI_COMPLEX8
#define MPI_REAL_PRECISION MPI_REAL4
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment