SlideShare a Scribd company logo
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Release
• 20 Jul 2015
Update 1
• 30 Nov 2015
Update 2
• 30 Mar 2016
Update 3
• TBD
6#
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
BUILD
DEBUG
EDIT
Developer does this #40 times a day
(Linker)
CLEAN BUILD
Product build nightly!
(Compiler)
• VS2015 linker is on average 2x faster when performing a clean link for Non Whole Program Optimized builds.
• VS2015 linker is multi-x faster for new edits now supported by incremental linking.
680
138
84
573
68
61
8
327
KIN E C T S PO R TS R IV AL ( X BO X
O NE )
F O R Z A ( XBO X O NE ) DE S TINY ( XBO X O NE ) C HR O ME
CLEAN LINK TIMES WITH VS2015 (SEC)
VS2013 RTM VS2015 RTM
• /Debug:fastlink
• /Zc:inline
• Incremental linking for
static libraries
• Linker multi-threading
VS2015 introduces…
• Whole Program Optimized (WPO) or LTCG builds perform optimizations
(Inlining, Register Allocation, Value Propagation) across source files and across modules.
• WPO improves runtime performance by low single digits (CPU).
• Minor edits in source code today result in full code generation for WPO builds.
• /ltcg:incremental makes these changes incremental in nature without sacrificing code-quality.
Incredibuild and Visual Studio
• Incredibuild is a software acceleration technology which accelerates Visual Studio, Continuous delivery
and development tool
• Incredibuild and Visual Studio partnership only in 2015 offers the following features as a part of the free SKU.
• A better granular build plan which breaks down false dependencies to maximize build parallelism
• Intelligent resource management
• Visualization tools to understand your build bottle-necks
All in all ~10% improvement in overall build time.
6:32
4:42
0:47
Visual Studio IncrediBuild
(Predicted)
IncrediBuild
(With Helpers*)
• Helper machines are desktop machines containing 2-4 cores each
• Based on Ace open source benchmark
Incredibuild and Visual Studio
“Acquire Incredibuild easily via the File->New, ‘Build Accelerator’ menu’”
faster
void blackscholes(float* input, int *signArray, int n)
{
for (int i = 0; i < n; i++) {
float InputX = input[i];
int sign;
if (InputX < 0.0f) {
InputX = -InputX;
sign = 1;
} else {
sign = 0;
}
input[i] = InputX;
signArray[i] = sign;
}
}
mask = InputX < 0.0f ? 0xFFFFFFFF : 0;
InputX = (mask & -InputX) | (~mask & InputX);
sign = (mask & 1) | (~mask & 0);
Optimized to branch-less code
300%+ speedup in
blackscholes benchmark
Vectorization of control-flow
faster
Vectorization of control-flow
Bit-test merging
faster
Vectorization of control-flow
Bit-test merging
Loop-if unswitching
for (int i = 0; i < 100; i++)
if (some_invariant_condition)
...
Source code:
if (some_invariant_condition)
for (int i = 0; i < 100; i++)
...
Optimized as if:
faster
Vectorization of control-flow
Bit-test merging
Loop-if unswitching
Other code-generation improvements
• Better vectorization of STL constructs (range based for-loops, std::vector)
• Vectorization under /O1 (optimize for size)
• Better codegen of std::min/std::max (200% improvement in runtime)
• Arm32 performance improvements, aggressive scheduler pairing opt,
EH optimizations, whole program type de-virtualization.
• Improve Pre-exec optimizations.
secure
/Guard:cf – new compiler switch
• Protects your instruction stream
• At compile time analyzes control flow for all indirect targets and then inserts code
to verify the targets at runtime.
Learn more about /Guard:cf
secure
/Guard:cf – new compiler switch Learn more about /Guard:cf
Intel®Memory Protection Extensions (MPX) support Learn more about MPX
• New hardware instructions to help mitigate potential buffer overflows (statically and
dynamically allocated buffers).
• Experimental compiler flag /d2MPX to enable automatic MPX code generation.
Intel MPX Enabling Guide
#6
5#
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
std::string s = "nSome reasons this string is hard
to read:nt1. It would go off the screen in your
editornt2. It has sooooo many escape
sequences.nnThey should make a type for this called
"long" string, har har har.nnHave fun parsing
this! (maybe?)n";
std::string s = R"(
Some reasons this string is hard to read:
1. It would go off the screen in your editor
2. It has sooooo many escape sequences.
They should make a type for this called "long" string, har har har.
Have fun parsing this! (maybe?)
)";
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
#6
#5
4#
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
#6
#5
#4
3#
C++17
constexpr Expression SFINAE Two-phase lookup
Variable templates Extended constexpr
NSDMI for aggregates
coroutines modules concepts Nested namespace Folded expressions
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
https://github.com/isocpp/CppCoreGuidelines
Your code will be:
• good modern C++,
• simpler and safer,
• which leads to less resource leaks
and logic errors
https://www.nuget.org/packages/Microsoft.CppCoreCheck https://www.nuget.org/packages/Microsoft.Gsl/
https://github.com/Microsoft/GSL
With Core Checkers
Don't use pointer arithmetic. Use span instead. (bounds.1)
Variable 'n' is uninitialized. Always initialize an object. (type.5)
Don't use pointer arithmetic. Use span instead. (bounds.1)
Don't use pointer arithmetic. Use span instead. (bounds.1)
Don't use pointer arithmetic. Use span instead. (bounds.1)
C26481
C26494
C26481
C26481
C26481
1. void f(int* p, int count)
2. {
3. if (count < 2) return;
4. int* q = p + 1;
5.
6. ptrdiff_t d;
7. int n;
8. d = (p - &n);
9.
10. p[4] = 1;
11. p[count - 1] = 2;
12. use(&p[0], 3);
13.}
14.
15.std::unique_ptr<int[]> a
16. (new int[10]);
17.f(a.get(), 10);
1. void f(int* p, int count)
2. {
3. if (count < 2) return;
4. int* q = p + 1;
5.
6. ptrdiff_t d;
7. int n;
8. d = (p - &n);
9.
10. p[4] = 1;
11. p[count - 1] = 2;
12. use(&p[0], 3);
13.}
14.
15.std::unique_ptr<int[]> a
16. (new int[10]);
17.f(a.get(), 10);
With Core Checkers
C26481
C26494
C26481
C26481
C26481
After (with GSL)
1. void f(gsl::span<int> a)
2. {
3. if (a.length() < 2) return;
4. gsl::span<int> q = a.subspan(1);
5. [[suppress(type.5)]] {
6. ptrdiff_t d;
7. int n;
8. d = (a.data() - &n);
9. }
10. a[4] = 1;
11. a[a.length() - 1] = 2;
12. use(a.data(), 3);
13.}
14.
15.std::unique_ptr<int[]> a
16. (new int[10]);
17.f({ a.get(), 10 });
#6
#5
#4
#3
2#
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
#6
#5
#4
#3
#2
1#
1#
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Description
Build your android application with Gradle build system and easily reference other
android libraries.
Feature Capabilities
• State of the art coding experience with Java and C++
• Powerful debugging for your Java and C++ code
• Gradle Build System
• Ant Build System
• Referencing Android libraries (.aar, .jar) easily in your Android Code.
• Logcat integration
• Fast emulation
• Jump start development with templates and samples
Description
Easily import your Xcode project into Visual Studio and get started with
iOS development within Visual Studio from Windows.
Feature Capabilities
• Import from Xcode, project wizard
• Open in XCode
Learn more about Clang with Microsoft Codegen
#ifdef (specific_compiler_implementation)’
File-> New-> Cross Platform->
#6
#5
#4
#3
#2
#1
0#
http://visualstudio.uservoice.com
http://connect.microsoft.com https://social.msdn.microsoft.com/Forums/en-US/home?forum=vcgeneral
For more info: https://blogs.msdn.microsoft.com/visualstudio/2015/07/30/visual-studio-customer-feedback-channels/
Status User Voice
COMPLETED Include gamma functions in math.h
COMPLETED Single file IntelliSense
COMPLETED Separate ship line of Visual C++ compiler from Visual Studio IDE
COMPLETED Make C/C++ compiler (cl.exe) independent of IDE
COMPLETED Decouple C++ compiler releases from Visual Studio releases
COMPLETED Automate the installation of boost
COMPLETED Fix IntelliSense performance
COMPLETED Working Intellisense in C++
COMPLETED the IntelliSense is slow when "Parsing files in solution" in VS 2015, please speed it up
COMPLETED C++ has the same templates as Visual Basic and C#
COMPLETED Add options to turn off parts of IntelliSense
COMPLETED Bring Visual C++ up to par with open source programs such as Eclipse and Netbeans
COMPLETED One tab for .cpp and .h files
COMPLETED One-button switch between header and implementation file
COMPLETED C++ Edit and Continue in the new debug engine
COMPLETED x64 Edit and Continue for C++
COMPLETED Improve MFC
COMPLETED Add support for binary literals in C++
COMPLETED Provide refactoring for C++
COMPLETED Support C++11 features
COMPLETED Multithreaded C/C++ linker
COMPLETED Do not treat IntelliSense output as errors in Error List
COMPLETED Improve C++ intellisense for pointers
IN PROGRESS Support natvis debug visualizers in Mixed mode debugging
Top 10 contributors
David Majnemer (33)
Bruce Dawson2 (26)
Marcel Raad (23)
Michael Winterberg (18)
Debugini (17)
Kaba_ (15)
bogdan I (12)
Fred J. Tydeman (12)
Trass3r (11)
Niels Dekker (11)
#6
#5
#4
#3
#2
#1
#0
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
http://aka.ms/VDevLabs2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015
Channel 9
Microsoft Virtual Academy
Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015

