Chapter 7. Visual Studio 2010 Task Debugging Capabilities

WHAT'S IN THIS CHAPTER?

  • Debugging parallelized code running in multiple tasks

  • Taking advantage of multi-monitor support to debug parallelized applications

  • Understanding the Parallel Tasks debugger window

  • Viewing and analyzing the Parallel Stacks diagram

  • Following the concurrent code

  • Debugging anonymous methods

  • Viewing methods

  • Viewing threads in the source code

  • Detecting deadlocks

This chapter is about the new task debugging features introduced in Visual Studio 2010. It describes how the new windows display important information about the tasks and their relationships with the source code and the threads assigned to support their execution. These new windows enable you to detect and solve potential bugs when working with parallelized code in .NET Framework 4, which you'll learn about in this chapter as well.

TAKING ADVANTAGE OF MULTI-MONITOR SUPPORT

Visual Studio 2010 offers many different user interface (UI) elements and windows. Debugging a parallelized application requires more information on the screen than debugging sequential code does. Sometimes, even the resolution offered by Full HD monitors isn't enough to display all the necessary windows at the same time. Figure 7-1 shows the integrated development environment (IDE) of a typical debugging session. It displays information about multiple tasks, their underlying threads, and the code that is being executed. There are too many windows to display all of them on one screen, so it ...

Get Professional Parallel Programming with C#: Master Parallel Extensions With .NET 4 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.