Xrestop uses the X-Resource extension to provide 'top' like statistics
of each connected X11 client's server side resource usage. It is
intended as a developer tool to aid more efficient server resource
usage and debug server side leakage.

It should work with any server supporting the X-Resource extension,
including the freedesktop.org server and XFree86 4.3+.

"xdpyinfo | grep Resource" should tell you if your server supports
this extension.