More Related Content

PPTX
Build 2016 - B835 - Cross-Platform Mobile with Cordova and Ionic Framework
PPTX
Build 2016 - B836 - Cross-Platform Mobile with Xamarin
PDF
Titanium #MDS13
PDF
What's New, Hot, & Awesome for Xamarin Developers!
PPTX
Creating Apps with .NET MAUI
PDF
MS Experiences 17 - Xamarin: Future of Mobile Development
PDF
.NET Everywhere and for Everyone
PDF
Visual Studio 2017 Launch Event
Build 2016 - B835 - Cross-Platform Mobile with Cordova and Ionic Framework
Build 2016 - B836 - Cross-Platform Mobile with Xamarin
Titanium #MDS13
What's New, Hot, & Awesome for Xamarin Developers!
Creating Apps with .NET MAUI
MS Experiences 17 - Xamarin: Future of Mobile Development
.NET Everywhere and for Everyone
Visual Studio 2017 Launch Event

What's hot (20)

PPTX
Migrating .NET Application to .NET Core
PPTX
Choosing The Best Mobile App Framework
PPTX
Cross platform mobile development with xamarin and office 365
PPTX
Ultimate Productivity Tools
PPTX
Introduction to Xamarin
PDF
IVS CTO Night And Day 2018 Winter - AWSマネージドサービスで実現するCICDパイプライン
PDF
NativeScript: Cross-Platform Mobile Apps with JavaScript and Angular
PPTX
Xamarin + GraphQL
PPTX
Seattle Mobile .NET User Group - Nov. 13th 2019
PPTX
Xamarin Dev Days 2016 introduction to xamarin
PPTX
It's just Angular
PPTX
Android Apps Using C# With Visual Studio And Xamarin
PDF
Anton Sakharov: The risks you take when develop cross-platform apps using HT...
PDF
C# Powered Robots, C# Powered Mobile Apps
PPTX
Xamarin - Beyond the Basics
PPTX
Visual studio 2017 - What's New
PPTX
NativeScript + Push Notifications
PPTX
How We Built a Mobile Electronic Health Record App Using Xamarin, Angular, an...
PDF
Xamarin: The Future of App Development
PDF
Alexander Shitikov: Cross Platform Mobile Development. Business Logic for mob...
Migrating .NET Application to .NET Core
Choosing The Best Mobile App Framework
Cross platform mobile development with xamarin and office 365
Ultimate Productivity Tools
Introduction to Xamarin
IVS CTO Night And Day 2018 Winter - AWSマネージドサービスで実現するCICDパイプライン
NativeScript: Cross-Platform Mobile Apps with JavaScript and Angular
Xamarin + GraphQL
Seattle Mobile .NET User Group - Nov. 13th 2019
Xamarin Dev Days 2016 introduction to xamarin
It's just Angular
Android Apps Using C# With Visual Studio And Xamarin
Anton Sakharov: The risks you take when develop cross-platform apps using HT...
C# Powered Robots, C# Powered Mobile Apps
Xamarin - Beyond the Basics
Visual studio 2017 - What's New
NativeScript + Push Notifications
How We Built a Mobile Electronic Health Record App Using Xamarin, Angular, an...
Xamarin: The Future of App Development
Alexander Shitikov: Cross Platform Mobile Development. Business Logic for mob...
Ad

