Microsoft Visual Studio Debugger
Encyclopedia
The Microsoft Visual Studio Debugger is a debugger
Debugger
A debugger or debugging tool is a computer program that is used to test and debug other programs . The code to be examined might alternatively be running on an instruction set simulator , a technique that allows great power in its ability to halt when specific conditions are encountered but which...

 that ships along with all versions of Microsoft Visual Studio
Microsoft Visual Studio
Microsoft Visual Studio is an integrated development environment from Microsoft. It is used to develop console and graphical user interface applications along with Windows Forms applications, web sites, web applications, and web services in both native code together with managed code for all...

. This debugger owes much of its feel and functionality to CodeView
CodeView
CodeView was a standalone debugger created by David Norris at Microsoft in 1985 as part of its development toolset. It originally shipped with Microsoft C 4.0 and later. It also shipped with Visual Basic for MS-DOS, Microsoft Basic PDS, and a number of other Microsoft language products...

, a standalone, text-based debugger that shipped with Microsoft Visual C++
Visual C++
Microsoft Visual C++ is a commercial , integrated development environment product from Microsoft for the C, C++, and C++/CLI programming languages...

 version 1.5 and earlier.

More advanced features of the most recent versions of this debugger include:
  • Full symbol and source integration.
  • Edit and continue support, enabling source code to be modified and recompiled on-the-fly without having to exit the current running program or restart the debugger (32 bit applications only).
  • Remote machine debugging.
  • Attaching and detaching to and from processes (both on the current machine and a remote machine).
  • Integrated debugging across programs written in both .NET and native Windows
    Microsoft Windows
    Microsoft Windows is a series of operating systems produced by Microsoft.Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces . Microsoft Windows came to dominate the world's personal...

     languages (calls from C# to C++
    C++
    C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language. It is regarded as an intermediate-level language, as it comprises a combination of both high-level and low-level language features. It was developed by Bjarne Stroustrup starting in 1979 at Bell...

    , for example).
  • Full support for C++, including templates and the standard library
  • Debugging ASP.NET
    ASP.NET
    ASP.NET is a Web application framework developed and marketed by Microsoft to allow programmers to build dynamic Web sites, Web applications and Web services. It was first released in January 2002 with version 1.0 of the .NET Framework, and is the successor to Microsoft's Active Server Pages ...

     Web Service
    Web service
    A Web service is a method of communication between two electronic devices over the web.The W3C defines a "Web service" as "a software system designed to support interoperable machine-to-machine interaction over a network". It has an interface described in a machine-processable format...

    s.
  • Tracing into DLL code when symbolic debugger information is present.
  • Standard as well as more advanced breakpoint
    Breakpoint
    In software development, a breakpoint is an intentional stopping or pausing place in a program, put in place for debugging purposes. It is also sometimes simply referred to as a pause....

     features, including conditional, address, data breakpoints.
  • Many ways of viewing program state and data, including multiple watch windows, threads
    Thread (computer science)
    In computer science, a thread of execution is the smallest unit of processing that can be scheduled by an operating system. The implementation of threads and processes differs from one operating system to another, but in most cases, a thread is contained inside a process...

    , call stack
    Call stack
    In computer science, a call stack is a stack data structure that stores information about the active subroutines of a computer program. This kind of stack is also known as an execution stack, control stack, run-time stack, or machine stack, and is often shortened to just "the stack"...

    , and modules. The way library and user data types are displayed can be configured (e.g., to show contents of a container class, rather than its raw structure).
  • Scriptability
    Scripting language
    A scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...

     or the ability to control via a macro or scripting language. Any language which can talk to COM
    Component Object Model
    Component Object Model is a binary-interface standard for software componentry introduced by Microsoft in 1993. It is used to enable interprocess communication and dynamic object creation in a large range of programming languages...

     can be used.
  • Local and remote debugging of SQL stored procedures on supported versions of Microsoft SQL Server.


The main shortcoming of the Visual Studio Debugger is its inability to trace into kernel-mode code. However, this is possible using a free VisualDDK extension. Alternatively, kernel-mode debugging of Windows is generally performed by using WinDbg
WinDbg
WinDbg is a multipurposed debugger for Microsoft Windows, distributed on the web by Microsoft. It can be used to debug user mode applications, drivers, and the operating system itself in kernel mode...

, KD, or SoftICE
SoftICE
SoftICE is a kernel mode debugger for Microsoft Windows. Crucially, it is designed to run underneath Windows such that the operating system is unaware of its presence. Unlike an application debugger, SoftICE is capable of suspending all operations in Windows when instructed...

.

The Visual Studio Debugger also has no ability to debug Lambda-Expressions or Linq
LINQ
Linq is a word-based card game from Endless Games, introduced at the American International Toy Fair in 2005.Game play requires at least four players, two of whom are dealt cards with the same word, while the others receive blanks. The goal is to gain points by correctly naming the players with...

. This is because of the high complexity the debugger would grow to. However, most developers working with Lambda expressions are able to visualize the data through the several memory windows.

Edit-and-continue is held by many developers as Microsoft's greatest asset given to developers. A program that is running in memory, that encounters a simple mistake, can be corrected without having to stop the current program or exit the debugger. This feature allows very common mistakes to be corrected easily and with great time savings over other solutions which require exiting the program, making the change, recompiling, and then navigating back through the running program to the previous location, including those available by the GNU Compiler Collection
GNU Compiler Collection
The GNU Compiler Collection is a compiler system produced by the GNU Project supporting various programming languages. GCC is a key component of the GNU toolchain...

 chain and debuggers like GDB and DBX. Still other developers believe that such "sloppy programming techniques" represent a greater philosophical issue related to the mindset of the developer, and should be addressed in other ways such as "teaching them proper coding techniques." This division over belief systems and coding methodology philosophies often causes staunch debate and even moderate hostility between some of the more zealot in both camps.
Debugger Canvas steps through code in the debugger in Visual Studio Ultimate 2010.
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK