On Wed, Dec 09, 2020 at 07:34:09PM +0100, Alejandro Colomar (man-pages) wrote: > Hi Heinrich & Michael, > > What about the following?: > > [ > NOTES > GCC provides a similar function, which may be useful on archi‐ > tectures that lack this system call: > > void __builtin___clear_cache(void *begin, void *end); > ] > > Cheers, > > Alex Maybe we should discourage people from calling the cacheflush syscall? I think that people shouldn't be using the syscall unless they really need the finer grained control it provides, and are prepared to take a hit to portability. (On arches where userspace is allowed to do cache flushing directly, __builtin___clear_cache() should transparently do the right thing, with no syscall overhead -- if not, that's probably a bug in the toolchain or compiler support library.) [...] Cheers ---Dave