Overview
Explore the concept of undefined behavior in C++ through this comprehensive conference talk from CppNow 2014. Delve into what undefined behavior is, why it matters, and its implications for C++ programmers. Learn about various examples of undefined behavior, including array access violations, signed integer overflow, and uninitialized variables. Examine compiler optimizations, performance considerations, and language semantics related to undefined behavior. Discover the history behind undefined behavior in C++ and its impact on modern programming practices. Gain insights into detecting and avoiding undefined behavior to write more robust and reliable C++ code.
Syllabus
Intro
Boost Lists
What is undefined behavior
Examples of what could happen
Array example
Signed integer overflow
Example program crashes
Compiler optimizations
Can you order pointers
Is this a new thing
Copy with overlapping buffers
Modulo bugs
Ignoring integer overflow
Uninitialized variables
Warnings as errors
Uninitialized variable
Uninitialized
Why do we do this
Performance and code size
Language semantics
Types of undefined behavior
Is undefined behavior legal
History of undefined behavior
Search theory
Printing
Taught by
CppNow