SHMEM_LONGLONG_INC(3)
β¨ SHMEM_LONGLONG_INC β atomic glow-up for your remote integers β¨
okay bestie, gather round, because this is the Open MPI manual page for shmem_int4_inc(3), shmem_int8_inc(3), shmem_int_inc <#shmem-int-inc>(3), shmem_long_inc <#shmem-long-inc>(3), and shmem_longlong_inc(3). what do they do? they perform an atomic increment operation on a remote data object. that's the whole vibe. adding one. remotely. atomically. iconic behavior honestly. π
πΈ SYNOPSIS πΈ
so here's how you call it in C or C++:
#include <mpp/shmem.h>
int shmem_int_inc(int *target, int pe)
long shmem_long_inc(long *target, int pe)
long long shmem_longlong_inc(long long *target, int pe)
and in Fortran:
INCLUDE "mpp/shmem.fh"
INTEGER pe
INTEGER(KIND=4) SHMEM_INT4_INC, target4
INTEGER(KIND=8) SHMEM_INT8_INC, target8
ires4 = SHMEM_INT4_INC(target4, pe)
ires8 = SHMEM_INT8_INC(target8, pe)
copy it exactly, do not freestyle the types, i am begging π«Ά
π DESCRIPTION π
The atomic increment routines replace the value of target with its value incremented by one. literally just +1, but make it atomic.
and the tea is: the operation must be completed without the possibility of another process updating target between the time of the fetch and the update. no sneaky interlopers. no race conditions. periodt. π
The arguments are as follows:
targetβ The remotely accessible integer data object to be updated on the remote PE. The type oftargetshould match that implied in the SYNOPSIS section. (so likeβ¦ match your types bestie, the compiler IS watching π§)peβ An integer that indicates the PE number upon whichtargetis to be updated. If you are using Fortran, it must be a default integer value. β¨
π NOTES π
The term remotely accessible is defined in intro_shmem(3). go read it, it's giving required reading. π
π RETURN VALUES π
None. </3
that's it. nothing. no return value. she does the thing and she comes back with zero receipts. π
See also:
π Copyright π
2003-2026, The Open MPI Community
okay lovelies, that's the whole page π this was the Open MPI version of SHMEM_LONGLONG_INC(3), dated Sep 10, 2026. now go increment something remotely and responsibly. mwah. π¦π
β¨
π¦ where this page comes from
- ubuntu stonking: openmpi-doc 5.0.10-6 Β· other
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms