SHMEM_SET_CACHE_LINE_INV(3)
π SHMEM_SET_CACHE_LINE_INV(3) β Open MPI, section 3 π
okay bestie, sit DOWN because we're talking about cache coherency today and honestly? it's giving β¨controlβ¨
this lil family of routines is the data cache utilities crew: shmem_clear_cache_inv, shmem_set_cache_inv, shmem_set_cache_line_inv, shmem_udcflush, and shmem_udcflush_line. yes they all show up here, they're a package deal, no gatekeeping πΈ
β¨ SYNOPSIS β¨
π©· C or C++
#include <mpp/shmem.h>
void shmem_clear_cache_inv(void)
void shmem_clear_cache_line_inv(void *target)
void shmem_set_cache_inv(void)
void shmem_set_cache_line_inv(void *target)
void shmem_udcflush(void)
void shmem_udcflush_line(void *target)
π©· Fortran
INCLUDE "mpp/shmem.fh"
CALL SHMEM_CLEAR_CACHE_INV
CALL SHMEM_CLEAR_CACHE_LINE_INV(target)
CALL SHMEM_SET_CACHE_INV
CALL SHMEM_SET_CACHE_LINE_INV(target)
CALL SHMEM_UDCFLUSH
CALL SHMEM_UDCFLUSH_LINE(target)
π DESCRIPTION π
okay so there's one argument that gets passed to the cache line control routines and she is iconic:
targetβ a data object that is local to the processing element (PE).targetcan be of any noncharacter type. and if you're in Fortran land, she can be of any kind π«Ά
now the tea on each routine:
shmem_clear_cache_inv(3) β disables automatic cache coherency mode that was previously enabled byshmem_set_cache_inv(3) orshmem_set_cache_line_inv. turning it OFF, bestie, lights out πshmem_clear_cache_line_inv(3) β disables automatic cache coherency mode for the cache line associated with the address oftargetonly. just that one line, not everybody, very targeted behavior slayshmem_set_cache_inv(3) β enables the OpenSHMEM API to automatically decide the best strategy for cache coherency. she's the main character making the calls πshmem_set_cache_line_invβ enables automatic cache coherency mode for the cache line associated with the address oftargetonly. again, just that one line, bc we're precise hereshmem_clear_cache_inv(3) β disables automatic cache coherency mode previously enabled byshmem_set_cache_inv(3) orshmem_set_cache_line_inv. and yeah, the page literally says this twice, i'm not playing, it's in the source like that, so here it is again, no cap πshmem_udcflush(3) β makes the entire user data cache coherent. the whole thing. all of it. periodtshmem_udcflush_line(3) β makes coherent the cache line that corresponds with the address specified bytarget. one line only, cute and specific π
π NOTES π
these routines have been retained for improved backward compatibility with legacy architectures. so like, they're still here serving looks for the old-school crowd π§ not new-new, but definitely still on the roster.
bestie reminder: retained for backward compatibility with legacy architectures. that's the whole vibe of this notes section, no cap.
See also: intro_shmem(3) shmem_put(3) shmem_swap(3)
π Copyright π
2003-2026, The Open MPI Community
and that's the whole page, bestie!! π this came to you straight from the Open MPI manual, dated Sep 10, 2026, courtesy of those Open MPI girlies at SHMEM_SET_CACHE_LINE_INV(3). go make your cache coherent, ily, bye π¦β¨π
π¦ 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