ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
cadical_var.cpp
Go to the documentation of this file.
1#include "global.h"
2
3#include "internal.hpp"
4
6
7namespace CaDiCaL {
8
10 LOG ("marking all variables as not subsume");
11 for (auto idx : vars)
12 flags (idx).subsume = false;
13}
14
16#ifndef CADICAL_NDEBUG
17 int64_t fixed = 0, eliminated = 0, substituted = 0, pure = 0, unused = 0;
18 for (auto idx : vars) {
19 Flags &f = flags (idx);
20 if (f.active ())
21 continue;
22 if (f.fixed ())
23 fixed++;
24 if (f.eliminated ())
25 eliminated++;
26 if (f.substituted ())
27 substituted++;
28 if (f.unused ())
29 unused++;
30 if (f.pure ())
31 pure++;
32 }
33 CADICAL_assert (stats.now.fixed == fixed);
34 CADICAL_assert (stats.now.eliminated == eliminated);
35 CADICAL_assert (stats.now.substituted == substituted);
36 CADICAL_assert (stats.now.pure == pure);
37 int64_t inactive = unused + fixed + eliminated + substituted + pure;
38 CADICAL_assert (stats.inactive == inactive);
39 CADICAL_assert (max_var == stats.active + stats.inactive);
40#endif
41}
42
43} // namespace CaDiCaL
44
#define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END
#define CADICAL_assert(ignore)
Definition global.h:14
#define LOG(...)
const char * flags()
bool eliminated() const
Definition flags.hpp:71
bool substituted() const
Definition flags.hpp:72
bool fixed() const
Definition flags.hpp:70
bool unused() const
Definition flags.hpp:68
bool pure() const
Definition flags.hpp:73
bool active() const
Definition flags.hpp:69
int fixed(int lit)
void reset_subsume_bits()
const Range vars
Definition internal.hpp:324