DWARF information on Linux provides debuggers with a bridge between high-level source code and the machine instructions generated by the compiler. As part of this, it describes how to locate variables within your program at runtime using a language called DWARF Expressions. When implementing a parser for DWARF Expressions I thought "this seems suspiciously Turing-complete, can I implement a programming language inside this?" It turns out the answer is yes. In this session you'll learn how debug information and executables are stored on Linux systems and how I managed to (ab)use them to implement a programming language interpreter that runs when you ask your debugger for the address of a variable.
Ещё видео!