Skip to content

Commit

Permalink
Merge branch 'master' into pr/team_get_config_clarify
Browse files Browse the repository at this point in the history
  • Loading branch information
jdinan authored Aug 23, 2024
2 parents 44cd0c0 + 2592c49 commit bca0592
Show file tree
Hide file tree
Showing 10 changed files with 34 additions and 18 deletions.
14 changes: 12 additions & 2 deletions content/backmatter.tex
Original file line number Diff line number Diff line change
Expand Up @@ -686,8 +686,8 @@ \section{Version 1.6}
operations for team-based reductions.
\ChangelogRef{teamreducetypes}%
%
\item Added the session routines, \FUNC{shmem\_session\_start} and
\FUNC{shmem\_session\_stop}, which allow users to pass hints to the
\item Added the session routines, \FUNC{shmem\_ctx\_session\_start} and
\FUNC{shmem\_ctx\_session\_stop}, which allow users to pass hints to the
\openshmem library to apply runtime optimizations.
\ChangelogRef{subsec:sessions}%
\item Added fine grained completion routine: \FUNC{shmem\_pe\_quiet}.
Expand All @@ -697,6 +697,12 @@ \section{Version 1.6}
functions from a single entry in \openshmem[1.5] into separate entries.
\ChangelogRef{subsec:shmem_malloc, subsec:shmem_free, subsec:shmem_realloc,
subsec:shmem_align}%
%
\item Clarified that the \FUNC{shmem\_\{malloc, free, realloc, align,
malloc\_with\_hints, calloc\}} functions are collective operations on
the world team.
\ChangelogRef{subsec:shmem_malloc, subsec:shmem_free, subsec:shmem_realloc,
subsec:shmem_align, subsec:shmmallochint, subsec:shmem_calloc}%
\item Corrected the level argument's recommended value in API notes for
\FUNC{shmem\_pcontrol} to indicate that the value should be greater than
2 to enable profiling with profile library defined effects and
Expand All @@ -707,6 +713,10 @@ \section{Version 1.6}
\VAR{config\_mask} is 0 and/or the \VAR{config} argument is a null pointer.
\ChangelogRef{subsec:shmem_team_get_config}
%
\item Clarified the behavior of \FUNC{shmem\_team\_split\_strided} when the
stride argument is 0 or negative.
\ChangelogRef{subsec:shmem_team_split_strided}
%
\end{itemize}

\section{Version 1.5}
Expand Down
2 changes: 1 addition & 1 deletion content/collective_intro.tex
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
\end{enumerate}

Concurrent accesses to symmetric memory by an \openshmem collective
routine and any other means of access---where at least one updates the
routine and any other means of access---where at least one \ac{PE} updates the
symmetric memory---results in undefined behavior.
Since \acp{PE} can enter and exit collectives at different times,
accessing such memory remotely may require additional synchronization.
Expand Down
2 changes: 1 addition & 1 deletion content/memmgmt_intro.tex
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
symmetric data objects in the symmetric heap.

The symmetric memory allocation routines differ from the private heap
allocation routines in that they must be called by all \acp{PE} in a
allocation routines in that they must be called by all \acp{PE} in
the world team. When specified, each of these routines includes at
least one call to a procedure that is semantically equivalent to
\FUNC{shmem\_barrier\_all}. This ensures that all \acp{PE}
Expand Down
3 changes: 2 additions & 1 deletion content/shmem_align.tex
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@


