HackerTube.dev

C++ Exceptions for Smaller Firmware - Khalil Estell - CppCon 2024

CppCon · 23.3K views · 2024-12-06 · 1:24:36

Open on YouTube ↗

If playback is restricted in your region, try opening the original video. Use Mark watched to add it to your marked videos.

Overview

Khalil Estell's CppCon 2024 talk argues C++ exceptions can reduce binary size in firmware. He digs into how exceptions work and how to shrink their code footprint on embedded platforms.

On Hacker News

Pointed to as the in-depth talk on exception mechanics and code size for embedded C++.

Recommended by 5 HN people across 4 months · HN mentions 2025–2026

Topics

Search by tags

What people said

inetknght · 2025-09 · Strong recommendation

> I don't have enough time to watch these kinds of presentations. Then let me pick and share some of my favorites that I found enlightening, and summarize with some information that I found useful. By far, the most useful one is Khalil Estell's presentation last year [0]. It's a fairly face paced but relatively deep dive into exception mechanics. At the end, he advocates for a new tool that would audit a program to determine what exceptions could be thrown. I think that's a flipping fantastic idea for a tool. Unfortunately I haven't seen any progress toward it -- if someone here knows where his tool is, or a similar tool, please reply! I did send him an email a few months ago inquiring about it, but haven't received a reply. Nonetheless, the whole presentation was excellent in my opinion. I did see that he had another related presentation at ACCU this year [4] with a topic of "C++ Exceptions are Code Compression" (which I totally can believe -- I've seen it myself in binary sizes), but I haven't seen his presentation yet. I'll watch it later today. Just about anything from Herb Sutter is good. I don't like that he works for Microsoft, but he does great stuff for C++, including the old Guru of the Week series [1]. In particular, his 2019 presentation [2] describes different error handling techniques, some difficulties and pitfalls in combining libraries with different error handling techniques, and leads up to explaining why std::expected came about. He does pontificate a lot

Read the original HN comment ↗
daemin · 2026-03 · Recommendation

I just thought I'd mention that Khalil Estell is doing some work regarding exceptions in embedded and bare metal programming. In the first of his talks about this topic ( [VIDEO] ) he mentions that a lot of the bloat in exception handling is including printf in order to print out the message when terminating the program. For those interested he has another presentation on this topic [LINK]

Read the original HN comment ↗
neonz80 · 2025-11 · Recommendation

There was an interesting talk about C++ exceptions in smaller firmware at CppCon last year: [VIDEO] Basically, the overhead of exceptions is probably less than handling the same errors manually in any non-trivial program. Also, it's not like these table doesn't exist in other languages. Both Rust and Go have to unwind.

Read the original HN comment ↗

Sources

Video by CppCon, played through YouTube.

Data and selection notes

HN summaries and labels may contain AI errors. HN dates refer to discussions, not video publication.

HN Library: HackerTube export (2026-10-31) and open-index/hacker-news. Upstream summaries and classifications may contain AI errors.

Views, duration and playback status refresh separately from the published catalog. When an update fails, existing data remains visible.

Selection checks
  • SaaS & AI candidates: Topic keywords do not match
  • Editor-approved picks: Editorial review is required

Rule matches identify candidates. They do not guarantee video quality or financial results.

About the library and its sources