Back To Schedule

Undefined Behavior From the Compiler’s Perspective

A deep dive into what makes UBs so dangerous, and why people rightfully continue to use them anyways

11:00 - 12:30 Monday 28th April 2025 MT Bethe Hall
Intermediate
Advanced
Generic/Metaprogramming

There are two ways people react to Undefined Behavior (UB) in C++. One reaction is to make this the big bad demon, out to eat all of your bits. The other is to shrug it off as some niche subject which won't matter much.

Both attitudes have some merit while, at the same time, being quite wrong.

This talk approaches UBs, not as the big bad wolf, but from the compiler's perspective. It covers what they are, what the compiler does with them and what makes them dangerous. It also covers C++ misguided approach to them, and what the C++ language (and compilers) can (and should) do to make life easier on developers.

View Slides

Shachar Shemesh

CCC (Chief Content Creator)Some Assembly required

Shachar started programming over 40 years ago, and still finds pleasure in it. Programming at all levels, from bare metal to GUI, and even building whole computers on FPGAs, some with even more bits than 8.

Shachar is operating a technological YouTube channel called "Some Assembly required" and a less technical one called "Less Assembly required".