Visual Studio 2022 – 17.5 Performance Enhancements
We are excited to announce that Visual Studio 2022 17.5 offers a range of performance enhancements that significantly improve the speed and responsiveness of the product in the following main areas:
- Build Acceleration for .NET SDK style projects
- External Sources Decompilation
- Thread Window
- Razor & C# experience
- Quick Add Item
- Code Coverage
Build Acceleration for .NET SDK style projects are an opt-in feature that directs Visual Studio to only build projects that had modifications while skipping projects that were unchanged. Enabling Build Acceleration can reduce incremental build times by up to 80% for SDK-style .NET projects.
For further details and instructions on enabling/disabling Build Acceleration, please visit the link.
External Sources De-compilation
You’ll also find de-compiling large modules in 17.5 is up to 10 times faster! Decompiling .NET libraries on a call stack demonstrates that it is now possible to de-compile multiple modules in less time than it took to de-compile a single module in version 17.4. These improvements would likely make debugging and troubleshooting issues more efficient.
The performance of the threads window has been vastly improved in 17.5! The response time of the window now scales very well when debugging applications with large number of threads. This animation demonstrates the speed of 17.5 compared to 17.4 when debugging an application with around 200 threads.
Quick Add Item
17.5 introduces a faster way to add files and folders to your solution! The “New Item” menu command (Or Ctrl+Shift+A shortcut) brings up a compact dialog where you provide the name and extension of the file you want to add, and a file with matching template will get added to your project. Compared to the dialog that shows all templates, the compact dialog is much faster and lets you get the job done with fewer gestures. The new dialog also allows multiple files and folders to be created with a single invocation of the dialog, giving a further boost to developer productivity!
You can learn more about the quick Add Item experience by watching a short video.
Razor & C# Experience
To address the feedback about productivity and performance surrounding Razor we’ve added support for code actions in Razor files, including some helpful shortcuts like “Remove Tag,” “Encode image in Base64,” and “Insert Image height/width.”
We have made significant improvement to the performance of dynamic code coverage by addressing an issue related to inlining. Our investigation showed that dynamic instrumentation was globally disabling inlining. For instance, running coverage tests on the Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests project in Roslyn executes over 1 million code blocks while only around 400,000 blocks are instrumented to test code coverage. To optimize this, we now enable inlining when neither the caller nor the callee are under code coverage. This change has led to a significant boost in the speed of dynamic code coverage. Code coverage tests on the Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests project in Roslyn run over 35% faster in 17.5!
Tell us what you think!
We hope these performance enhancements make your development work efficient and enjoyable. Feedback from developers like you is very important for us to improve the product and meet your expectations. We welcome your feedback on Visual studio performance. The preferred approach is using the Report-a-problem tool. You can also leave comments below.