Carbon and Modernizing C++ with Chandler Carruth
Episode
62 min
Read time
2 min
Topics
Design & UX, Software Development, Product & Tech Trends
AI-Generated Summary
Key Takeaways
- ✓C++ Interop Architecture: Carbon uses Clang to parse C++ into AST, synthesizes bidirectional representations between Carbon's semantic IR and C++'s AST, then merges both into LLVM IR. This enables zero-copy data passing and supports complex features like virtual inheritance across language boundaries without runtime overhead.
- ✓Parameter Passing Optimization: C++ forces developers to choose between pass-by-value and const-reference for every function parameter based on type size, creating decision overhead and performance penalties. Carbon provides one unified input parameter syntax that automatically optimizes for each type, eliminating pointer indirection for small types like integers.
- ✓Definition-Checked Generics: Carbon implements checked generic programming that validates code at definition time rather than instantiation, enabling memory safety features similar to Rust while maintaining template compatibility for C++ interop. This reduces code duplication and compile-time costs compared to C++ template instantiation for every type combination.
- ✓Incremental Migration Path: Developers can automatically translate C++ code to Carbon syntax, then incrementally add constraints to templates without breaking existing code. Once constraints propagate through dependencies, templates convert to checked generics, delivering better error messages and reduced binary size while maintaining full functionality throughout migration.
- ✓Governance Through Painter Role: Carbon's three-lead structure includes a painter who breaks aesthetic ties only when no technical rationale exists. This mechanism forces contributors to articulate technical reasons for preferences rather than arguing aesthetics, resulting in almost zero purely aesthetic decisions while maintaining rapid decision velocity.
What It Covers
Chandler Carruth explains Carbon, Google's experimental successor to C++, designed to provide memory safety and modern features while maintaining seamless interoperability with existing C++ codebases through advanced compiler technology and bidirectional AST translation.
Key Questions Answered
- •C++ Interop Architecture: Carbon uses Clang to parse C++ into AST, synthesizes bidirectional representations between Carbon's semantic IR and C++'s AST, then merges both into LLVM IR. This enables zero-copy data passing and supports complex features like virtual inheritance across language boundaries without runtime overhead.
- •Parameter Passing Optimization: C++ forces developers to choose between pass-by-value and const-reference for every function parameter based on type size, creating decision overhead and performance penalties. Carbon provides one unified input parameter syntax that automatically optimizes for each type, eliminating pointer indirection for small types like integers.
- •Definition-Checked Generics: Carbon implements checked generic programming that validates code at definition time rather than instantiation, enabling memory safety features similar to Rust while maintaining template compatibility for C++ interop. This reduces code duplication and compile-time costs compared to C++ template instantiation for every type combination.
- •Incremental Migration Path: Developers can automatically translate C++ code to Carbon syntax, then incrementally add constraints to templates without breaking existing code. Once constraints propagate through dependencies, templates convert to checked generics, delivering better error messages and reduced binary size while maintaining full functionality throughout migration.
- •Governance Through Painter Role: Carbon's three-lead structure includes a painter who breaks aesthetic ties only when no technical rationale exists. This mechanism forces contributors to articulate technical reasons for preferences rather than arguing aesthetics, resulting in almost zero purely aesthetic decisions while maintaining rapid decision velocity.
Notable Moment
Carruth reveals that C++ compile times measured in minutes for text processing represent a fundamental failure compared to millisecond turnarounds in modern JavaScript tooling. Carbon targets interactive-speed compilation through novel semantic IR architecture that enables faster parsing and compile-time evaluation than traditional AST approaches.
Episode Transcript
Carbon is a programming language developed by Google as a successor to c plus plus and it aims to provide modern safety features while maintaining high performance. It's designed to offer seamless interoperability with c plus plus while addressing shortcomings of c plus plus such as slow compilation times and lack of memory safety. Carbon also introduces features like a more readable syntax, improved generics, and automatic memory management while still allowing low level control. Chandler Carruth is the creator of Carbon, and he leads the c plus plus, CLANG, and LLVM teams at Google, and he also worked on several pieces of Google's distributed build system. In this episode, he joins Kevin Ball to talk about Carbon and the future of the language. Kevin Ball, or Kay Ball, is the vice president of engineering at Mento and an independent coach for engineers and engineering leaders. He cofounded and served as CTO for two companies, founded the San Diego JavaScript meetup, and organizes the AI in Action discussion group through Latent Space. Check out the show notes to follow Kay Ball on Twitter or LinkedIn, or visit his website, kball.llc. Chandler, welcome to the show. Really happy to be here. Really happy to be here. Yeah. I'm excited to dig in. So let's maybe start with a little bit about you, your background, and a little bit about what Carbon is and what led to it. Sure. Sure. I mean, I've been a software engineer at Google for a long time now. And when I started, I was pretty fresh out of university and didn't really know what I was doing kind of got thrown into a bit of the deep end. And I was working on a c plus plus project with a bunch of amazing folks who are largely teaching me how to be a good software engineer. And I was incredibly frustrated because the C plus plus project was just holding me back every single step of the way working on the C plus plus code base was painful. The tools were bad. The experience was bad. And it seemed like it really it just it became an overwhelming kind of problem that we needed to solve. And that kind of kick started me diving a whole lot deeper into first compilers because I thought maybe the compiler was the problem. And as we got better and better compilers, then enter the programming language, joined the standards committee, really tried to figure out ways we could much more radically improve c plus plus the experience for all the developers, and also the quality of the actual software we're able to put out. At a certain point, we weren't actually able to achieve the kind of improvements we needed to. We kept seeing really fundamental risks facing c plus plus really fundamental problems that needed pretty radical changes to the programming language as a whole and that the kind of how the programming language worked in order to …
Get the full transcript (12,344 words) + summary by email — free
One-time email with the complete transcript and AI summary of this episode. No account needed.
One email, no spam. We’ll also show you what SignalCast does.
You just read a 3-minute summary of a 59-minute episode.
Get Software Engineering Daily summarized like this every Monday — plus up to 2 more podcasts, free.
Pick Your Podcasts — FreeKeep Reading
More from Software Engineering Daily
A Rust Framework to Simplify Distributed Systems
Sep 10 · 50 min
a16z Podcast
Building Search for AI Agents with Exa CEO Will Bryk
Jun 6
More from Software Engineering Daily
SED News: The NVIDIA-Hugging Face Deal, China’s Proxy Economy, the Open Weight Surge
Sep 8 · 52 min
a16z Podcast
What It Takes to Build a Startup | Andrew Chen & Matt Perault
Sep 11
More from Software Engineering Daily
We summarize every new episode. Want them in your inbox?
A Rust Framework to Simplify Distributed Systems
SED News: The NVIDIA-Hugging Face Deal, China’s Proxy Economy, the Open Weight Surge
Moving Beyond RAG with Precomputed Context
The Death of Online Anonymity
TypeScript 7 and What Comes Next
Similar Episodes
Related episodes from other podcasts
a16z Podcast
Jun 6
Building Search for AI Agents with Exa CEO Will Bryk
a16z Podcast
Sep 11
What It Takes to Build a Startup | Andrew Chen & Matt Perault
Deep Questions with Cal Newport
Sep 7
How I’m Organizing My Life this Fall | Advice
Practical AI
Aug 28
Building the Foundation for the Agentic AI Era
Latent Space
Aug 26
🔬“We have foundation models for language, not for physics” — Anima Anandkumar, Bren Professor of Computing
Explore Related Topics
This podcast is featured in Best Cybersecurity Podcasts (2026) — ranked and reviewed with AI summaries.
Read this week's Software Engineering Podcast Insights — cross-podcast analysis updated weekly.
You're clearly into Software Engineering Daily.
Every Monday, we deliver AI summaries of the latest episodes from Software Engineering Daily and 192+ other podcasts. Free for one show.
Start My Monday DigestNo credit card · Unsubscribe anytime