\apidescription{
The \FUNC{shmem\_align} routine allocates a block in the symmetric
The \FUNC{shmem\_align} routine is a collective operation on the
world team that allocates a block in the symmetric
heap that has a byte alignment specified by the \VAR{alignment}
argument. The value of \VAR{alignment} shall be a multiple of
\CONST{sizeof(void *)} that is also a power of two; otherwise, the
Expand Down
3 changes: 2 additions & 1 deletion content/shmem_free.tex
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
\end{apiarguments}

\apidescription{
The \FUNC{shmem\_free} routine causes the block to which \VAR{ptr}
The \FUNC{shmem\_free} routine is a collective operation on the
world team that causes the block to which \VAR{ptr}
points to be deallocated, that is, made available for further
allocation. If \VAR{ptr} is a null pointer, no action is performed;
otherwise, \FUNC{shmem\_free} calls a barrier on entry.
Expand Down
3 changes: 2 additions & 1 deletion content/shmem_malloc.tex
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@


\apidescription{
The \FUNC{shmem\_malloc} routine returns the symmetric address of a
The \FUNC{shmem\_malloc} routine is a collective operation on the
world team and returns the symmetric address of a
block of at least \VAR{size} bytes, which shall be suitably aligned
so that it may be assigned to a pointer to any type of object.
This space is allocated from the symmetric heap (in contrast to
Expand Down
7 changes: 2 additions & 5 deletions content/shmem_malloc_hints.tex
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@

\apidescription{

The \FUNC{shmem\_malloc\_with\_hints} routine, like \FUNC{shmem\_malloc}, returns a pointer to a block of at least
The \FUNC{shmem\_malloc\_with\_hints} routine, like \FUNC{shmem\_malloc},
is a collective operation on the world team that returns a pointer to a block of at least
\VAR{size} bytes, which shall be suitably aligned so that it may be
assigned to a pointer to any type of object. This space is allocated from
the symmetric heap (similar to \FUNC{shmem\_malloc}). When the \VAR{size} is zero,
Expand Down Expand Up @@ -57,19 +58,15 @@
\tabularnewline \hline
\endhead
%%
\newline
\CONST{0} &
\newline
Behavior same as \FUNC{shmem\_malloc}
\tabularnewline \hline

\LibConstDecl{SHMEM\_MALLOC\_ATOMICS\_REMOTE} &
\newline
Memory used for \VAR{atomic} operations
\tabularnewline \hline

\LibConstDecl{SHMEM\_MALLOC\_SIGNAL\_REMOTE} &
\newline
Memory used for \VAR{signal} operations
\tabularnewline \hline

Expand Down
3 changes: 2 additions & 1 deletion content/shmem_realloc.tex
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@


\apidescription{
The \FUNC{shmem\_realloc} routine changes the size of the block to
The \FUNC{shmem\_realloc} routine is a collective operation on
the world team that changes the size of the block to
which \VAR{ptr} points to the size (in bytes) specified by
\VAR{size}. The contents of the block are unchanged up to the
lesser of the new and old sizes.
Expand Down
11 changes: 8 additions & 3 deletions content/shmem_team_split_strided.tex
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,15 @@
i \in \mathbb{Z}_{size-1}
\end{equation*}
where $\mathbb{Z}$ is the set of natural numbers ($0, 1, \dots$), $N$ is the
number of \acp{PE} in the parent team and $size$ is a positive number indicating
the number of \acp{PE} in the new team. The index $i$ specifies the number of
the given PE in the new team. Thus, \acp{PE} in the new team remain in the same
number of \acp{PE} in the parent team, $size$ is a positive number indicating
the number of \acp{PE} in the new team, and $stride$ is an integer.
The index $i$ specifies the number of the given PE in the new team.
When $stride$ is greater than zero, PEs in the new team remain in the same
relative order as in the parent team.
When $stride$ is less than zero, PEs in the new team are in \textit{reverse}
relative order with respect to the parent team.
If a $stride$ value equal to 0 is passed to \FUNC{shmem\_team\_split\_strided},
then the $size$ argument passed must be 1, or the behavior is undefined.

This routine must be called by all \acp{PE} in the parent team.
All \acp{PE} must provide the same values for the \ac{PE} triplet.
Expand Down
4 changes: 2 additions & 2 deletions content/teams_intro.tex
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ \subsubsection*{Predefined and Application-Defined Teams}
portion of an application.
Any team successfully created by a \FUNC{shmem\_team\_split\_*}
routine is valid until it is destroyed.
All valid teams have a least one member.
All valid teams have at least one member.

\subsubsection*{Team Handles}

Expand Down Expand Up @@ -84,7 +84,7 @@ \subsubsection*{Team Creation}

\acp{PE} in a newly created team are consecutively numbered starting with
\ac{PE} number 0. \acp{PE} are ordered by their \ac{PE} number in
the parent team. Team relative \ac{PE}
the parent team. Team-relative \ac{PE}
numbers can be used for point-to-point operations through team-based
contexts (see Section~\ref{sec:ctx}) or using the translation routine
\FUNC{shmem\_team\_translate\_pe}.
Expand Down

0 comments on commit bca0592

Please sign in to comment.