@movq@www.uninformativ.de If I understand it correctly, gtk4 renders using OpenGL. That means some of that RAM that appears to be allocated is actually some trick of the OpenGL driver so that it can map address in RAM space to the GPU’s VRAM (depends a lot on your setup though).
What happens if you run it with GSK_RENDERER=cairo
set?