GCC Code Coverage Report
Directory: . Exec Total Coverage
File: build-coverage/src/options/proof_options.h Lines: 6 6 100.0 %
Date: 2021-08-20 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
  TPTP,
37
  DOT,
38
  VERIT,
39
  NONE
40
};
41
42
static constexpr size_t ProofFormatMode__numValues = 4;
43
44
std::ostream& operator<<(std::ostream& os, ProofFormatMode mode);
45
ProofFormatMode stringToProofFormatMode(const std::string& optarg);
46
47
enum class ProofGranularityMode
48
{
49
  OFF,
50
  DSL_REWRITE,
51
  THEORY_REWRITE,
52
  REWRITE
53
};
54
55
static constexpr size_t ProofGranularityMode__numValues = 4;
56
57
std::ostream& operator<<(std::ostream& os, ProofGranularityMode mode);
58
ProofGranularityMode stringToProofGranularityMode(const std::string& optarg);
59
// clang-format on
60
61
#if defined(CVC5_MUZZLED) || defined(CVC5_COMPETITION_MODE)
62
#  define DO_SEMANTIC_CHECKS_BY_DEFAULT false
63
#else /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */
64
#  define DO_SEMANTIC_CHECKS_BY_DEFAULT true
65
#endif /* CVC5_MUZZLED || CVC5_COMPETITION_MODE */
66
67
27444
struct HolderPROOF
68
{
69
// clang-format off
70
  bool proofEagerChecking = false;
71
  bool proofEagerCheckingWasSetByUser = false;
72
  ProofFormatMode proofFormatMode = ProofFormatMode::NONE;
73
  bool proofFormatModeWasSetByUser = false;
74
  ProofGranularityMode proofGranularityMode = ProofGranularityMode::THEORY_REWRITE;
75
  bool proofGranularityModeWasSetByUser = false;
76
  uint64_t proofPedantic = 0;
77
  bool proofPedanticWasSetByUser = false;
78
  bool proofPrintConclusion = false;
79
  bool proofPrintConclusionWasSetByUser = false;
80
// clang-format on
81
};
82
83
#undef DO_SEMANTIC_CHECKS_BY_DEFAULT
84
85
// clang-format off
86
14391551
inline bool proofEagerChecking() { return Options::current().proof.proofEagerChecking; }
87
3785
inline ProofFormatMode proofFormatMode() { return Options::current().proof.proofFormatMode; }
88
6127
inline ProofGranularityMode proofGranularityMode() { return Options::current().proof.proofGranularityMode; }
89
3771
inline uint64_t proofPedantic() { return Options::current().proof.proofPedantic; }
90
240297
inline bool proofPrintConclusion() { return Options::current().proof.proofPrintConclusion; }
91
// clang-format on
92
93
namespace proof
94
{
95
// clang-format off
96
static constexpr const char* proofEagerChecking__name = "proof-eager-checking";
97
static constexpr const char* proofFormatMode__name = "proof-format-mode";
98
static constexpr const char* proofGranularityMode__name = "proof-granularity";
99
static constexpr const char* proofPedantic__name = "proof-pedantic";
100
static constexpr const char* proofPrintConclusion__name = "proof-print-conclusion";
101
102
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);
103
// clang-format on
104
}
105
106
}  // namespace cvc5::options
107
108
#endif /* CVC5__OPTIONS__PROOF_H */