Debugging Application For Microsoft Dot Net And Microsoft Windows
作者:John Robbins出版社:微软
出版日期:2003
简介:
This book brings a vast amount of Windows-specific debugginginformation together in one place and has been very helpful to me. Someof this info could be found elsewhere, but only by sorting throughdozens of documentation pages and magazine articles, some many yearsold, and additionally the author adds value by giving very explicitinstructions (even providing source code) on how to do things that areoften only hinted at in the Microsoft documentation.
Most useful to me were the symbol-server tips, the SuperAssertmacro and seeing how it does it what it does, crash handling ingeneral, and the author's insight into why certain things are so slow(like OutputDebugString).
This book does have a not-so-subtle anti-C++ bias, there are littledigs at C++ coding techniques throughout the book, which seem a littleantiquated and inappropriate in 2005.
In the chapter on the debug C-runtime, I'm really surprised theauthor does not suggest writing a leak-detection system that capturesthe callstack at the time of allocation, I've found the C-runtime'sfile-and-line-oriented leak report fairly useless since the allocationis often deep inside some container class, you really need to know whatcode caused the allocation, not what code actually did the allocation.And the recommended feature that walks the entire heap every Nallocations is unusable (it's too slow) in a large C++ program whichmight have many thousands of allocations. Also, redefining C++ keywordsas suggested seems so evil, there are better ways of doing this.
I believe Windows XP Service Pack 2 changed some Windows internalsthat affect crash handling/debugging/stack walking, I wouldn't mindseeing an updated volume that covers these changes in detail.
Overall though, an excellent book, the most useful debugging book I've found so far.
下载