Compile Time Regular Expressions with Deterministic Finite Automaton

C++ London
C++ London
Public group
Location image of event venue


This month we're excited to welcome Hana Dusíková, visiting from Prague, to talk to us about Regular Expressions ... at compile time!

We're back at CloudFlare, so drinks and some light snacks, will be provided.

To submit a talk idea for future events please visit


19:00 Intro and News - Phil Nash

19:10: TBA ---

19:45 "Compile Time Regular Expressions with Deterministic Finite Automaton" - Hana Dusíková.

In this talk I will present an advancement on the Compile Time Regular Expression (CTRE) Library. The library was designed with new C++20 features, and it uses novel techniques. This presentation independently sums up the work since my previous CppCon talk about the library. The primary topic of this talk will be an explanation of the new Deterministic Finite Automaton (DFA) engine in the library and how it's built and optimised during compilation. I will explain the differences and limitations of the new engine in comparison to the previous Back Tracking engine. I will address these differences with a benchmark and I will discuss the generated assembly. Even if you are not interested in regular expressions, you will learn new techniques in compile-time meta-programming and see new C++20 features in action.

About the speakers:

Hana is working as a senior researcher in Avast Software. She is the author of CTRE (Compile Time Regular Expressions) library, Chair of SG7 (Study Group for Compile Time Programming) and Czech National Body representative in WG21 (ISO C++ Committee).