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