Add GPU references and example to docs: first round.

This commit is contained in:
Salvatore Filippone
2021-04-06 14:37:34 +02:00
parent b4b96d9338
commit 53747b8534
38 changed files with 4332 additions and 4251 deletions
+13 -1
View File
@@ -48,7 +48,7 @@ work in the expected way. Our advice is first to download the LAPACK tarfile fro
\href{http://www.netlib.org/lapack}{www.netlib.org/lapack} and install it independently of ATLAS. In this case,
you need to modify the OPTS and NOOPT definitions for including -fPIC compilation option
in the make.inc file of the LAPACK library.
\item[MPI] \cite{MPI2,MPI1} A version of MPI is available on most
\item[MPI] \cite{MPI2,MPI1} A version of MPI is available on most
high-performance computing systems.
\item[PSBLAS] \cite{PSBLASGUIDE,psblas_00} Parallel Sparse BLAS (PSBLAS) is
available from
@@ -61,6 +61,18 @@ Please note that the four previous libraries must have Fortran
interfaces compatible with AMG4PSBLAS; usually this means that they
should all be built with the same compiler being used for AMG4PSBLAS.
If you want to use the PSBLAS support for NVIDIA GPUs, you will also
need:
\begin{description}
\item[PSBLAS-EXT] Parallel Sparse BLAS (PSBLAS) Extensions,
available from
\href{https://psctoolkit.github.io/products/psblasext/}{psctoolkit.github.io/products/psblasext/}; version 1.3.0 (or later).
\item[SPGPU] Sparse CUDA kernels for NVIDIA GPUs; available from
GitHub, see also
\href{https://psctoolkit.github.io/products/psblasext/}{psctoolkit.github.io/products/psblasext/}.
\end{description}
See also Sec~\ref{sec:gpu-example}.
\subsection{Optional third party libraries\label{sec:third-party}}
We provide interfaces to the following third-party software libraries;
+39
View File
@@ -416,6 +416,45 @@ call P%build(A,desc_A,info)
\end{listing}
\subsection{GPU example\label{sec:gpu-example}}
The code reported in Figure~\ref{fig:gpu-ex1} shows how to set up a
program exploiting the combined GPU capabilities of PSBLAS and
AMG4PSBLAS.
\begin{listing}[h!]
\ifpdf
\begin{minted}[breaklines=true,bgcolor=bg,fontsize=\small]{fortran}
! build a one-level RAS with overlap 2 and ILU(0) on the local blocks.
call P%init('AS',info)
call P%set('SUB_OVR',2,info)
call P%build(A,desc_A,info)
... ...
! solve Ax=b with preconditioned BiCGSTAB
call psb_krylov('BICGSTAB',A,P,b,x,tol,desc_A,info)
\end{minted}
\else
\begin{center}
\begin{minipage}{.90\textwidth}
{\small
\begin{verbatim}
! build a one-level RAS with overlap 2 and ILU(0) on the local blocks.
call P%init('AS',info)
call P%set('SUB_OVR',2,info)
call P%build(A,desc_A,info)
... ...
! solve Ax=b with preconditioned BiCGSTAB
call psb_krylov('BICGSTAB',A,P,b,x,tol,desc_A,info)
\end{verbatim}
}
\end{minipage}
\end{center}
\fi
\caption{setup of a one-level Schwarz preconditioner.\label{fig:gpu-ex1}}
\end{listing}
%%% Local Variables:
%%% mode: latex
%%% TeX-master: "userguide"