bm->UserFlags.print_arrayval_declaredorder_flag = true;
break;
case 'r':
- bm->UserFlags.arrayread_refinement_flag = false;
+ bm->UserFlags.ackermannisation = true;
break;
case 's' :
bm->UserFlags.stats_flag = true;
// This establishes equalities between every indexes, and a fresh variable.
- if (bm->UserFlags.arrayread_refinement_flag)
+ if (!bm->UserFlags.ackermannisation)
{
ASTNodeMap replaced;
result = CurrentSymbol;
- if (bm->UserFlags.arrayread_refinement_flag)
+ if (!bm->UserFlags.ackermannisation)
{
// result is a variable here; it is an ite in the
// else-branch
// TODO: Should be enabled irrespective of whether refinement is enabled.
// TODO: I chose the number of reads we perform this operation at randomly.
bool removed = false;
- if (!bm->UserFlags.arrayread_refinement_flag && numberOfReadsLessThan(simplified_solved_InputToSAT,50))
+ if (bm->UserFlags.ackermannisation && numberOfReadsLessThan(simplified_solved_InputToSAT,50))
{
// If the number of axioms that would be added it small. Remove them.
simplified_solved_InputToSAT = arrayTransformer->TransformFormula_TopLevel(simplified_solved_InputToSAT);
bm->UserFlags.optimize_flag = optimize_enabled;
SOLVER_RETURN_TYPE res;
- if (bm->UserFlags.arrayread_refinement_flag)
+ if (!bm->UserFlags.ackermannisation)
{
bm->counterexample_checking_during_refinement = true;
}
if (bm->UserFlags.stats_flag)
simp->printCacheStatus();
- const bool maybeRefinement = arrayops && bm->UserFlags.arrayread_refinement_flag;
+ const bool maybeRefinement = arrayops && !bm->UserFlags.ackermannisation;
simplifier::constantBitP::ConstantBitPropagation* cb = NULL;
std::auto_ptr<simplifier::constantBitP::ConstantBitPropagation> cleaner;
}
assert(arrayops); // should only go to abstraction refinement if there are array ops.
- assert(bm->UserFlags.arrayread_refinement_flag); // Refinement must be enabled too.
+ assert(!bm->UserFlags.ackermannisation); // Refinement must be enabled too.
assert (bm->UserFlags.solver_to_use != UserDefinedFlags::MINISAT_PROPAGATORS); // The array solver shouldn't have returned undecided..
res = Ctr_Example->SATBased_ArrayReadRefinement(NewSolver, simplified_solved_InputToSAT, original_input, satBase);
//run STP in optimized mode
bool optimize_flag;
- //do sat refinement, i.e. underconstraint the problem, and feed to
+ //do sat refinement, i.e. underconstrain the problem, and feed to
//SAT. if this works, great. else, add a set of suitable constraints
//to re-constraint the problem correctly, and call SAT again, until
//all constraints have been added.
- bool arrayread_refinement_flag;
+ bool ackermannisation; // eagerly write through the array's function congruence axioms.
//switch to control write refinements
//bool arraywrite_refinement_flag;
// SAT. if this works, great. else, add a set of suitable
// constraints to re-constraint the problem correctly, and call SAT again,
// until all constraints have been added.
- arrayread_refinement_flag = true;
+ ackermannisation = false;
//flag to control write refinement
//arraywrite_refinement_flag = true;
}
// One modified version of Minisat has an array propagator based solver built in. So this block sends the details of the arrays to it.
- if ((bm->UserFlags.solver_to_use == UserDefinedFlags::MINISAT_PROPAGATORS) && bm->UserFlags.arrayread_refinement_flag )
+ if ((bm->UserFlags.solver_to_use == UserDefinedFlags::MINISAT_PROPAGATORS) && !bm->UserFlags.ackermannisation )
{
int array_id = 0; // Is incremented for each distinct array.
bool found = false;