What is the "Analyze Wait Chain" in Task Manager?

27

1

In Windows 8's Task Manager under the "Details" tab there is a detailed list of every running process in the system.

In the context menu of every process, there is a new menu item called "Analyze wait chain": awc

What is this wait chain and what does this analysis do?

Vladimir Sinenko

Posted 2012-11-01T12:38:18.583

Reputation: 2 565

Answers

21

This is a special tool to deal with hung and frozen programs. It helps you identify the actual process that caused the freeze:

The analyze wait chain tree shows which processes (root nodes in the tree) are using, or waiting to use, a resource that is being used by another process (child nodes in the tree) and is required for the selected process to continue).

So if you have an unresponsive process, this tool will show you a resource dependency tree and it will highlight the frozen child processes (if any) with red color. By ending the correct ones you might still save your data in the parent process.

See this or this blog posts for a detailed description.

As to the wait chain, see the official API documentation:

A wait chain is an alternating sequence of threads and synchronization objects; each thread waits for the object that follows it, which is owned by the subsequent thread in the chain.

In fact, the Wait Chain Traversal API has been around since Windows Vista. For example, Windows 7's Resource Monitor has already had the same context menu item:

Win7 Resource Monitor

So in Windows 8 it was merely moved to a more convenient location in the Task Manager (copied, to be exact, as Resource Monitor still has it too).

Vladimir Sinenko

Posted 2012-11-01T12:38:18.583

Reputation: 2 565