tsan_flags.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. //===-- tsan_flags.h --------------------------------------------*- C++ -*-===//
  2. //
  3. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  4. // See https://llvm.org/LICENSE.txt for license information.
  5. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  6. //
  7. //===----------------------------------------------------------------------===//
  8. //
  9. // This file is a part of ThreadSanitizer (TSan), a race detector.
  10. // NOTE: This file may be included into user code.
  11. //===----------------------------------------------------------------------===//
  12. #ifndef TSAN_FLAGS_H
  13. #define TSAN_FLAGS_H
  14. #include "sanitizer_common/sanitizer_flags.h"
  15. #include "sanitizer_common/sanitizer_deadlock_detector_interface.h"
  16. namespace __tsan {
  17. struct Flags : DDFlags {
  18. #define TSAN_FLAG(Type, Name, DefaultValue, Description) Type Name;
  19. #include "tsan_flags.inc"
  20. #undef TSAN_FLAG
  21. void SetDefaults();
  22. void ParseFromString(const char *str);
  23. };
  24. void InitializeFlags(Flags *flags, const char *env,
  25. const char *env_option_name = nullptr);
  26. } // namespace __tsan
  27. #endif // TSAN_FLAGS_H