09-28, 08:45–09:15 (UTC), Loft
At some stage in your programming life you may well have used a debugger, but did you wonder how it was able to step into and control your executable? In this talk we'll see how debuggers work by building one from scratch in a few lines of Go.
In this talk Liz will explore how a debugger gains control of a process with the all-powerful ptrace system call. You'll see how we can find the machine code that corresponds to a line of human-readable source code and vice-versa. She will show how breakpoints are set, explain how the stack gets built up, and demonstrate how to generate a stack trace showing the path to that breakpoint.
Even if you know nothing about machine code, you'll leave this talk with a better understanding of how a computer runs an executable, and how a debugger is able to start and stop the executable as you wish.
Maxime Hadjinlian is an embedded Linux engineer at Devialet. He was involved in the creation of the current and future software stack running on Devialet’s product. He also contributes in his spare time to a few open-source projects, including Buildroot.