Similar to Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015 (20)

PDF
[Td 2015] what is new in visual c++ 2015 and future directions(ulzii luvsanba...
PDF
Deep Learning Edge
PPT
Overview Of Parallel Development - Ericnel
PDF
(1) c sharp introduction_basics_dot_net
PDF
Speeding up Programs with OpenACC in GCC
PPT
generate IP CORES
PDF
Advanced iOS Build Mechanics, Sebastien Pouliot
PDF
Go native benchmark test su dispositivi x86: java, ndk, ipp e tbb
PDF
Consequences of using the Copy-Paste method in C++ programming and how to dea...
PDF
Use C++ and Intel® Threading Building Blocks (Intel® TBB) for Hardware Progra...
PDF
Beyond Breakpoints: A Tour of Dynamic Analysis
PDF
Craftsmanship in Computational Work
PDF
A Check of the Open-Source Project WinSCP Developed in Embarcadero C++ Builder
PPTX
TypeScript and SharePoint Framework
PDF
High Productivity Web Development Workflow
PDF
High productivity web development workflow - JavaScript Meetup Saigon 2014
PPTX
Moving from Jenkins 1 to 2 declarative pipeline adventures
PPTX
PVS-Studio, a solution for resource intensive applications development
DOCX
20145-5SumII_CSC407_assign1.htmlCSC 407 Computer Systems II.docx
PDF
不深不淺,帶你認識 LLVM (Found LLVM in your life)
[Td 2015] what is new in visual c++ 2015 and future directions(ulzii luvsanba...
Deep Learning Edge
Overview Of Parallel Development - Ericnel
(1) c sharp introduction_basics_dot_net
Speeding up Programs with OpenACC in GCC
generate IP CORES
Advanced iOS Build Mechanics, Sebastien Pouliot
Go native benchmark test su dispositivi x86: java, ndk, ipp e tbb
Consequences of using the Copy-Paste method in C++ programming and how to dea...
Use C++ and Intel® Threading Building Blocks (Intel® TBB) for Hardware Progra...
Beyond Breakpoints: A Tour of Dynamic Analysis
Craftsmanship in Computational Work
A Check of the Open-Source Project WinSCP Developed in Embarcadero C++ Builder
TypeScript and SharePoint Framework
High Productivity Web Development Workflow
High productivity web development workflow - JavaScript Meetup Saigon 2014
Moving from Jenkins 1 to 2 declarative pipeline adventures
PVS-Studio, a solution for resource intensive applications development
20145-5SumII_CSC407_assign1.htmlCSC 407 Computer Systems II.docx
不深不淺,帶你認識 LLVM (Found LLVM in your life)
Ad

More from Windows Developer (20)

PPTX
Our Fluent Path to Spatial Computing: Easy as 1-2D-3D
PPTX
Fluent Design System inside of Microsoft: Office
PPTX
Building powerful desktop and MR applications with new windowing apis
PPTX
Creating Innovative Experiences for Fluent Design using the Visual Layer
PPTX
Rapidly Construct LOB Applications with UWP and Visual Studio 2017
PPTX
Modernizing Desktop Apps on Windows 10
PPTX
How Simplygon helped Remix become platform independent
PPTX
Harnessing the Power of AI with Windows Ink
PPTX
Technical deep dive into creating the “Solutions Showcase for Mixed Reality” ...
PPTX
Developing for Sets on Windows 10
PPTX
Data-Driven and User-Centric: Improving enterprise productivity and engagemen...
PPTX
Drive user reengagement across all your Windows, Android, and iOS with Micros...
PPTX
Fluent Design: Evolving our Design System
PPTX
Seizing the Mixed Reality Revolution – A past, present and future Mixed Reali...
PPTX
Windows 10 on ARM for developers
PPTX
Building Mixed reality with the new capabilities in Unity
PPTX
Set up a windows dev environment that feels like $HOME
PPTX
Modernizing Twitter for Windows as a Progressive Web App
PPTX
Holograms for trade education, built for students, by students with Immersive...
PPTX
Designing Inclusive Experiences to Maximize Reach and Satisfaction
Our Fluent Path to Spatial Computing: Easy as 1-2D-3D
Fluent Design System inside of Microsoft: Office
Building powerful desktop and MR applications with new windowing apis
Creating Innovative Experiences for Fluent Design using the Visual Layer
Rapidly Construct LOB Applications with UWP and Visual Studio 2017
Modernizing Desktop Apps on Windows 10
How Simplygon helped Remix become platform independent
Harnessing the Power of AI with Windows Ink
Technical deep dive into creating the “Solutions Showcase for Mixed Reality” ...
Developing for Sets on Windows 10
Data-Driven and User-Centric: Improving enterprise productivity and engagemen...
Drive user reengagement across all your Windows, Android, and iOS with Micros...
Fluent Design: Evolving our Design System
Seizing the Mixed Reality Revolution – A past, present and future Mixed Reali...
Windows 10 on ARM for developers
Building Mixed reality with the new capabilities in Unity
Set up a windows dev environment that feels like $HOME
Modernizing Twitter for Windows as a Progressive Web App
Holograms for trade education, built for students, by students with Immersive...
Designing Inclusive Experiences to Maximize Reach and Satisfaction

Recently uploaded (20)

PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Encapsulation_ Review paper, used for researhc scholars
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
Big Data Technologies - Introduction.pptx
PDF
Modernizing your data center with Dell and AMD
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Spectral efficient network and resource selection model in 5G networks
PPTX
MYSQL Presentation for SQL database connectivity
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Electronic commerce courselecture one. Pdf
PDF
cuic standard and advanced reporting.pdf
PDF
KodekX | Application Modernization Development
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Network Security Unit 5.pdf for BCA BBA.
Dropbox Q2 2025 Financial Results & Investor Presentation
The AUB Centre for AI in Media Proposal.docx
The Rise and Fall of 3GPP – Time for a Sabbatical?
Encapsulation_ Review paper, used for researhc scholars
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Big Data Technologies - Introduction.pptx
Modernizing your data center with Dell and AMD
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Spectral efficient network and resource selection model in 5G networks
MYSQL Presentation for SQL database connectivity
NewMind AI Weekly Chronicles - August'25 Week I
Electronic commerce courselecture one. Pdf
cuic standard and advanced reporting.pdf
KodekX | Application Modernization Development
Reach Out and Touch Someone: Haptics and Empathic Computing
Advanced methodologies resolving dimensionality complications for autism neur...
“AI and Expert System Decision Support & Business Intelligence Systems”
Chapter 3 Spatial Domain Image Processing.pdf
Digital-Transformation-Roadmap-for-Companies.pptx
Network Security Unit 5.pdf for BCA BBA.

Build 2016 - B880 - Top 6 Reasons to Move Your C++ Code to Visual Studio 2015

  • 4. Release • 20 Jul 2015 Update 1 • 30 Nov 2015 Update 2 • 30 Mar 2016 Update 3 • TBD
  • 5. 6#
  • 7. BUILD DEBUG EDIT Developer does this #40 times a day (Linker) CLEAN BUILD Product build nightly! (Compiler)
  • 8. • VS2015 linker is on average 2x faster when performing a clean link for Non Whole Program Optimized builds. • VS2015 linker is multi-x faster for new edits now supported by incremental linking. 680 138 84 573 68 61 8 327 KIN E C T S PO R TS R IV AL ( X BO X O NE ) F O R Z A ( XBO X O NE ) DE S TINY ( XBO X O NE ) C HR O ME CLEAN LINK TIMES WITH VS2015 (SEC) VS2013 RTM VS2015 RTM • /Debug:fastlink • /Zc:inline • Incremental linking for static libraries • Linker multi-threading VS2015 introduces…
  • 9. • Whole Program Optimized (WPO) or LTCG builds perform optimizations (Inlining, Register Allocation, Value Propagation) across source files and across modules. • WPO improves runtime performance by low single digits (CPU). • Minor edits in source code today result in full code generation for WPO builds. • /ltcg:incremental makes these changes incremental in nature without sacrificing code-quality.
  • 10. Incredibuild and Visual Studio • Incredibuild is a software acceleration technology which accelerates Visual Studio, Continuous delivery and development tool • Incredibuild and Visual Studio partnership only in 2015 offers the following features as a part of the free SKU. • A better granular build plan which breaks down false dependencies to maximize build parallelism • Intelligent resource management • Visualization tools to understand your build bottle-necks All in all ~10% improvement in overall build time. 6:32 4:42 0:47 Visual Studio IncrediBuild (Predicted) IncrediBuild (With Helpers*) • Helper machines are desktop machines containing 2-4 cores each • Based on Ace open source benchmark
  • 11. Incredibuild and Visual Studio “Acquire Incredibuild easily via the File->New, ‘Build Accelerator’ menu’”
  • 12. faster void blackscholes(float* input, int *signArray, int n) { for (int i = 0; i < n; i++) { float InputX = input[i]; int sign; if (InputX < 0.0f) { InputX = -InputX; sign = 1; } else { sign = 0; } input[i] = InputX; signArray[i] = sign; } } mask = InputX < 0.0f ? 0xFFFFFFFF : 0; InputX = (mask & -InputX) | (~mask & InputX); sign = (mask & 1) | (~mask & 0); Optimized to branch-less code 300%+ speedup in blackscholes benchmark Vectorization of control-flow
  • 14. faster Vectorization of control-flow Bit-test merging Loop-if unswitching for (int i = 0; i < 100; i++) if (some_invariant_condition) ... Source code: if (some_invariant_condition) for (int i = 0; i < 100; i++) ... Optimized as if:
  • 15. faster Vectorization of control-flow Bit-test merging Loop-if unswitching Other code-generation improvements • Better vectorization of STL constructs (range based for-loops, std::vector) • Vectorization under /O1 (optimize for size) • Better codegen of std::min/std::max (200% improvement in runtime) • Arm32 performance improvements, aggressive scheduler pairing opt, EH optimizations, whole program type de-virtualization. • Improve Pre-exec optimizations.
  • 16. secure /Guard:cf – new compiler switch • Protects your instruction stream • At compile time analyzes control flow for all indirect targets and then inserts code to verify the targets at runtime. Learn more about /Guard:cf
  • 17. secure /Guard:cf – new compiler switch Learn more about /Guard:cf Intel®Memory Protection Extensions (MPX) support Learn more about MPX • New hardware instructions to help mitigate potential buffer overflows (statically and dynamically allocated buffers). • Experimental compiler flag /d2MPX to enable automatic MPX code generation. Intel MPX Enabling Guide
  • 18. #6
  • 19. 5#
  • 22. std::string s = "nSome reasons this string is hard to read:nt1. It would go off the screen in your editornt2. It has sooooo many escape sequences.nnThey should make a type for this called "long" string, har har har.nnHave fun parsing this! (maybe?)n"; std::string s = R"( Some reasons this string is hard to read: 1. It would go off the screen in your editor 2. It has sooooo many escape sequences. They should make a type for this called "long" string, har har har. Have fun parsing this! (maybe?) )";
  • 25. #6 #5
  • 26. 4#
  • 30. 3#
  • 31. C++17 constexpr Expression SFINAE Two-phase lookup Variable templates Extended constexpr NSDMI for aggregates coroutines modules concepts Nested namespace Folded expressions
  • 33. https://github.com/isocpp/CppCoreGuidelines Your code will be: • good modern C++, • simpler and safer, • which leads to less resource leaks and logic errors
  • 35. With Core Checkers Don't use pointer arithmetic. Use span instead. (bounds.1) Variable 'n' is uninitialized. Always initialize an object. (type.5) Don't use pointer arithmetic. Use span instead. (bounds.1) Don't use pointer arithmetic. Use span instead. (bounds.1) Don't use pointer arithmetic. Use span instead. (bounds.1) C26481 C26494 C26481 C26481 C26481 1. void f(int* p, int count) 2. { 3. if (count < 2) return; 4. int* q = p + 1; 5. 6. ptrdiff_t d; 7. int n; 8. d = (p - &n); 9. 10. p[4] = 1; 11. p[count - 1] = 2; 12. use(&p[0], 3); 13.} 14. 15.std::unique_ptr<int[]> a 16. (new int[10]); 17.f(a.get(), 10);
  • 36. 1. void f(int* p, int count) 2. { 3. if (count < 2) return; 4. int* q = p + 1; 5. 6. ptrdiff_t d; 7. int n; 8. d = (p - &n); 9. 10. p[4] = 1; 11. p[count - 1] = 2; 12. use(&p[0], 3); 13.} 14. 15.std::unique_ptr<int[]> a 16. (new int[10]); 17.f(a.get(), 10); With Core Checkers C26481 C26494 C26481 C26481 C26481 After (with GSL) 1. void f(gsl::span<int> a) 2. { 3. if (a.length() < 2) return; 4. gsl::span<int> q = a.subspan(1); 5. [[suppress(type.5)]] { 6. ptrdiff_t d; 7. int n; 8. d = (a.data() - &n); 9. } 10. a[4] = 1; 11. a[a.length() - 1] = 2; 12. use(a.data(), 3); 13.} 14. 15.std::unique_ptr<int[]> a 16. (new int[10]); 17.f({ a.get(), 10 });
  • 38. 2#
  • 42. 1#
  • 43. 1#
  • 46. Description Build your android application with Gradle build system and easily reference other android libraries. Feature Capabilities • State of the art coding experience with Java and C++ • Powerful debugging for your Java and C++ code • Gradle Build System • Ant Build System • Referencing Android libraries (.aar, .jar) easily in your Android Code. • Logcat integration • Fast emulation • Jump start development with templates and samples
  • 47. Description Easily import your Xcode project into Visual Studio and get started with iOS development within Visual Studio from Windows. Feature Capabilities • Import from Xcode, project wizard • Open in XCode
  • 48. Learn more about Clang with Microsoft Codegen #ifdef (specific_compiler_implementation)’ File-> New-> Cross Platform->
  • 50. 0#
  • 52. Status User Voice COMPLETED Include gamma functions in math.h COMPLETED Single file IntelliSense COMPLETED Separate ship line of Visual C++ compiler from Visual Studio IDE COMPLETED Make C/C++ compiler (cl.exe) independent of IDE COMPLETED Decouple C++ compiler releases from Visual Studio releases COMPLETED Automate the installation of boost COMPLETED Fix IntelliSense performance COMPLETED Working Intellisense in C++ COMPLETED the IntelliSense is slow when "Parsing files in solution" in VS 2015, please speed it up COMPLETED C++ has the same templates as Visual Basic and C# COMPLETED Add options to turn off parts of IntelliSense COMPLETED Bring Visual C++ up to par with open source programs such as Eclipse and Netbeans COMPLETED One tab for .cpp and .h files COMPLETED One-button switch between header and implementation file COMPLETED C++ Edit and Continue in the new debug engine COMPLETED x64 Edit and Continue for C++ COMPLETED Improve MFC COMPLETED Add support for binary literals in C++ COMPLETED Provide refactoring for C++ COMPLETED Support C++11 features COMPLETED Multithreaded C/C++ linker COMPLETED Do not treat IntelliSense output as errors in Error List COMPLETED Improve C++ intellisense for pointers IN PROGRESS Support natvis debug visualizers in Mixed mode debugging
  • 53. Top 10 contributors David Majnemer (33) Bruce Dawson2 (26) Marcel Raad (23) Michael Winterberg (18) Debugini (17) Kaba_ (15) bogdan I (12) Fred J. Tydeman (12) Trass3r (11) Niels Dekker (11)