This page provides details on a statically defined user application tracing provider for the DTrace facility in Solaris 10 and later releases. This provider instruments various points in the X server, to allow tracing what client applications are up to.
Due to the way User-Defined DTrace probes work, arguments to these probes all bear undistinguished names of arg0, arg1, arg2, etc. These tables should help you determine what the real data is for each of the probe arguments.
| Probe name | Description | arg0 | arg1 | arg2 | arg3 | arg4 |
|---|---|---|---|---|---|---|
| Request Probes | ||||||
| request-start | Called just before processing each client request. | requestName | requestCode | requestLength | clientId | requestBuffer |
| request-done | Called just after processing each client request. | requestName | requestCode | sequenceNumber | clientId | resultCode |
| Event Probes | ||||||
| send-event | Called just before send each event to a client. | clientId | eventCode | eventBuffer | ||
| Client Connection Probes | ||||||
| client-connect | Called when a new connection is opened from a client | clientId | clientFD | |||
| client-auth | Called when client authenticates (normally just after connection opened) | clientId | clientAddr | clientPid | clientZoneId | |
| client-disconnect | Called when a client connection is closed | clientId | ||||
| Resource Allocation Probes | ||||||
| resource-alloc | Called when a new resource (pixmap, gc, colormap, etc.) is allocated | resourceId | resourceTypeId | resourceValue | resourceTypeName | |
| resource-free | Called when a resource is freed | resourceId | resourceTypeId | resourceValue | resourceTypeName | |
To access data in arguments of type string, you will need to use copyinstr(). To access data buffers referenced via uintptr_t's, you will need to use copyin().
| Argument name | type | Description |
|---|---|---|
| clientAddr | string | String representing address client connected from |
| clientFD | int | X server's file descriptor for server side of each connection |
| clientId | int | Unique integer identifier for each connection to the X server |
| clientPid | pid_t | Process id of client, if connection is local (from getpeerucred() ) |
| clientZoneId | zoneid_t | Zone id of client, if connection is local (from getpeerucred() ) |
| eventBuffer | uintptr_t | Pointer to buffer containing X event - decode using structures in <X11/Xproto.h> and similar headers for each extension |
| eventCode | uint8_t | Event number of X event |
| resourceId | uint32_t | X resource id (XID) |
| resourceTypeId | uint32_t | Resource type id |
| resourceTypeName | string | String representing X resource type ("PIXMAP", etc.) |
| resourceValue | uintptr_t | Pointer to data for X resource |
| resultCode | int | Integer code representing result status of request |
| requestBuffer | uintptr_t | Pointer to buffer containing X request - decode using structures in <X11/Xproto.h> and similar headers for each extension |
| requestCode | uint8_t | Request number of X request or Extension |
| requestName | string | Name of X request or Extension |
| requestLength | uint16_t | Length of X request |
| sequenceNumber | uint32_t | Number of X request in in this connection |