Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to list call stack of all managed threads using WinDBG?

I have a dump created from a managed application. I am using SOS/SOSEX extentions to ease my dump analysis. I'd like to list down the call stack of all managed threads as we do ~*kb with native applications. How do we do that?

like image 639
sarat Avatar asked Nov 16 '11 10:11

sarat


People also ask

How to see call stack in WinDbg?

As an alternative to the k command, you can view the call stack in the Calls window. To open the Calls window, choose Call Stack from the View menu. The following screen shot shows an example of a Calls window. Buttons in the Calls window enable you to customize the view of the call stack.

What is a call stack thread?

A call stack is a stack data structure that stores information about the active subroutines of a computer program. What you're calling a thread stack is what i assume is the private stack of a thread. These two things are essentially the same. They are both stack data structures .

Which one of these will you use to view thread and stacks?

Threads view shows call stack information for all threads in the app. You can navigate between threads and stack frames on those threads. Tasks view shows task-centered call stack information. In managed code, Tasks view shows call stacks of System.

How do I run a stack trace in Windows?

To open the Call Stack window in Visual Studio, from the Debug menu, choose Windows>Call Stack. To set the local context to a particular row in the stack trace display, select and hold (or double click) the first column of the row.


1 Answers

Use the sos !EEStack command:

0:007> .load sos 0:007> !EEStack 

See SOS.dll (SOS Debugging Extension)

like image 57
Justin Avatar answered Sep 25 '22 05:09

Justin