Back To Schedule

Beautiful C++ Code

Told Through the Eyes of A Failed AI Prompt

14:30 - 16:00 Monday 4th May 2026 MT Bethe Hall
Intermediate
Advanced

A production message-passing abstraction has quietly powered a large C++ system for years. Most developers use its API daily. Very few understand the machinery underneath.

Its longevity comes from a dense combination of advanced C++ techniques: controlled friendship, type erasure, subtle inheritance structures, carefully engineered destructor ordering and clever operator overloading. The surface is simple; the implementation is anything but.

In this talk, we attempt to recreate the abstraction from scratch using an AI assistant. The initial results are clean, plausible and fundamentally simpler than the production design. By iteratively refining prompts, we guide the AI toward the nuanced trade-offs that make the real system robust and performant.

This process produces something remarkable: a compressed reenactment of the abstraction’s evolution. By contrasting naïve implementations with the final design, we expose the hidden decisions and constraints that expert-level C++ encodes.

This talk uses AI, in a novel way, as a lens to illuminate advanced C++ design. And to better understand why beautiful abstractions are built the way they are.

View Slides

Erich Lohrmann

Senior Embedded Software EngineerGeneral Dynamics Mission Systems

Erich Lohrmann is a software engineer at General Dynamics Mission Systems, where he specializes in building high-performance, low-latency systems. Previously, he served as a research engineer at the Georgia Tech Research Institute, contributing to the development of next-generation technologies.

His experience spans the design and implementation of large-scale server applications as well as advanced embedded systems. He holds a Master of Science in Computer Science from the Georgia Institute of Technology, earned in May 2018. His professional interests include the research and development of state-of-the-art operating systems, embedded platforms, and distributed systems.

Erich primarily works in C++ and Rust, focusing on creating robust abstractions that enforce correct usage and minimize the risk of misuse by other developers. His work emphasizes reliability and maintainability in complex, distributed application environments.