You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
title: "View Disassembly Code in the Debugger in Visual Studio | Microsoft Docs"
3
3
ms.custom: "H1Hack27Feb2017"
4
-
ms.date: "11/04/2016"
4
+
ms.date: "10/29/2018"
5
5
ms.technology: "vs-ide-debug"
6
6
ms.topic: "conceptual"
7
7
f1_keywords:
@@ -24,46 +24,47 @@ manager: douge
24
24
ms.workload:
25
25
- "multiple"
26
26
---
27
-
# View Disassembly Code in the Visual Studio Debugger
28
-
This feature is available only if address-level debugging is enabled the **Options** dialog box, **Debugging** node. It is not available for Script or SQL debugging.
27
+
# View disassembly code in the Visual Studio debugger
28
+
This feature is only available if address-level debugging is enabled in the **Options** dialog box, **Debugging** node. It isn't available for Script or SQL debugging.
29
29
30
-
The **Disassembly** window shows assembly code corresponding to the instructions created by the compiler. If you are debugging managed code, these assembly instructions correspond to the native code created by the Just-in-Time (JIT) compiler, not the Microsoft intermediate language (MSIL) generated by the Visual Studio compiler.
30
+
The **Disassembly** window shows assembly code corresponding to the instructions created by the compiler. If you're debugging managed code, these assembly instructions correspond to the native code created by the Just-in-Time (JIT) compiler, not the Microsoft intermediate language (MSIL) created by the Visual Studio compiler.
31
+
32
+
> [!NOTE]
33
+
> To take full advantage of the **Disassembly** window, you'll need to understand the basics of assembly-language programming, which is beyond the scope of this article.
31
34
32
-
In addition to assembly instructions, the **Disassembly** window can show the following optional information:
35
+
In addition to assembly instructions, the **Disassembly** window can show the following optional information:
33
36
34
-
- Memory address where each instruction is located. For native applications, this is the actual memory address. For Visual Basic, C#, or managed code, it is an offset from the beginning of the function.
37
+
- Memory address where each instruction is located. For native applications, it is the actual memory address. For Visual Basic, C#, or managed code, it's an offset from the beginning of the function.
35
38
36
39
- Source code from which the assembly code derives.
37
40
38
-
- Code bytes—byte representations of the actual machine or MSIL instructions.
41
+
- Code bytes, that is, the byte representations of the actual machine or MSIL instructions.
39
42
40
43
- Symbol names for the memory addresses.
41
44
42
45
- Line numbers corresponding to the source code.
43
46
44
-
Assembly-language instructions consist of mnemonics, which are abbreviations for instruction names, and symbols that represent variables, registers, and constants. Each machine-language instruction is represented by one assembly-language mnemonic, usually followed by one or more variables, registers, or constants.
45
-
46
-
If you cannot read assembly language and want to take full advantage of the Disassembly window, consult a good book on assembly-language programming. Assembly-language programming is beyond the scope of what we can address in this brief introduction to the Disassembly window.
47
+
Assembly-language instructions consist of *mnemonics*, which are abbreviations for instruction names, and *symbols* for variables, registers, and constants. Each machine-language instruction is represented by one assembly-language mnemonic optionally followed by one or more symbols.
47
48
48
-
Because assembly code relies heavily on processor registers or, in the case of managed code, common language runtime registers, you will often find it useful to use the Disassembly window in conjunction with the Registers window, which allows you to examine register contents.
49
+
Assembly code relies heavily on processor registers or, for managed code, common language runtime registers. You can use the **Disassembly** window along with the **Registers** window, which allows you to examine register contents.
49
50
50
-
You probably will never have the desire or need to view machine-code instructions in their raw, numeric form, rather than assembly language. However, if you want to do so, you can use the Memory window for that purpose or choose Code Bytes from the shortcut menu in the Disassembly window.
51
+
To view machine-code instructions in their raw numeric form, rather than as assembly language, use the **Memory** window or select **Code Bytes** from the shortcut menu in the **Disassembly** window.
51
52
52
53
> [!NOTE]
53
54
> The dialog boxes and menu commands you see might differ from those described in Help depending on your active settings or edition. To change your settings, choose **Import and Export Settings** on the **Tools** menu. For more information, see [Personalize the Visual Studio IDE](../ide/personalizing-the-visual-studio-ide.md).
54
55
55
56
### To display the Disassembly window
56
57
57
-
- While you are debugging, select **Debug > Windows** and then click**Disassembly**.
58
+
- While you're debugging, select **Debug** > **Windows** and then select**Disassembly**.
58
59
59
60
### To turn optional information on or off
60
61
61
-
- Right-click the **Disassembly** window, and set or clear the desired options in the shortcut menu.
62
+
- Right-click in the **Disassembly** window, and set or clear the desired options in the shortcut menu.
62
63
63
-
A yellow arrow in the left margin marks the location of the current execution point. For native code, this corresponds to the CPU's program counter. This location shows the next instruction that will be executed in your program.
64
+
A yellow arrow in the left margin marks the location of the current execution point. For native code, the execution point corresponds to the CPU's program counter. This location shows the next instruction that will be executed in your program.
64
65
65
-
For more information, see [Paging Up or Down in Memory](../debugger/how-to-page-up-or-down-in-memory.md).
66
+
For more information, see [Paging up or down in memory](../debugger/how-to-page-up-or-down-in-memory.md).
66
67
67
-
## See Also
68
-
[Viewing Data in the Debugger](../debugger/viewing-data-in-the-debugger.md)
69
-
[How to: Use the Registers Window](../debugger/how-to-use-the-registers-window.md)
68
+
## See also
69
+
[Viewing data in the debugger](../debugger/viewing-data-in-the-debugger.md)
70
+
[How to: Use the Registers window](../debugger/how-to-use-the-registers-window.md)
0 commit comments