Presentation is loading. Please wait.

Presentation is loading. Please wait.

4/13/2018 10:02 AM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN.

Similar presentations


Presentation on theme: "4/13/2018 10:02 AM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN."— Presentation transcript:

1 4/13/ :02 AM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

2 reasons to move your C++ code to Visual Studio
4/13/ :02 AM B8105 7 reasons to move your C++ code to Visual Studio 2017 Marian Luparu @mluparu @visualc © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

3 7 2017 One IDE to: #1 write modern, portable C++
4/13/ :02 AM One IDE to: #1 write modern, portable C++ #2 upgrade to, pain-free #3 run faster #4 make you more productive #5 bring your non-MSVC sources to (via Open Folder) #6 target multiple platforms #7 streamline your installation reasons you will love Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

4 Visual Studio 2017 Community Professional Enterprise
Microsoft Build 2017 4/13/ :02 AM Visual Studio Community Professional Enterprise RC 16 Nov 2016 Release 7 Mar 2017 2017.1 5 Apr 2017 2017.2 Available Now 2017.3 Preview 1 Available Now © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

5 7 #1 modern, portable C++ 2017 Visual Studio
4/13/ :02 AM #1 modern, portable C++ reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

6 C++ Conformance C++17 … … C++11 C++14 C++TS
Updated or Completed in VS2015 wave Updated or Completed in VS2015 wave C++ Conformance Updated or Completed in VS2017 RTM Updated or Completed in VS2017 RTM Coming soon in VS Update C++11 Two-phase Name Lookup under /permissive- (partial support) default/deleted func, Inline namespaces, User-defined literals, noexcept, char16_t/char32_t, alignas/alignof, __func__, Extended sizeof, Inheriting constructors, Unicode string literals, Magic statics, thread_local, Unrestricted unions, Attributes, Universal char names in literals, Data-dep ordering attributes, constexpr Expression SFINAE (via Boost) STL: All C++11 Features C++14 Expression SFINAE (via more libraries) auto, decltype(auto) return types, Generic lambdas, Generalized lambda captures, Binary literals, Sized Deallocators, Deprecated attribute, Digit separator, Variable Templates NSDMI for Aggregates Extended Constexpr STL: All C++14 Features Auto with braced-init list, u8 char literal, Attributes on namespace and enum, Removing trigraphs, typename in template template-param, Nested Namespace, Ignoring unrecognized attributes Terse static_assert Attribute [[fallthrough]] C++17 Generalized range-based for-loops STL:<any> STL:<optional> STL:<string_view> STL:<variant> STL:<algorithm> sample() STL:<tuple> apply() Structured Bindings Selection statements with initializers Construction rules for enum class values Guaranteed copy elision __has_include Register keyword Capturing *this by value Using attribute namespaces without repetition Constexpr lambdas C++TS [[maybe_unused]] [[nodiscard]] Removing operator++ for bool if constexpr STL:<string_view> UDLs Filesystem (experim.) C++ Coroutines C++ Modules (experimental) C++ Concepts (experimental)

