Share via


Threads Window

Other versions of this page are also available for the following:

Windows Mobile SupportedWindows Embedded CE Supported

8/27/2008

The Threads window shows the threads, or paths of execution, within the process selected from the Process drop-down list. Using this dialog box, you can:

  • View the thread handle and the handle of the process that created the thread
  • View thread states
  • Display thread priority
  • Display elapsed time used by the thread
  • **

When the Debugger Is Running

The following types of information are displayed in the Threads window when the debugger is running.

Item Description

BasePrio

Base (unadjusted) thread priority.

CurPrio

Current (possibly inversion adjusted) thread priority.

hActvProc

Handle to active process.

hOwnerProc

Handle value of the process which created the thread.

hThread

Handle value associated with the thread.

hVMProc

Handle value of the process that the thread is currently running in (can change on system calls).

InfoStatus

Thread status information.

Item Description
UMode User mode thread (set at thread creation time).
KMode Kernel mode thread (set at thread creation time).
StkFlt Stack overflow exception occurred in the thread.
UsrBlkd Thread is stopped by user action (thread suspend, sleep, sync, etc.)
Profd Thread Profiling (deprecated).

KernelTime

The amount of CPU time spent by the thread in kernel mode.

KernelTime starts from the beginning of the creation of the thread until the current snapshot is taken.

LastError

Pointer to thread's last error value (SetLastError() / GetLastError() values).

PC

Thread's program counter (current instruction memory location).

pThread

Pointer to kernel thread data structure describing the thread.

Quantum

Thread's quantum time (maximum time a thread can run without preemption - in milliseconds).

QuantumLeft

Thread time left before preemption due to quantum expiration (in milliseconds).

RunState

Thread's execution state. See Run State table below.

SleepCount

The system tick count at which a thread should be done sleeping/waiting.

StackBase

End of stack (stack grows to StackBase).

StkLowBnd

Current lower bound of committed stack.

StkRetAddr

Return address on stack.

SuspendCount

Count of how many times a thread has been suspended (SuspendThread API).

ThreadName

The name of the module and initial thread function.

TlsPtr

Pointer to thread's local storage (TLS) area.

UserTime

The amount of CPU time the thread used in user mode.

UserTime starts from the beginning of the creation of the thread until the current snapshot is taken.

WaitState

Thread signal state.

Item Description
Signalled Thread has been signaled by an external event.
Processing An event has occurred or priority changed that might require re-processing the wait state.
Blocked Thread is waiting on an external event.

The following table shows the thread state values.

Run State Value Description

Dying

Thread has been terminated in-flight during a system call, will exit upon return of system call.

Dead

Thread has been terminated, cleanup work is pending.

Buried

Thread has been terminated and all resources cleaned up.

Slpg

Thread is sleeping.

Awak

Thread is not sleeping or blocked.

Rung

Thread is currently running.

Runab

Thread is in runnable state (thread is in run queue and can be scheduled to run when it comes to the front of the queue).

RunBlkd

Thread is blocked.

RunNeeds

Thread is out of block queue, but not yet put in run queue.

Context Menu Options

The following table shows the options in the Context menu:

  • Refresh
    Deletes all entries in the window, allowing only current entries to appear.
  • Log
    Formats and moves all data in this window to the Log tab of the Output window.
  • Expand All
    Displays the callstack information for each thread.
  • Collapse All
    Hides the callstack information for each thread.
  • Open in Call Stack Window
    Opens the Call Stack Window for the selected process and thread.
  • Show Thread Name
    Displays names for threads.

See Also

Reference

Call Stack Window