1 |
|
/****************************************************************************** |
2 |
|
* Top contributors (to current version): |
3 |
|
* Mathias Preiner, Aina Niemetz |
4 |
|
* |
5 |
|
* This file is part of the cvc5 project. |
6 |
|
* |
7 |
|
* Copyright (c) 2009-2021 by the authors listed in the file AUTHORS |
8 |
|
* in the top-level source directory and their institutional affiliations. |
9 |
|
* All rights reserved. See the file COPYING in the top-level source |
10 |
|
* directory for licensing information. |
11 |
|
* **************************************************************************** |
12 |
|
* |
13 |
|
* Contains code for handling command-line options. |
14 |
|
* |
15 |
|
* For each <module>_options.toml configuration file, mkoptions.py |
16 |
|
* expands this template and generates a <module>_options.h file. |
17 |
|
*/ |
18 |
|
|
19 |
|
#include "cvc5_private.h" |
20 |
|
|
21 |
|
#ifndef CVC5__OPTIONS__THEORY_H |
22 |
|
#define CVC5__OPTIONS__THEORY_H |
23 |
|
|
24 |
|
#include "options/options.h" |
25 |
|
|
26 |
|
// clang-format off |
27 |
|
|
28 |
|
// clang-format on |
29 |
|
|
30 |
|
namespace cvc5::options { |
31 |
|
|
32 |
|
// clang-format off |
33 |
|
enum class EqEngineMode |
34 |
|
{ |
35 |
|
DISTRIBUTED, CENTRAL, |
36 |
|
__MAX_VALUE = CENTRAL |
37 |
|
}; |
38 |
|
std::ostream& operator<<(std::ostream& os, EqEngineMode mode); |
39 |
|
EqEngineMode stringToEqEngineMode(const std::string& optarg); |
40 |
|
|
41 |
|
enum class TcMode |
42 |
|
{ |
43 |
|
CARE_GRAPH, |
44 |
|
__MAX_VALUE = CARE_GRAPH |
45 |
|
}; |
46 |
|
std::ostream& operator<<(std::ostream& os, TcMode mode); |
47 |
|
TcMode stringToTcMode(const std::string& optarg); |
48 |
|
|
49 |
|
enum class TheoryOfMode |
50 |
|
{ |
51 |
|
THEORY_OF_TYPE_BASED, THEORY_OF_TERM_BASED, |
52 |
|
__MAX_VALUE = THEORY_OF_TERM_BASED |
53 |
|
}; |
54 |
|
std::ostream& operator<<(std::ostream& os, TheoryOfMode mode); |
55 |
|
TheoryOfMode stringToTheoryOfMode(const std::string& optarg); |
56 |
|
|
57 |
|
// clang-format on |
58 |
|
|
59 |
|
#if defined(CVC5_MUZZLED) || defined(CVC5_COMPETITION_MODE) |
60 |
|
# define DO_SEMANTIC_CHECKS_BY_DEFAULT false |
61 |
|
#else /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */ |
62 |
|
# define DO_SEMANTIC_CHECKS_BY_DEFAULT true |
63 |
|
#endif /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */ |
64 |
|
|
65 |
30747 |
struct HolderTHEORY |
66 |
|
{ |
67 |
|
// clang-format off |
68 |
|
bool assignFunctionValues = true; |
69 |
|
bool assignFunctionValuesWasSetByUser = false; |
70 |
|
bool condenseFunctionValues = true; |
71 |
|
bool condenseFunctionValuesWasSetByUser = false; |
72 |
|
EqEngineMode eeMode = EqEngineMode::DISTRIBUTED; |
73 |
|
bool eeModeWasSetByUser = false; |
74 |
|
bool relevanceFilter = false; |
75 |
|
bool relevanceFilterWasSetByUser = false; |
76 |
|
TcMode tcMode = TcMode::CARE_GRAPH; |
77 |
|
bool tcModeWasSetByUser = false; |
78 |
|
TheoryOfMode theoryOfMode = TheoryOfMode::THEORY_OF_TYPE_BASED; |
79 |
|
bool theoryOfModeWasSetByUser = false; |
80 |
|
// clang-format on |
81 |
|
}; |
82 |
|
|
83 |
|
#undef DO_SEMANTIC_CHECKS_BY_DEFAULT |
84 |
|
|
85 |
|
// clang-format off |
86 |
|
inline bool assignFunctionValues() { return Options::current().theory.assignFunctionValues; } |
87 |
|
inline bool condenseFunctionValues() { return Options::current().theory.condenseFunctionValues; } |
88 |
25006015 |
inline EqEngineMode eeMode() { return Options::current().theory.eeMode; } |
89 |
|
inline bool relevanceFilter() { return Options::current().theory.relevanceFilter; } |
90 |
|
inline TcMode tcMode() { return Options::current().theory.tcMode; } |
91 |
200618934 |
inline TheoryOfMode theoryOfMode() { return Options::current().theory.theoryOfMode; } |
92 |
|
// clang-format on |
93 |
|
|
94 |
|
} // namespace cvc5::options |
95 |
|
|
96 |
|
#endif /* CVC5__OPTIONS__THEORY_H */ |