STRUCT DRM_MEMORY_STATS(9)
π struct drm_memory_stats(9) π
okay so bestie, welcome to the Kernel API Manual β yes we're in kernel land today and honestly? it's giving main character energy. this page is all about struct drm_memory_stats, and no cap, it's the lil glow-up struct that holds your GEM object stats β¨
πΈ NAME πΈ
struct drm_memory_stats β GEM object stats, all associated and cozy together π«Ά
β¨ SYNOPSIS β¨
like, here's the whole vibe, literally verbatim:
struct drm_memory_stats {
u64 shared;
u64 private;
u64 resident;
u64 purgeable;
u64 active;
};
that's it. five u64s and a dream π
π Members π
sharedβ the total size of GEM objects that are shared between processes. it's giving collaborative. it's giving "we're all in this together" π€privateβ the total size of GEM objects. periodt. just... all of them πresidentβ the total size of GEM objects backing pages. they're literally there, living rent-free πpurgeableβ the total size of GEM objects that can be purged. and iykyk: "purgeable" here means resident and not active. both conditions, bestie, no skipping πactiveβ the total size of GEM objects that are active on one or more engines. go go go π₯
π¦ Description π¦
okay so this whole struct is used by drm_print_memory_stats. that's the whole description. short, sweet, iconic π
π SEE ALSO π
the kernel file ./include/drm/drm_file.h β which is where all these besties live β plus:
struct drm_minor(9)struct drm_pending_event(9)struct drm_file(9)drm_is_primary_client(9)drm_is_render_client(9)drm_is_accel_client(9)
reminder bestie: this is straight from the source, no invented lore, no extra tips dressed up as facts. everything above is exactly what the page says, just cuter π
and that's a wrap, angel! π this little masterpiece is from ./include/drm, dated October 2026, and it's struct drm_memory_stats(9) forever and always. 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