15 const double factor = (ratio <= 2) ? 1.0 : log (ratio) / log (2);
29 memset (
this, 0,
sizeof *
this);
34 if (l <= 0 && !
lim.terminate.forced) {
35 LOG (
"keeping unbounded terminate limit");
37 LOG (
"reset terminate limit to be unbounded");
38 lim.terminate.forced = 0;
40 lim.terminate.forced = l;
41 LOG (
"new terminate limit of %d calls", l);
46 if (l < 0 &&
inc.conflicts < 0) {
47 LOG (
"keeping unbounded conflict limit");
49 LOG (
"reset conflict limit to be unbounded");
53 LOG (
"new conflict limit of %d conflicts", l);
58 if (l < 0 &&
inc.decisions < 0) {
59 LOG (
"keeping unbounded decision limit");
61 LOG (
"reset decision limit to be unbounded");
65 LOG (
"new decision limit of %d decisions", l);
71 LOG (
"ignoring invalid preprocessing limit %d", l);
73 LOG (
"reset preprocessing limit to no preprocessing");
74 inc.preprocessing = 0;
76 inc.preprocessing = l;
77 LOG (
"new preprocessing limit of %d preprocessing rounds", l);
83 LOG (
"ignoring invalid local search limit %d", l);
85 LOG (
"reset local search limit to no local search");
89 LOG (
"new local search limit of %d local search rounds", l);
125 LOG (
"reset limits");
#define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END
double clause_variable_ratio() const
double scale(double v) const
static bool is_valid_limit(const char *name)
void limit_local_search(int)
void limit_terminate(int)
bool limit(const char *name, int)
void limit_preprocessing(int)
void limit_decisions(int)
void limit_conflicts(int)