Visual Studio Code C++ July 2021 Update: Disassembly View, Macro Expansion and Windows ARM64 Debugging

Julia Reid

The July 2021 update of the C++ extension for Visual Studio Code is here, bringing you brand new features— such as a Disassembly View while debugging, inline macro expansions, and debug support for Windows ARM64 architecture—along with a bunch of enhancements and bug fixes. To find out more about all the enhancements, check out our release notes on GitHub.

Disassembly View

We’re excited to announce that Disassembly View— our #1 upvoted GitHub issue (#206)— is publicly available in VS Code Insiders! Disassembly View allows you to debug assembly code corresponding to the instructions created by your compiler. It’ll be available in the 1.59 release of Visual Studio Code in August, but in the meantime you can download VS Code Insiders and try it out!

To open Disassembly View while debugging, right click your source code and select Open Disassembly View.

Image showing the right-click menu option to Open Disassembly View

In the Disassembly View, the yellow hollow marker represents the current instruction. For each instruction, you’ll see the memory address (left column) and the machine language instructions displayed as hex (middle column) and as assembly language (right column). You can navigate between instructions, step over (F10) and step in to (F11) instructions.

Image showing the Disassembly View opened side by side with source code

To set a breakpoint in the Disassembly View, hover over the instruction and click the red filled circle that appears to the left of the memory address.

Image showing the red filled circle that appears on hover to set a breakpoint at an instruction in Disassembly View

Unset the breakpoint by clicking the red dot again, or by unchecking the box in the Breakpoints section of the Debug pane.

Image showing the Breakpoints section of the Debug pane, where users can enable and disable breakpoints

Check out this GIF to see Disassembly View in action:

GIF showing how to open Disassembly View while debugging, navigate between instructions and set breakpoints

Macro Expansion

With this latest release of the C++ extension, you can expand macros inline (GitHub issue #4183), making it easier to read and understand your code. To expand a macro inline, click on it, select the lightbulb, and then click Inline macro.

GIF showing how to expand a macro inline

Windows ARM64 Debugging

Last year, we announced support for running the C++ extension on Windows ARM64 architecture, giving Surface Pro X users access to C++ IntelliSense, code navigation, and build support. With the July 2021 update of the C++ extension, you can debug projects on Windows ARM64, completing the end-to-end Surface Pro X C++ development experience in VS Code.

What do you think?

Download the C++ extension for Visual Studio Code today, give it a try, and let us know what you think. If you run into any issues, or have any suggestions, please report them in the Issues section of our GitHub repository. You can also join our Insiders program and get access to early builds of our release by going to File > Preferences > Settings and under Extensions > C/C++, change the “C_Cpp: Update Channel” to “Insiders.” Then under Features > Extensions, enable “Extensions: Auto Update.”

We can be reached via the comments below or in email at visualcpp@microsoft.com. You can also find our team on Twitter at @VisualC.