resctrl_arch...ycles_lat_fn(9)
β¨ NAME β¨
okay so this is from the Kernel API Manual, and the manual page is filed under the truncated little handle resctrl_arch...ycles_lat_fn(9). The actual main character is resctrl_arch_measure_cycles_lat_fn β it measures cycle latency to read pseudo-locked memory π
π¦ SYNOPSIS π¦
int resctrl_arch_measure_cycles_lat_fn (void *_plr );
πΈ ARGUMENTS πΈ
_plrβ the pseudo-lock region to measure, bestie. That's the thing we're checking on π
π DESCRIPTION π
ngl, there is no deterministic way to test if a memory region is cached. Like, none. So one way is to measure how long it takes to read the memory β the speed of access is a good way to learn how close to the cpu the data was β¨
Even more iconic: if the prefetcher is disabled and the memory is read at a stride of half the cache line, then a cache miss will be easy to spot, since the read of the first half would be significantly slower than the read of the second half π
β RETURN β
0β waiter on waitqueue will be woken on completion. slay π«
π«Ά SEE ALSO π«Ά
- Kernel file
./arch/x86/kernel/cpu/resctrl/pseudo_lock.c resctrl_arch_get_prefetch_disable_bits(9)resctrl_arch_pseudo_lock_fn(9)
and that's the vibe check, bestie π this cutie lives in the source tree at ./arch/x86/kernel/cpu/resctrl, dated October 2026, and signs off as resctrl_arch...ycles_lat_fn(9) β mwah ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms