Advanced .NET Debugging by Mario Hewardt | WHSmith Books
Advanced .NET Debugging

Advanced .NET Debugging

By: Mario Hewardt (author)Paperback

Up to 2 WeeksUsually despatched within 2 weeks

£41.79 RRP £43.99  You save £2.20 (5%) With FREE Saver Delivery


"Mario Hewardt's Advanced .NET Debugging is an excellent resource for both beginner and experienced developers working with .NET. The book is also packed with many debugging tips and discussions of CLR internals, which will benefit developers architecting software."-Jeffrey Richter, consultant, trainer, and author at Wintellect "Mario has done it again. His Advanced Windows Debugging (coauthored with Daniel Pravat) is an invaluable resource for native code debugging, and Advanced .NET Debugging achieves the same quality, clarity, and breadth to make it just as invaluable for .NET debugging."-Mark Russinovich, Technical Fellow, Microsoft CorporationThe Only Complete, Practical Guide to Fixing the Toughest .NET Bugs Advanced .NET Debugging is the first focused, pragmatic guide to tracking down today's most complex and challenging .NET application bugs. It is the only book to focus entirely on using powerful native debugging tools, including WinDBG, NTSD, and CDB, to debug .NET applications. Using these tools, author Mario Hewardt explains how to identify the real root causes of problems-far more quickly than you ever could with other debuggers. Hewardt first introduces the key concepts needed to successfully use .NET's native debuggers. Next, he turns to sophisticated debugging techniques, using real-world examples that demonstrate many common C# programming errors. This book enables you toMake practical use of postmortem debugging, including PowerDBG and other "power tools"Understand the debugging details and implications of the new .NET CLR 4.0Master and successfully use Debugging Tools for Windows, as well as SOS, SOSEX, CLR Profiler, and other powerful toolsGain a deeper, more practical understanding of CLR internals, such as examining thread-specific data, managed heap and garbage collector, interoperability layer, and .NET exceptionsSolve difficult synchronization problems, managed heap problems, interoperability problems, and much moreGenerate and successfully analyze crash dumps A companion web site ( contains all sample code, examples, and bonus content.

About Author

Mario Hewardt, senior development lead at Microsoft, has pioneered Windows system-level development for more than a decade. He currently leads a development team that builds ground-breaking online IT management solutions. Hewardt is coauthor of Advanced Windows Debugging (Addison-Wesley, 2008).


Foreword xixPreface xxiAcknowledgments xxxiAbout the Author xxxiii Part I: Overview 1 Chapter 1: Introduction to the Tools 3Debugging Tools for Windows 3.NET 2.0-Redistributable 4.NET 2.0-SDK 5SOS 8SOSEX 10CLR Profiler 11Performance Counters 14Reflector for .NET 15PowerDbg 16Managed Debugging Assistants 18Summary 21 Chapter 2: CLR Fundamentals 23High-Level Overview 23CLR and the Windows Loader 26Application Domains 33Assembly Overview 38Assembly Manifest 39Type Metadata 42Summary 68 Chapter 3: Basic Debugging Tasks 69The Debugger and the Debugger Target 69Symbols 74Controlling Execution 77Loading Managed Code Extensions 85Controlling CLR Debugging 90Setting Breakpoints 90Object Inspection 103Thread Operations 131Code Inspection 143CLR Internals Commands 146Diagnostics Commands 149SOSEX Extension Commands 151Crash Dump Files 163Summary 165 Part II: Applied Debugging 167 Chapter 4: Assembly Loader 169CLR Loader Overview 169Simple Assembly Load Failure 179Load Context Failure 185Interoperability and DllNotFoundException 195Debugging Light Weight Code Generation 197Summary 202 Chapter 5: Managed Heap and Garbage Collection 203Windows Memory Architecture Overview 204Garbage Collector Internals 213Debugging Managed Heap Corruptions 254Debugging Managed Heap Fragmentation 262Debugging Out of Memory Exceptions 272Summary 291 Chapter 6: Synchronization 293Synchronization Basics 293Thread Synchronization Primitives 294Synchronization Internals 306Synchronization Scenarios 316Summary 344 Chapter 7: Interoperability 345Platform Invocation 345COM Interoperability 352Debugging P/Invoke Calls 358Debugging Interop Leaks 373Debugging COM Interop Finalization 378Summary 388 Part III: Advanced Topics 389 Chapter 8: Postmortem Debugging 391Dump File Fundamentals 392Windows Error Reporting 409Summary 438 Chapter 9: Power Tools 439PowerDbg 439Visual Studio 448CLR Profiler 460WinDbg and the CmdTree Command 467Summary 469 Chapter 10: CLR 4.0 471Tools 471Managed Heap and Garbage Collection 472Synchronization 480Interoperability 483Postmortem Debugging 484Summary 485 Index 487

Product Details

  • ISBN13: 9780321578891
  • Format: Paperback
  • Number Of Pages: 552
  • ID: 9780321578891
  • weight: 850
  • ISBN10: 0321578899

Delivery Information

  • Saver Delivery: Yes
  • 1st Class Delivery: Yes
  • Courier Delivery: Yes
  • Store Delivery: Yes

Prices are for internet purchases only. Prices and availability in WHSmith Stores may vary significantly