First page Last page Overview Graphics

Dynamic tracing of the X server

  • }

    Notes:

    This can be rewrittenslightly to cache the string containing the name of the request since it will be reused many times, and copying it over and over from the kernel:

    #!/usr/sbin/dtrace -s

    string Xrequest[uintptr_t];

    Xserver*:::request-start
    /Xrequest[arg0] == ""/
    {
    Xrequest[arg0] = copyinstr(arg0);
    }

    Xserver*:::request-start
    {
    @counts[Xrequest[arg0]] = count();
    }