Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Block-Strided RMA Operations #448

Merged
merged 8 commits into from
Oct 4, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 59 additions & 0 deletions content/shmem_ibget.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
\apisummary{
Copies blocks of strided data from a specified \ac{PE}.
}

\begin{apidefinition}

\begin{C11synopsis}
void @\FuncDecl{shmem\_ibget}@(TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ibget}@(shmem_ctx_t ctx, TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{C11synopsis}
where \TYPE{} is one of the standard \ac{RMA} types specified by Table \ref{stdrmatypes}.

\begin{Csynopsis}
void @\FuncDecl{shmem\_\FuncParam{TYPENAME}\_ibget}@(TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ctx\_\FuncParam{TYPENAME}\_ibget}@(shmem_ctx_t ctx, TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{Csynopsis}
where \TYPE{} is one of the standard \ac{RMA} types and has a corresponding \TYPENAME{} specified by Table \ref{stdrmatypes}.

\begin{CsynopsisCol}
void @\FuncDecl{shmem\_ibget\FuncParam{SIZE}}@(void *dest, const void *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ctx\_ibget\FuncParam{SIZE}}@(shmem_ctx_t ctx, void *dest, const void *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{CsynopsisCol}
where \SIZE{} is one of \CONST{8, 16, 32, 64, 128}.

\begin{apiarguments}
\apiargument{IN}{ctx}{A context handle specifying the context on which to perform the operation.
When this argument is not provided, the operation is performed on
the default context.}
\apiargument{OUT}{dest}{Local address of the array to be updated.
The type of \dest{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{source}{Symmetric address of the source array data object.
The type of \source{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{dst}{The stride between consecutive elements of the \dest{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \dest{} array. A value of \CONST{1}
indicates contiguous data.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{sst}{The stride between consecutive elements of the \source{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \source{} array. A value of \CONST{1}
indicates contiguous data.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{bsize}{Number of elements per block in the \dest{} and \source{}
arrays.}
\apiargument{IN}{nblocks}{Number of blocks in the \dest{} and \source{}
arrays.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{pe}{\ac{PE} number of the remote \ac{PE}.}
\end{apiarguments}

\apidescription{
The \FUNC{shmem\_ibget} routines provide a method for copying strided data blocks from
a symmetric array from a specified remote \ac{PE} to strided locations on a
local array. The routines return when the data has been copied into the local
\VAR{dest} array.
}

\apireturnvalues{
None.
}

jdinan marked this conversation as resolved.
Show resolved Hide resolved
\end{apidefinition}
62 changes: 62 additions & 0 deletions content/shmem_ibput.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
\apisummary{
Copies strided data blocks to a specified \ac{PE}.
}

\begin{apidefinition}

\begin{C11synopsis}
void @\FuncDecl{shmem\_ibput}@(TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ibput}@(shmem_ctx_t ctx, TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{C11synopsis}
where \TYPE{} is one of the standard \ac{RMA} types specified by Table \ref{stdrmatypes}.

\begin{Csynopsis}
void @\FuncDecl{shmem\_\FuncParam{TYPENAME}\_ibput}@(TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ctx\_\FuncParam{TYPENAME}\_ibput}@(shmem_ctx_t ctx, TYPE *dest, const TYPE *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{Csynopsis}
where \TYPE{} is one of the standard \ac{RMA} types and has a corresponding \TYPENAME{} specified by Table \ref{stdrmatypes}.

\begin{CsynopsisCol}
void @\FuncDecl{shmem\_ibput\FuncParam{SIZE}}@(void *dest, const void *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
void @\FuncDecl{shmem\_ctx\_ibput\FuncParam{SIZE}}@(shmem_ctx_t ctx, void *dest, const void *source, ptrdiff_t dst, ptrdiff_t sst, size_t bsize, size_t nblocks, int pe);
\end{CsynopsisCol}
where \SIZE{} is one of \CONST{8, 16, 32, 64, 128}.

\begin{apiarguments}
\apiargument{IN}{ctx}{A context handle specifying the context on which to perform the operation.
When this argument is not provided, the operation is performed on
the default context.}
\apiargument{OUT}{dest}{Symmetric address of the destination array data object.
The type of \dest{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{source}{Local address of the array containing the data to be copied.
The type of \source{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{dst}{The stride between consecutive elements of the \dest{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \dest{} array. A value of \CONST{1}
indicates contiguous data.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{sst}{The stride between consecutive elements of the \source{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \source{} array. A value of \CONST{1}
indicates contiguous data.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{bsize}{Number of elements per block in the \dest{} and \source{}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
arrays.}
\apiargument{IN}{nblocks}{Number of blocks in the \dest{} and \source{}
arrays.}
jdinan marked this conversation as resolved.
Show resolved Hide resolved
\apiargument{IN}{pe}{\ac{PE} number of the remote \ac{PE}.}
\end{apiarguments}


\apidescription{
The \FUNC{shmem\_ibput} routines provide a method for copying strided data
jdinan marked this conversation as resolved.
Show resolved Hide resolved
elements (specified by \VAR{sst}) of an array from a \source{} array on the
jdinan marked this conversation as resolved.
Show resolved Hide resolved
local \ac{PE} to locations specified by stride \VAR{dst} on a \dest{} array
on specified remote \ac{PE}. The routines return when the data has
been copied out of the \VAR{source} array on the local \ac{PE} but not
necessarily before the data has been delivered to the remote data object.
}

\apireturnvalues{
None.
}

\end{apidefinition}
14 changes: 8 additions & 6 deletions content/shmem_iget.tex
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,20 @@
\apiargument{IN}{source}{Symmetric address of the source array data object.
The type of \source{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{dst}{The stride between consecutive elements of the \dest{}
array. The stride is scaled by the element size of the \dest{} array.
A value of \CONST{1} indicates contiguous data.}
\apiargument{IN}{sst}{The stride between consecutive elements of the
\source{} array. The stride is scaled by the element size of the \source{}
array. A value of \CONST{1} indicates contiguous data.}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \dest{} array. A value of \CONST{1}
indicates contiguous data.}
\apiargument{IN}{sst}{The stride between consecutive elements of the \source{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \source{} array. A value of \CONST{1}
indicates contiguous data.}
\apiargument{IN}{nelems}{Number of elements in the \dest{} and \source{}
arrays.}
\apiargument{IN}{pe}{\ac{PE} number of the remote \ac{PE}.}
\end{apiarguments}

\apidescription{
The \FUNC{iget} routines provide a method for copying strided data elements from
The \FUNC{shmem\_iget} routines provide a method for copying strided data elements from
a symmetric array from a specified remote \ac{PE} to strided locations on a
local array. The routines return when the data has been copied into the local
\VAR{dest} array.
Expand Down
22 changes: 9 additions & 13 deletions content/shmem_iput.tex
Original file line number Diff line number Diff line change
Expand Up @@ -31,22 +31,23 @@
\apiargument{IN}{source}{Local address of the array containing the data to be copied.
The type of \source{} should match that implied in the SYNOPSIS section.}
\apiargument{IN}{dst}{The stride between consecutive elements of the \dest{}
array. The stride is scaled by the element size of the \dest{} array. A
value of \CONST{1} indicates contiguous data.}
\apiargument{IN}{sst}{The stride between consecutive elements of the
\source{} array. The stride is scaled by the element size of the \source{}
array. A value of \CONST{1} indicates contiguous data.}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \dest{} array. A value of \CONST{1}
indicates contiguous data.}
\apiargument{IN}{sst}{The stride between consecutive elements of the \source{}
array. The stride must be greater than or equal to \CONST{1} and is
scaled by the element size of the \source{} array. A value of \CONST{1}
indicates contiguous data.}
\apiargument{IN}{nelems}{Number of elements in the \dest{} and \source{} arrays.}
\apiargument{IN}{pe}{\ac{PE} number of the remote \ac{PE}.}
\end{apiarguments}


\apidescription{
The \FUNC{iput} routines provide a method for copying strided data
The \FUNC{shmem\_iput} routines provide a method for copying strided data
elements (specified by \VAR{sst}) of an array from a \source{} array on the
local \ac{PE} to locations specified by stride \VAR{dst} on a \dest{} array
on specified remote \ac{PE}. Both strides, \VAR{dst} and \VAR{sst}, must be
greater than or equal to \CONST{1}. The routines return when the data has
on specified remote \ac{PE}. The routines return when the data has
been copied out of the \VAR{source} array on the local \ac{PE} but not
necessarily before the data has been delivered to the remote data object.
}
Expand All @@ -55,11 +56,6 @@
None.
}

\apinotes{
See Section \ref{subsec:memory_model} for a definition of the term
remotely accessible.
}

\begin{apiexamples}

\apicexample
Expand Down
6 changes: 6 additions & 0 deletions main_spec.tex
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ \subsubsubsection{\textbf{SHMEM\_P}}\label{subsec:shmem_p}
\subsubsubsection{\textbf{SHMEM\_IPUT}}\label{subsec:shmem_iput}
\input{content/shmem_iput.tex}

\subsubsubsection{\textbf{SHMEM\_IBPUT}}\label{subsec:shmem_ibput}
\input{content/shmem_ibput.tex}

\subsubsubsection{\textbf{SHMEM\_GET}}\label{subsec:shmem_get}
\input{content/shmem_get.tex}

Expand All @@ -180,6 +183,9 @@ \subsubsubsection{\textbf{SHMEM\_G}}\label{subsec:shmem_g}
\subsubsubsection{\textbf{SHMEM\_IGET}}\label{subsec:shmem_iget}
\input{content/shmem_iget.tex}

\subsubsubsection{\textbf{SHMEM\_IBGET}}\label{subsec:shmem_ibget}
\input{content/shmem_ibget.tex}

\subsubsection{Nonblocking Remote Memory Access Routines}\label{subsec:rma_nbi}

\subsubsubsection{\textbf{SHMEM\_PUT\_NBI}}\label{subsec:shmem_put_nbi}
Expand Down