blob: 2cd0a5b1334be881b772c04d05111d1fc785d5f9 [file] [log] [blame]
Kostya Kortchinskyf974ea42019-04-09 14:57:25 +00001//===-- 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#ifndef SCUDO_FLAGS_H_
10#define SCUDO_FLAGS_H_
11
12#include "internal_defs.h"
13
14namespace scudo {
15
16struct Flags {
17#define SCUDO_FLAG(Type, Name, DefaultValue, Description) Type Name;
18#include "flags.inc"
19#undef SCUDO_FLAG
Mitch Phillips4e8fae62019-12-13 09:09:34 -080020
21#ifdef GWP_ASAN_HOOKS
22#define GWP_ASAN_OPTION(Type, Name, DefaultValue, Description) \
23 Type GWP_ASAN_##Name;
24#include "gwp_asan/options.inc"
25#undef GWP_ASAN_OPTION
26#endif // GWP_ASAN_HOOKS
27
Kostya Kortchinskyf974ea42019-04-09 14:57:25 +000028 void setDefaults();
29};
30
31Flags *getFlags();
32void initFlags();
33class FlagParser;
34void registerFlags(FlagParser *Parser, Flags *F);
35
36} // namespace scudo
37
38#endif // SCUDO_FLAGS_H_