registerNode( qn, true, true );
Trace("qcf-qregister") << "- Make match gen structure..." << std::endl;
- d_mg.reset(new MatchGen(p, this, qn));
+ d_mg = std::make_unique<MatchGen>(d_env, p, this, qn);
if( d_mg->isValid() ){
for (size_t j = q[0].getNumChildren(), nvars = d_vars.size(); j < nvars;
}
if (!is_tsym || options().quantifiers.cbqiTConstraint)
{
- d_var_mg[j] = std::make_unique<MatchGen>(p, this, d_vars[j], true);
+ d_var_mg[j] = std::make_unique<MatchGen>(d_env, p, this, d_vars[j], true);
}
if( !d_var_mg[j] || !d_var_mg[j]->isValid() ){
Trace("qcf-invalid")
}
}
-MatchGen::MatchGen(QuantConflictFind* p, QuantInfo* qi, Node n, bool isVar)
- : d_tgt(),
+MatchGen::MatchGen(Env& env, QuantConflictFind* p, QuantInfo* qi, Node n, bool isVar)
+ : EnvObj(env),
+ d_tgt(),
d_tgt_orig(),
d_wasSet(),
d_n(),
for( unsigned i=0; i<d_n.getNumChildren(); i++ ){
if( d_n.getKind()!=FORALL || i==1 ){
std::unique_ptr<MatchGen> mg =
- std::make_unique<MatchGen>(p, qi, d_n[i], false);
+ std::make_unique<MatchGen>(d_env, p, qi, d_n[i], false);
if (!mg->isValid())
{
setInvalid();
Assert(d_n.getType().isBoolean());
d_type = typ_bool_var;
}
- else if (d_n.getKind() == EQUAL || options::cbqiTConstraint())
+ else if (d_n.getKind() == EQUAL || options().quantifiers.cbqiTConstraint)
{
for (unsigned i = 0; i < d_n.getNumChildren(); i++)
{
<< vu_count[i] << std::endl;
int score0 = 0;//has_nested[i] ? 0 : 1;
int score;
- if (!options::cbqiVoExp())
+ if (!options().quantifiers.cbqiVoExp)
{
score = vu_count[i];
}
d_child_counter = 0;
}
}
- else if (d_qi->isBaseMatchComplete() && options::cbqiEagerTest())
+ else if (d_qi->isBaseMatchComplete() && options().quantifiers.cbqiEagerTest)
{
d_use_children = false;
d_child_counter = 0;
// Returns the beginning of a range of efforts. The value returned is included
// in the range.
-inline QuantConflictFind::Effort QcfEffortEnd() {
- return options::cbqiMode() == options::QcfMode::PROP_EQ
+inline QuantConflictFind::Effort QcfEffortEnd(options::QcfMode m) {
+ return m == options::QcfMode::PROP_EQ
? QuantConflictFind::EFFORT_PROP_EQ
: QuantConflictFind::EFFORT_CONFLICT;
}
FirstOrderModel* fm = d_treg.getModel();
unsigned nquant = fm->getNumAssertedQuantifiers();
// for each effort level (find conflict, find propagating)
- for (unsigned e = QcfEffortStart(), end = QcfEffortEnd(); e <= end; ++e)
+ unsigned end = QcfEffortEnd(options().quantifiers.cbqiMode);
+ for (unsigned e = QcfEffortStart(); e <= end; ++e)
{
// set the effort (data member for convienence of access)
d_effort = static_cast<Effort>(e);