Posts

Overview of AddressSanitizer

AddressSanitizer (ASan) is a C++ tool that finds memory bugs at runtime, such as use-after-free and out-of-bounds accesses. It is part of LLVM. At Google, we use ASan extensively. I just read the ASan paper to understand how it works. The paper itself is very readable. Here is a quick summary. At compile time, ASan instruments memory accesses in the code, and at runtime it checks if the access is legitimate, by using shadow memory. ASan uses a custom allocator instead of malloc. Shadow memory is memory allocated by the program such that every ordinary application address X has a corresponding shadow address Y, where metadata about X can be stored. You can map X to Y by a direct scale and offset, in which case the whole application address space is mapped to a single shadow address space, or you can map X to Y using table lookups (runs slower but is more flexible). At compile time, ASan creates poisoned redzones around stack and global data. At runtime, it creates poisoned redzones aro

Some basic notes about debuggers

Trying out mypy

My 2010 - 2019

Thoughts on Coursera's Deep Learning Specialization

Overview of instruction-level parallelism

A Few Billion Lines of Code Later: CACM article describing static analysis in the real world

The Phoenix Project and the start of the DevOps movement

Audiobooks I listened to in 2018

The network structure of computer programs

Summary of the book "Linked", by Laszlo Barabasi

About this blog

Summary of the paper "A Domain-Specific Architecture for Deep Neural Networks"