LSAN and ASAN: tips, tricks and hacks

Address Sanitizer (ASAN) and Leak Sanitizer (LSAN) have a lot of options and additional functions which sometimes could be used not only for detecting memory errors and leaks.

This talk will cover LSAN internals (combined memory manager, interceptors, garbage collector which does not collects garbage, why LSAN does not work with gdb), ASAN and LSAN public interface, how to profile memory usage via ASAN or LSAN, obtaining about objects metadata, memory manager statistics and useful functions which could be used from gdb.

Also we'll try to improve LSAN diagnostic output via using non public LSAN API.

Image

Alexey Veselovsky

Senior C++ developer at Align Technology. Develops general system components and the framework of a specialized 3D CAD system.

Previously developed a real-time patient monitoring system, as well as a data collection and processing system for self driving cars. Took part in the Squid-proxy project.

Area of interest includes software reliability, compiler engineering, and system programming.

When

July 21-24, 2024

LinkedIn

CppNorth Group