$ wget https://movq.de/v/138ab3e622/win.c
$ cc -Wall -Wextra -o win win.c $(pkg-config --cflags --libs gtk4)
$ ./win
It also takes several seconds to start on my machine because it is compiling shaders and initializing DRI (it’s faster on the second run, unless you happen to lose
~/.cache/mesa_shader_cache/
). This might be a hint as to why it’s using so much memory: There’s obviously much more going on behind the scenes these days, not just a little bit of internal housekeeping and then creating a window.