Home | History | Annotate | Line # | Download | only in lsan
      1  1.1  kamil //===-- lsan_flags.inc ------------------------------------------*- C++ -*-===//
      2  1.1  kamil //
      3  1.1  kamil //                     The LLVM Compiler Infrastructure
      4  1.1  kamil //
      5  1.1  kamil // This file is distributed under the University of Illinois Open Source
      6  1.1  kamil // License. See LICENSE.TXT for details.
      7  1.1  kamil //
      8  1.1  kamil //===----------------------------------------------------------------------===//
      9  1.1  kamil //
     10  1.1  kamil // LSan runtime flags.
     11  1.1  kamil //
     12  1.1  kamil //===----------------------------------------------------------------------===//
     13  1.1  kamil #ifndef LSAN_FLAG
     14  1.1  kamil # error "Define LSAN_FLAG prior to including this file!"
     15  1.1  kamil #endif
     16  1.1  kamil 
     17  1.1  kamil // LSAN_FLAG(Type, Name, DefaultValue, Description)
     18  1.1  kamil // See COMMON_FLAG in sanitizer_flags.inc for more details.
     19  1.1  kamil 
     20  1.1  kamil LSAN_FLAG(bool, report_objects, false,
     21  1.1  kamil           "Print addresses of leaked objects after main leak report.")
     22  1.1  kamil LSAN_FLAG(
     23  1.1  kamil     int, resolution, 0,
     24  1.1  kamil     "Aggregate two objects into one leak if this many stack frames match. If "
     25  1.1  kamil     "zero, the entire stack trace must match.")
     26  1.1  kamil LSAN_FLAG(int, max_leaks, 0, "The number of leaks reported.")
     27  1.1  kamil 
     28  1.1  kamil // Flags controlling the root set of reachable memory.
     29  1.1  kamil LSAN_FLAG(bool, use_globals, true,
     30  1.1  kamil           "Root set: include global variables (.data and .bss)")
     31  1.1  kamil LSAN_FLAG(bool, use_stacks, true, "Root set: include thread stacks")
     32  1.1  kamil LSAN_FLAG(bool, use_registers, true, "Root set: include thread registers")
     33  1.1  kamil LSAN_FLAG(bool, use_tls, true,
     34  1.1  kamil           "Root set: include TLS and thread-specific storage")
     35  1.1  kamil LSAN_FLAG(bool, use_root_regions, true,
     36  1.1  kamil           "Root set: include regions added via __lsan_register_root_region().")
     37  1.1  kamil LSAN_FLAG(bool, use_ld_allocations, true,
     38  1.1  kamil           "Root set: mark as reachable all allocations made from dynamic "
     39  1.1  kamil           "linker. This was the old way to handle dynamic TLS, and will "
     40  1.1  kamil           "be removed soon. Do not use this flag.")
     41  1.1  kamil 
     42  1.1  kamil LSAN_FLAG(bool, use_unaligned, false, "Consider unaligned pointers valid.")
     43  1.1  kamil LSAN_FLAG(bool, use_poisoned, false,
     44  1.1  kamil           "Consider pointers found in poisoned memory to be valid.")
     45  1.1  kamil LSAN_FLAG(bool, log_pointers, false, "Debug logging")
     46  1.1  kamil LSAN_FLAG(bool, log_threads, false, "Debug logging")
     47  1.1  kamil LSAN_FLAG(const char *, suppressions, "", "Suppressions file name.")
     48