[RFC] Making tracing/debugging of client requests easier

Alan Coopersmith alan.coopersmith at oracle.com
Fri Jul 2 10:37:16 PDT 2010


Rami Ylimäki wrote:
> I think we want to avoid walking the window tree. It may even be that we
> want to trace some client that doesn't create any windows.
> 
> One thing that I was wondering when investigating this is that why are
> properties restricted to windows? However, the properties seem to be
> implemented in a different manner for different objects in extensions
> like XV (port attributes) and XI2 (device properties).

As far as I know, windows were just the only thing they thought properties
would be useful on during the original protocol design, so they only provided
API & requests for looking up properties by window id.   RandR & Xinput later
extended this to input and output devices, and I think it's reasonable to
consider further extensions as we find uses for them.

I've even wondered if "server properties" make sense - the way xinput properties
have replaced static entries in xorg.conf, there's various serverflags or
commandline options we could expose as server properties.   (Some of these have
ended up as root window properties in the past, though they're really per-server
not  per-screen/root.)

> So I guess that based on your comment it would be best to make XRES
> similar to the other extensions and provide means to set and get client
> properties. In that case we wouldn't use _NET_WM_PID window property but
> would just make it possible to attach some extra data identified by an
> atom to client structures. By default we would then set some
> _LOCAL_CLIENT_PID for the client XID and wouldn't need separate requests
> for querying extra data that we might want to attach to clients in the
> future.

Is XRes the best extension to capture this in?   Would it make more sense
in XFixes?   What properties would we want to expose beyond the connection
info (process id / ip address / etc.) ?   A list of top-level window ids
for each client?   ClientRec in include/dixstruct.h doesn't really suggest
much that's useful to expose to other clients.

-- 
	-Alan Coopersmith-        alan.coopersmith at oracle.com
	 Oracle Solaris Platform Engineering: X Window System



More information about the xorg-devel mailing list