The !ks.graph extension command displays a textual description of the kernel mode graph in topologically sorted order.

!ks.graph Object [Level] [Flags] 


Specifies a pointer to the object to use as a starting point for the graph. Must be a pointer to one of the following: file object, IRP, pin, or filter.

Optional. Specifies the level of detail to display on a 0-7 scale with progressively more information displayed for higher values. To display all available details, supply a value of 7. The levels for !ks.graph are the same as those for !ks.dump.

Optional. Specifies the kind of information to be displayed. Flags can be any combination of the following bits.

Bit 0 (0x1)
Display a list of IRPs queued to each pin instance in the graph.

Bit 1 (0x2)
Display a list of IRPs that are pending from each pin instance in the graph. Only IRPs that the pin knows it is waiting for are displayed.

Bit 4 (0x10)
Analyze a stalled graph for suspect filters.


Windows 2000


Windows XP and later


Additional Information

For more information, see Kernel Streaming Debugging.


This command may take a bit of time to process.

Issue a !ks.graph command with no arguments for help.

Here is an example of the !ks.graph display, with the address of a filter object:

kd> !graph 829493c4
Attempting a graph build on 829493c4...  Please be patient...

Graph With Starting Point 829493c4:

"avssamp" Filter 82949350, Child Factories 1
    Output Factory 0 [Video/General Capture]:
        Pin 8293f4f0 (File 82503498) Irps(q/p) = 2, 0

Send comments about this topic to Microsoft