The Microsoft C++ team attended CppCon, the largest C++ conference in the world. This year, the conference was held in Aurora, Colorado from September 16-20.
Microsoft Booth
Our team managed a booth from Monday to Thursday of the week. This gave us an amazing opportunity to interact with the C++ community and discuss many topics of interest as well as hear feedback from our customers.
The following people worked at the booth (from left to right in the picture above):
- Victor Ciura, who works on Rust and C++ interop. He presented a talk called So You Think You Can Hash.
- Mryam Girmay, who works on Visual Studio productivity features. She was one of the co-presenters of this year’s What’s New in Visual Studio for C++ Developers talk.
- Sinem Akinci, who works on CMake tooling in the Visual Studio IDE and Visual Studio Code. Sinem also works on GitHub Copilot. She was one of the co-presenters of this year’s What’s New in Visual Studio Code talk.
- Augustin Popa (me), and I work on the vcpkg package manager. My talk was called 10 Problems Large Companies Have with Managing C++ Dependencies and How to Solve Them.
- Alexandra Kemper, who works on the C++ experience in Visual Studio Code. She was one of the co-presenters of this year’s What’s New in Visual Studio Code talk.
- Michael Price, who works on C++ integration with developer services like GitHub and Microsoft Dev Box. He was one of the co-presenters of this year’s What’s New in Visual Studio for C++ Developers talk.
Microsoft works on several developer tools for C++, including the Visual Studio IDE, Visual Studio Code, the MSVC compiler toolset, GitHub Copilot for C++, and the vcpkg package manager. We interacted with hundreds of C++ developers across a variety of different industries, experience levels, and familiarity with our product offerings. There were folks who had been using our products before their names started with “Visual”, and some that had never used our tools at all.
We were excited to see so much interest from developers for C++ best practices and how to become more productive. We received some great feedback about how we could improve our tools, in terms of bug reports, user experience improvements, and feature requests. We were also able to have several 1 on 1 longer discussions away from the booth to help people solve more specific challenges using Microsoft C++ developer tools.
At the booth we also gave out some cool swag, including USB adapters, vcpkg bags, stickers, and the ever-popular Visual Studio socks.
We also held a raffle at the end of each day at our booth, for some Visual Studio backpacks and tote bags.
Keynote Talk: Peering forward – C++’s next decade
As usual, Herb Sutter delivered an excellent talk at CppCon. This year it was a keynote that looks forward in time, describing the planned evolution of the C++ language. The main topics were reflection, safety, and simplicity. These topics were effectively previews for a number of other C++ talks that elaborated on these topics in great detail.
Microsoft Talks at CppCon 2024
Aside from Herb’s keynote, there were several other talks delivered by folks from Microsoft at CppCon this year.
So You Think You Can Hash
Victor delivered a talk on fundamentals of data structure design, focusing on computing hashes for aggregated user-defined types and experimenting with various hash algorithms. He introduced a method for experimenting with and benchmarking different hash algorithms. This allows easy switching of hashing algorithms used by complex data structures, enabling easy comparisons. This way, hash algorithm designers can concentrate on designing better hash algorithms, with little worry about how these new algorithms can be incorporated into existing code. Type designers can create their hash support just once, without worrying about what hashing algorithm should be used.
The talk spurred a bunch of hallway conversations on tradeoffs between performance and flexibility of type design, with attendees sharing their project pains and workarounds in this space.
10 Problems Large Companies Have with Managing C++ Dependencies and How to Solve Them
I presented a talk on 10 problems that large companies have with C++ dependency management, based on many conversations I had this year with enterprise teams. I also went over how these companies are solving these problems. About half of the problems are solvable with a modern package manager, but the rest require additional investments in development workflows. The talk was well attended and there were some good conversations afterward about the problems.
Today, developers are still more likely to manually manage their dependencies than to use a package manager and consider managing libraries a top pain point for C++, according to ISO C++ surveys. I pointed out some ways that a package manager like vcpkg can mitigate the pain. Here are a few examples:
- Supporting build from source as a fallback without sacrificing the build-time savings of binary dependency acquisition.
- Upgrading dependencies as a set using baselines, rather than managing them individually, to avoid version conflicts / diamond problems.
- How to continue working in an offline build environment using asset caching.
- Getting any open-source libraries installed and working with your project with minimal effort, while also automatically resolving transitive dependencies.
In the second half of the talk, I noted that security is top of mind for enterprises, so vulnerability monitoring, detection, and response is critical. Some enterprises have also started using Software Bill of Materials (SBOMs) to track their dependencies and manage risk. I also pointed out that vcpkg generates SPDX SBOM files for dependencies.
Lastly, I spoke about some workflow changes that make it more manageable to do C++ development at scale, at a large company with many distributed teams. This includes centralizing common development tasks with dedicated core teams, moving to container-based builds and a standardized global build toolchain, and how to handle a large migration to a new software system by breaking it down into smaller, manageable milestones where you get a win at each step.
After my talk, I talked with several folks about the problems they were dealing with at their work and what they had in common with the themes of the talk. In my opinion, one of the best things about delivering a talk is the conversations that happen afterward, which lead to new ideas and approaches to improve our software.
Embracing an Adversarial Mindset for C++ Security
Amanda Rousseau delivered a compelling talk on thinking like an adversary with respect to C++ security. She walked through some attack scenarios, vulnerability trends, exploits that actually exist out in the wild, and general strategies for C++ development. For Microsoft, security is always top of mind, and it was interesting hearing from her experiences about how to address these growing concerns.
What’s new for Visual Studio Code: Performance, GitHub Copilot, and CMake Enhancements
The annual Visual Studio Code talk, delivered this year by Alexandra Kemper and Sinem Akinci, was packed full of updates for C++ developers. Enhancing performance for C++ developers was a top priority for our team, and the talk announced several updates to make the C++ development process faster, including updates to project start-up time and time to colorization. The talk featured enhancements to C++ Copilot completions, sample AI-assisted workflows in C++ code, and new Copilot extensibility points available for developers to tailor the AI tool to their workflow. Demonstrating the chat extension API extensibility points to CppCon via a @CppCon chat participant piqued interest in the crowd. The docs to learn more about these APIs available can be found here: https://code.visualstudio.com/api/extension-guides/chat.
The demo code that was used can be found below. The first demo focused on C++, CMake, and Copilot functionality whereas the second demo focused on a CppCon chat participant for Copilot.
- sinemakinci1/Cpp-Copilot-VSC-Demo at alex-gui-2
- sinemakinci1/cppcon-chat-participant: Chat participant for CppCon
What’s New in Visual Studio for C++ Developers
Mryam Girmay and Michael Price presented the 10th annual session demonstrating new features for C++ developers in Visual Studio. Highlighted this year were features to make you a more productive C++ developer, from shrinking your build times with Build Insights and Include Diagnostics, to reducing the amount of time you spend crafting the perfect commit message for those changes you’ve accumulated throughout the day, by letting GitHub Copilot write a first draft for you.
Visual Studio leverages the power of GitHub Copilot to reduce the burden of routine tasks like sketching out unit tests for a function you just wrote or wading through pages of template error messages to understand what you’ve done wrong. And in the talk, Michael and Mryam demonstrated the soon-to-be-generally available content exclusion feature that you can configure to prevent contents from specified files never get sent in a prompt to GitHub Copilot. They also showcased interactive demos, allowing developers to see firsthand how these new features can be leveraged in real-world scenarios.
After the talk, developers shared valuable feedback on Visual Studio, the Microsoft C++ compiler, and GitHub Copilot. Attendees came with questions and offered several suggestions on how we can further improve our products for them. This input is crucial as the team continues to refine and enhance the tool to better meet the needs of C++ developers.
Some Other Interesting Talks
There were many great talks this year. Below are a few that we enjoyed.
Diego Rodriguez-Losada Gonzalez of JFrog delivered a very interesting talk where he demoed integrated Common Package Specification (CPS) files with various build systems, including CMake, MSBuild, Autotools, and Meson. The Common Package Specification is a mechanism for describing the useful artifacts of a software package and is a collaborative effort between several software vendors, build system maintainers, library authors, and large companies to eventually standardize such a system across the industry.
Creating a Sender/Receiver HTTP Server
This session was a live-coding demo with building an HTTP server from scratch and debugging problems using C++26 sender/receivers.
Performance engineering – Being friendly to your hardware
Excellent crash course on hardware details, from DRAM inner-workings to CPUs and how to write software to avoid angering the machine.
Sender Patterns to Wrangle Concurrency in Embedded Devices
Superb introduction to bare-metal senders and receivers and very crisp explanations of the async examples.
C++/Rust Interop: Using Bridges in Practice
Quick tour of the Rust/C++ interop essentials and some of the friction points in hybrid-code projects.
Theme: Reflection
Every CppCon, there tends to be a big focus on some major feature that is coming up in the language. For a long time, that used to be modules. Now that modules are successfully baked into many of our developer tools and are seeing some adoption, the biggest discussion topic has moved to reflection. Reflection is a significant feature improvement that many of us have looked forward to for years, and our patience is getting rewarded. Aside from Herb’s keynote, there were several talks, including Reflection based libraries to look forward to (by Saksham Sharma), Reflection is Not Contemplation (by Andrei Alexandrescu), and Implementing Reflection using the new C++20 Tooling Opportunity: Modules (by Maiko Steeman). Lastly, Daveed Vandevoorde’s Gazing Beyond Reflection for C++26 went into some excellent technical detail while giving a preview of what’s to come and is worth checking out.
Theme: C++ Security
We have all seen the headlines from industry analysts and governments over the past few years citing concerns with code safety or security in C++. This is a big focus area for the C++ Committee as well as large companies that must worry about rising threats to their business. Some specialized talks included: Security Beyond Memory Safety – Using Modern C++ to Avoid Vulnerabilities by Design (by Max Hoffmann), Embracing an Adversarial Mindset for C++ Security (by Amanda Rousseau), Building Safe and Reliable Surgical Robotics (by Milad Khaledyan), Modern C++ Error Handling (by Phil Nash), Mix Assertion, Logging, Unit Testing and Fuzzing: Build Safer Modern C++ Applications (by Xiaofan Sun), “Pick a random number… no, not that one!” – Tales of Real-World Exploits Based on Bad Randomness (by Max Hoffmann), and Compile-time Validation (by Alon Wolf).
In addition, LLVM’s Realtime Safety Revolution: Tools for Modern Mission Critical Systems (by Christopher Apple and David Trevelyan) introduced the new Realtime Sanitizer, which detects calls to malloc
, pthread_mutex_lock
, and other problematic functions in your realtime code at runtime!
Lastly, there was also an expert-led Safety and Security Panel to check out too.
Women’s Luncheon
The Women’s Networking Luncheon was a fun and resourceful event. Alexandra, Mryam, and Sinem from Microsoft’s team attended. Each table buzzed with interesting discussions: women in tech, inspirations to join the programming world, various work experiences, and ideas to inspire the next generation of women. With table rotations, attendees had the chance to talk to different people in the room. The relaxed atmosphere fostered connections among women from diverse companies and places who share an interest in C++ and programming.
Conclusion
It was great to meet many of you in person this year at CppCon. We enjoyed our time there and learned a lot from the C++ community and have taken back our learnings to our day-to-day work. If you didn’t get a chance to attend or missed out on some of the sessions, remember to check out all the CppCon talk on the conference’s YouTube channel as they get rolled out! We also made a playlist of past Microsoft CppCon sessions. We look forward to seeing you again next year.
0 comments
Be the first to start the discussion.