interesting articles

Analyze Wait Chain - Why is my program stuck?

My new favorite "Nerd" feature in Win7 involves the Resource Monitor (not surprisingly.) It's mesmerizing at times...

Ever had a program get "stuck", where it seems to be quite obviously waiting for something, but you don't know what? Install programs that invoke child processes are notorious for this.

In the Win7 Resource Monitor app, in the Overview or CPU tabs, you'll find the list of running processes. If a process is "stuck", it'll be highlighted with red text. This isn't the cool part though.

You can right click on any process, and in the context menu, you'll see "Analyze Wait Chain...". Click that. In a nutshell, it lists the threads in a process that are blocking on a resource currently owned by another process. Better still, it tells you who the owning process/thread is! With that info, you can take corrective action, such as killing the child process that's not giving up the resource.





---------------------------------------------------------------------------------------------------------------------

My favorite Windows 7 feature so far - Resource Monitor

While the Windows 7 UI is currently getting most of the "What's new?" attention, I'm a system guy at heart. I gravitate towards the tools and features that let me understand what's going on. Why does program 'X' take so long to load? Which of my dozens of services are sucking up the CPU? Which app is pounding on the network connection?

With the Windows 7 Resource Monitor, it's trivial to get answers to these sorts of questions. If you're familiar with SysInternals tools like ProcMon and ProcExp (and if not, you should be!), you know that a wealth of knowledge is available. However, they're still pretty techie for most folks.

In Windows Vista, the Resource Monitor made great strides over prior methods (e.g., perf counters and Task Manager). But the Windows 7 Resource Monitor... all I can say is "Wow!" Left to my own devices, I'd play with it for hours, trying little experiments and watching how they show up...

At the topmost level, Resource Monitor has 4 tabs:

  • Overview (summary of CPU, Memory, Disk, and Network)
  • CPU
  • Memory
  • Disk
  • Network

The overview tab gives the "rolled" up view, similar to the Vista Resource Manager. The remaining tabs drill into more details in their corresponding area. For instance, in the CPU tab, you can see a CPU usage breakdown by service. Likewise, on the Disk tab, you can see a breakdown of disk activity by process. Plus, it's trivial using checkboxes to filter the views to specific processes.

Resource Manager can be found under All Programs | Accessories | System Tools | Resource Monitor, as well as various other shortcuts.

Highly recommended. Check it out!


http://blogs.msdn.com/b/matt_pietrek/archive/2009/01/16/my-favorite-windows-7-feature-so-far-resource-monitor.aspx
------------------------------------------------------------------------------------------------

Inline Redux

by Herb Sutter, describing the inline is performed.
http://www.drdobbs.com/inline-redux/184403879
----------------------------------------------------------------------------------------------------------------------------------




  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值