Guide agents through choosing, enabling, and interpreting compiler runtime sanitizers for finding memory errors, undefined behaviour, data races, and memory leaks.
| detectleaks=0/1 | Enable LeakSanitizer (default 1 on Linux) | | abortonerror=1 | Call abort() instead of exit() (for core dumps) | | logpath=path | Write report to file | | symbolize=1 | Symbolize addresses (needs llvm-symbolizer in PATH) | | fastunwindonmalloc=0 | More accurate stacks (slower) | | quarantinesizemb=256 | Delay reuse of freed memory |
Reading: the top frame in WRITE/READ is the access site; the allocated at stack shows the allocation. The region is 40 bytes at [start, end) and the access is at end = one byte past the end (classic off-by-one).
Compiler-Bereinigungsfähigkeit zur Laufzeitfehlererkennung in C/C++. Wird zum Aktivieren und Interpretieren von AddressSanitizer (ASan), UndefinedBehaviorSanitizer (UBSan), ThreadSanitizer (TSan), MemorySanitizer (MSan) oder LeakSanitizer (LSan) mit GCC oder Clang verwendet. Wird bei Abfragen zu Sanitizer-Flags, Sanitizer-Berichten, ASAN_OPTIONS, Speicherfehlern, Datenrennen, undefiniertem Verhalten, nicht initialisierten Lesevorgängen oder der Auswahl des Sanitizers für eine bestimmte Fehlerklasse aktiviert. Quelle: mohitmishra786/low-level-dev-skills.