7 std::optional<T>
Microsoft Build 2017 4/13/ :02 AM std::optional<T> bool reduce(Item it, /*in, opt*/ Item* subitem, /*out*/ CachedItem* ret) { CachedItem* retVal; if (download(it, retVal)) { if (subitem != nullptr) { CachedItem* subItemRet; if (download(*subitem, subItemRet)) { retVal->addSubitem(*subItemRet); } else return false; return true; return false; Item i(...), j(...); CachedItem* ret = nullptr; if (reduce(i, &j, ret)) { cout << ret->name << endl; After optional<CachedItem> reduce(Item it, optional<Item> subitem) { CachedItem* retVal; if (download(it, retVal)) { if (subitem) { CachedItem* subItemRet; if (download(*subitem, subItemRet)) { retVal->addSubitem(*subItemRet); } else return nullopt; return *retVal; return nullopt; Item i(...), j(...); auto ret = reduce(i, j); if (ret) { cout << ret->name << endl; Before © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

8 std::optional<T>
Microsoft Build 2017 4/13/ :02 AM std::optional<T> Before bool reduce(Item it, /*in, opt*/ Item* subitem, /*out*/ CachedItem* ret) { CachedItem* retVal; if (download(it, retVal)) { if (subitem != nullptr) { CachedItem* subItemRet; if (download(*subitem, subItemRet)) { retVal->addSubitem(*subItemRet); } else return false; return true; return false; Item i(...), j(...); CachedItem* ret = nullptr; if (reduce(i, &j, ret)) { cout << ret->name << endl; After optional<CachedItem> reduce(Item it, optional<Item> subitem = nullopt) { CachedItem* retVal; if (download(it, retVal)) { if (subitem) { CachedItem* subItemRet; if (download(*subitem, subItemRet)) { retVal->addSubitem(*subItemRet); } else return nullopt; return *retVal; return nullopt; Item i(...), j(...); auto ret = reduce(i, j); if (ret) { cout << ret->name << endl; auto ret2 = reduce(i); © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

9 C++ Conformance C++17 … … C++11 C++14 C++TS
Updated or Completed in VS2015 wave Updated or Completed in VS2015 wave C++ Conformance Updated or Completed in VS2017 RTM Updated or Completed in VS2017 RTM Coming soon in VS Update C++11 Two-phase Name Lookup under /permissive- (partial support) default/deleted func, Inline namespaces, User-defined literals, noexcept, char16_t/char32_t, alignas/alignof, __func__, Extended sizeof, Inheriting constructors, Unicode string literals, Magic statics, thread_local, Unrestricted unions, Attributes, Universal char names in literals, Data-dep ordering attributes, constexpr Expression SFINAE (via Boost) STL: All C++11 Features C++14 Expression SFINAE (via more libraries) auto, decltype(auto) return types, Generic lambdas, Generalized lambda captures, Binary literals, Sized Deallocators, Deprecated attribute, Digit separator, Variable Templates NSDMI for Aggregates Extended Constexpr STL: All C++14 Features Auto with braced-init list, u8 char literal, Attributes on namespace and enum, Removing trigraphs, typename in template template-param, Nested Namespace, Ignoring unrecognized attributes Terse static_assert Attribute [[fallthrough]] C++17 Generalized range-based for-loops STL:<any> STL:<optional> STL:<string_view> STL:<variant> STL:<algorithm> sample() STL:<tuple> apply() Structured Bindings Selection statements with initializers Construction rules for enum class values Guaranteed copy elision __has_include Register keyword Capturing *this by value Using attribute namespaces without repetition Constexpr lambdas C++TS [[maybe_unused]] [[nodiscard]] Removing operator++ for bool if constexpr STL:<string_view> UDLs Filesystem (experim.) C++ Coroutines C++ Modules (experimental) C++ Concepts (experimental)

10 Need help adopting the C++ Core Guidelines?
Microsoft Build 2017 4/13/ :02 AM Need help adopting the C++ Core Guidelines? C++ Core Checkers (part of C++ Code Analysis) Bounds checks Type checks Const checks Resource management checks Guidelines Support Library span<T> not_null<T> owner<T>, and more Install GSL from: Source code: © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

11 7 #2 pain-free upgrades 2017 Visual Studio
4/13/ :02 AM #2 pain-free upgrades reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

12 Pain-free upgrade Microsoft Build 2016 4/13/2018 10:02 AM
© 2016 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

13 Pain-Free Upgrade You can get the VS2015 toolset with VS2017 (without needing the VS2015 IDE) Binary compatibility between the VS2015 and VS2017 runtimes Vcpkg: Open source tool based on a port tree approach vcpkg install boost And 220+ libraries more Installs the .h, .lib and binaries in a “lib folder” including dependencies works with VS2017 2015 binaries are compatible with 2017 (no need to rebuild)

14 Developer Inner Loop Read & Edit Diagnose Commit Compile Test
Microsoft Build 2016 4/13/ :02 AM Developer Inner Loop Read & Edit Create and update your code Diagnose Fix and optimize your code Commit Share your code Compile Build your code Test Validate your code © 2016 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

15 7 #3 performance 2017 Visual Studio reasons to move your C++ code to
4/13/ :02 AM #3 performance reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

16 Performance Auto-precompiled headers for IntelliSense perf (when no PCH) Memory usage during debugging significantly decreased E.g. debugging a specific problematic project down to 1.9G from… crashing Faster builds /debug:fastlink on by default, 30% link time improvements Solution load dramatic improvements Chromium Solution Items VS 2015 Update 3 VS 2017 Improvement Time - First Solution Open (s) 1,213 182 6.6x Time – Subsequent Solution Open (s) 1,211 68 17.8x Private Working Set (MB) 2,293 804 2.8x Virtual Memory (MB) 3,066 1,302 2.3x aka.ms/vcperf

17 7 #4 productivity 2017 Visual Studio reasons to move your C++ code to
4/13/ :02 AM #4 productivity reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

18 Demo Microsoft Build 2017 4/13/2018 10:02 AM
© Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

19 Unit Testing Announcing support for new frameworks!
Microsoft Build 2017 4/13/ :02 AM Compile Test Diagnose Read & Edit Commit Unit Testing Announcing support for new frameworks! Supported Frameworks: MSTest Google Test (available now in Marketplace!) Built with GTest Adapter extension (by Christian Soltenborn and Jonas Gefele) Boost.Test (coming soon!) Manage tests from Test Explorer Check code coverage right in the IDE Create test projects or unit testing files easily © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

20 C++ Productivity Read & Edit
Microsoft Build 2017 4/13/ :02 AM Compile Test Diagnose Read & Edit Commit C++ Productivity Read & Edit New filters + Predictive IntelliSense mode Go To (ctrl + ,) with various filters Find All References improvements Code formatting enforcement (via. .editorconfig) Compile /debug:fastlink 30% improvements OSS libs from Test New Unit Test Frameworks Google Test (available now) Boost.Test (coming soon) Diagnose Improved: Error List results Memory and CPU profiler Debugging Run to Click Reattach to process Exception helper Break-on-exception conditions Compiler diagnostics via /diagnostics:caret Commit Force push your changes SSH support for remotes View Commit Diff © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

21 7 #5 open folder 2017 Visual Studio reasons to move your C++ code to
4/13/ :02 AM #5 open folder reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

22 Open Folder: CMake, etc Ideal for non-MSBuild projects
Microsoft Build 2017 4/13/ :02 AM Open Folder: CMake, etc Ideal for non-MSBuild projects e.g. any project using CMake, make or other C++ build systems Easy to get started devenv.exe <directory> or “File > Open > Folder…” (Ctrl+Alt+Shift+O) Read & edit All C++ navigation and IntelliSense features Build & Debug Flexible integration of external build processes Familiar Visual Studio debugging experience © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

23 Demo Microsoft Build 2017 4/13/2018 10:02 AM
© Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

24 #6 cross-platform development
4/13/ :02 AM #6 cross-platform development reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

25 Android C++ Development
Microsoft Build 2017 4/13/ :02 AM Android C++ Development © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

26 iOS C++ Development Microsoft Build 2017 4/13/2018 10:02 AM
© Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

27 Microsoft Build 2017 4/13/ :02 AM Linux C++ Development C/C++ Linux Development workload now part of VS installer Target any Linux distro with SSH, gdbserver and compiler. Use the full power of the Visual Studio debugger as you would expect with your C/C++ Linux development Debug live using attach to process to your Linux machine IntelliSense & Code browsing out of the box for GCC and stdlibc++ easily extended by importing your own headers. Bring your existing build processes with the makefile project support © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

28 Demo Microsoft Build 2017 4/13/2018 10:02 AM
© Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

29 7 2017 One IDE to: #1 write modern, portable C++
4/13/ :02 AM One IDE to: #1 write modern, portable C++ #2 upgrade to, pain-free #3 run faster #4 make you more productive #5 bring your non-MSVC sources to (via Open Folder) #6 target multiple platforms reasons you will love Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

30 #7 streamlined installation
reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

31 Desktop development with C++ Universal Windows Platform development
Microsoft Build 2016 4/13/ :02 AM Desktop development with C++ Universal Windows Platform development Mobile development with C++ Game development with C++ Linux development with C++ aka.ms/vcinstaller © 2016 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

32 7 #7++ you helped build it 2017 Visual Studio
4/13/ :02 AM #7++ you helped build it reasons to move your C++ code to Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

33 You helped us build it! Visual Studio User Voice
“Report a problem” tool

34 987 You helped us build it! 1546 Visual Studio User Voice
“Report a problem” tool 1546 Votes on UserVoice 987 fixed bugs publicly reported through Connect & IDE

35 7 2017 #1 modern, portable C++ #2 pain-free upgrades #3 performance
4/13/ :02 AM #1 modern, portable C++ #2 pain-free upgrades #3 performance #4 productivity #5 open folder #6 cross-platform development #7 streamlined installation #7++ you helped build it reasons you will love Visual Studio 7 2017 © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

36 Take our C++ survey https://aka.ms/cppbuild2017survey
Microsoft Build 2017 4/13/ :02 AM Take our C++ survey Stop by our Expo booth to Talk with the C++ team, Get a “Visual C++” t-shirt (while supplies last) © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

37 Related sesions B8083 – The Future of Visual Studio (Amanda Silver)
Microsoft Build 2017 4/13/ :02 AM Related sesions B8083 – The Future of Visual Studio (Amanda Silver) T Linux C++ development with Visual Studio 2017 (Marc Goodner) P From pre-compiled headers to incremental whole program optimization: saving mankind through improving the compile time of native code (Eric Brumer) Quick Start - Create a basic Universal Windows Platform (UWP) app in C++ © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

38 4/13/ :02 AM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

39 Two-phase name lookup namespace doc {
Microsoft Build 2017 4/13/ :02 AM Two-phase name lookup namespace doc { template<typename> auto tcp_connect() { parameters: awaitable => "stores the awaitable state", req(output) => "the object to write the request", socket => "the TCP socket used to connect", dest => "the address to connect to" return: "future<int> that you should co_await" promise: "0 on success; <= 0 on failure" } auto& tcp_connect( awaitable_state<int>& awaitable, uv_connect_t* req, uv_tcp_t* socket, const struct sockaddr* dest) { promise_t<int> awaitable; auto state = awaitable._state->lock(); req->data = state; auto ret = ::uv_tcp_connect(req, socket, dest, [](uv_connect_t* req, int status) -> void { ... © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.


Download ppt "4/13/2018 10:02 AM © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN."

Similar presentations


Ads by Google