precompute_cache_shard_ids(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– NAME πŸ’–

okay so bestie, you're looking at precompute_cache_shard_ids(9) from the Kernel API Manual, section 9 ✨. Its whole mission? Assign each CPU its shard index within its LLC. That's it. That's the assignment. periodt. πŸ’…

✨ SYNOPSIS ✨

void precompute_cache_shard_ids (void );

🫢 ARGUMENTS 🫢

  • void β€” no arguments. literally zero. not even one tiny parameter. πŸ’€

🌸 DESCRIPTION 🌸

Here's the whole plot, bestie: precompute_cache_shard_ids iterates over all LLC pods. For each pod, it counts distinct cores, then assigns shard indices to all CPUs in the pod. That's the vibe. πŸ¦‹

⚠️ Important caveat, no cap: it must be called after WQ_AFFN_CACHE and WQ_AFFN_SMT have been initialized. So do that first, okay? πŸ’…

πŸ‘‘ SEE ALSO πŸ‘‘

Kernel file ./kernel/workqueue.c β€” and the whole friend group is:

xoxo, from ./kernel β€’ dated October 2026 β€’ precompute_cache_shard_ids(9) πŸ’–

πŸ“¦ where this page comes from