GCC Code Coverage Report
Directory: . Exec Total Coverage
File: build-coverage/src/options/proof_options.h Lines: 6 6 100.0 %
Date: 2021-08-16 Branches: 0 0 0.0 %

Line Exec Source
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__PROOF_H
22
#define CVC5__OPTIONS__PROOF_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
34
enum class ProofFormatMode
35
{
36
  NONE,
37
  DOT,
38
  VERIT
39
};
40
41
static constexpr size_t ProofFormatMode__numValues = 3;
42
43
std::ostream& operator<<(std::ostream& os, ProofFormatMode mode);
44
ProofFormatMode stringToProofFormatMode(const std::string& optarg);
45
46
enum class ProofGranularityMode
47
{
48
  REWRITE,
49
  DSL_REWRITE,
50
  THEORY_REWRITE,
51
  OFF
52
};
53
54
static constexpr size_t ProofGranularityMode__numValues = 4;
55
56
std::ostream& operator<<(std::ostream& os, ProofGranularityMode mode);
57
ProofGranularityMode stringToProofGranularityMode(const std::string& optarg);
58
// clang-format on
59
60
#if defined(CVC5_MUZZLED) || defined(CVC5_COMPETITION_MODE)
61
#  define DO_SEMANTIC_CHECKS_BY_DEFAULT false
62
#else /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */
63
#  define DO_SEMANTIC_CHECKS_BY_DEFAULT true
64
#endif /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */
65
66
27407
struct HolderPROOF
67
{
68
// clang-format off
69
  bool proofEagerChecking = false;
70
  bool proofEagerCheckingWasSetByUser = false;
71
  ProofFormatMode proofFormatMode = ProofFormatMode::NONE;
72
  bool proofFormatModeWasSetByUser = false;
73
  ProofGranularityMode proofGranularityMode = ProofGranularityMode::THEORY_REWRITE;
74
  bool proofGranularityModeWasSetByUser = false;
75
  uint64_t proofPedantic = 0;
76
  bool proofPedanticWasSetByUser = false;
77
  bool proofPrintConclusion = false;
78
  bool proofPrintConclusionWasSetByUser = false;
79
// clang-format on
80
};
81
82
#undef DO_SEMANTIC_CHECKS_BY_DEFAULT
83
84
// clang-format off
85
14409213
inline bool proofEagerChecking() { return Options::current().proof.proofEagerChecking; }
86
3777
inline ProofFormatMode proofFormatMode() { return Options::current().proof.proofFormatMode; }
87
6122
inline ProofGranularityMode proofGranularityMode() { return Options::current().proof.proofGranularityMode; }
88
3768
inline uint64_t proofPedantic() { return Options::current().proof.proofPedantic; }
89
241849
inline bool proofPrintConclusion() { return Options::current().proof.proofPrintConclusion; }
90
// clang-format on
91
92
namespace proof
93
{
94
// clang-format off
95
static constexpr const char* proofEagerChecking__name = "proof-eager-checking";
96
static constexpr const char* proofFormatMode__name = "proof-format-mode";
97
static constexpr const char* proofGranularityMode__name = "proof-granularity";
98
static constexpr const char* proofPedantic__name = "proof-pedantic";
99
static constexpr const char* proofPrintConclusion__name = "proof-print-conclusion";
100
101
void setDefaultProofEagerChecking(Options& opts, bool value);void setDefaultProofFormatMode(Options& opts, ProofFormatMode value);void setDefaultProofGranularityMode(Options& opts, ProofGranularityMode value);void setDefaultProofPedantic(Options& opts, uint64_t value);void setDefaultProofPrintConclusion(Options& opts, bool value);
102
// clang-format on
103
}
104
105
}  // namespace cvc5::options
106
107
#endif /* CVC5__OPTIONS__PROOF_H */