// implied options
if (opts.smt.debugCheckModels)
{
- opts.smt.checkModels = true;
+ opts.writeSmt().checkModels = true;
}
if (opts.smt.checkModels || opts.driver.dumpModels)
{
- opts.smt.produceModels = true;
+ opts.writeSmt().produceModels = true;
}
if (opts.smt.checkModels)
{
- opts.smt.produceAssignments = true;
+ opts.writeSmt().produceAssignments = true;
}
// unsat cores and proofs shenanigans
if (opts.driver.dumpDifficulty)
{
- opts.smt.produceDifficulty = true;
+ opts.writeSmt().produceDifficulty = true;
}
if (opts.smt.checkUnsatCores || opts.driver.dumpUnsatCores
|| opts.smt.unsatAssumptions || opts.smt.minimalUnsatCores
|| opts.smt.unsatCoresMode != options::UnsatCoresMode::OFF)
{
- opts.smt.unsatCores = true;
+ opts.writeSmt().unsatCores = true;
}
if (opts.smt.unsatCores
&& opts.smt.unsatCoresMode == options::UnsatCoresMode::OFF)
notifyModifyOption(
"unsatCoresMode", "assumptions", "enabling unsat cores");
}
- opts.smt.unsatCoresMode = options::UnsatCoresMode::ASSUMPTIONS;
+ opts.writeSmt().unsatCoresMode = options::UnsatCoresMode::ASSUMPTIONS;
}
// if check-proofs, dump-proofs, or proof-mode=full, then proofs being fully
// enabled is implied
if (opts.smt.checkProofs || opts.driver.dumpProofs
|| opts.smt.proofMode == options::ProofMode::FULL)
{
- opts.smt.produceProofs = true;
+ opts.writeSmt().produceProofs = true;
}
// this check assumes the user has requested *full* proofs
if (opts.smt.produceProofs)
{
// if the user requested proofs, proof mode is full
- opts.smt.proofMode = options::ProofMode::FULL;
+ opts.writeSmt().proofMode = options::ProofMode::FULL;
// unsat cores are available due to proofs being enabled
if (opts.smt.unsatCoresMode != options::UnsatCoresMode::SAT_PROOF)
{
{
notifyModifyOption("unsatCoresMode", "sat-proof", "enabling proofs");
}
- opts.smt.unsatCores = true;
- opts.smt.unsatCoresMode = options::UnsatCoresMode::SAT_PROOF;
+ opts.writeSmt().unsatCores = true;
+ opts.writeSmt().unsatCoresMode = options::UnsatCoresMode::SAT_PROOF;
}
}
if (!opts.smt.produceProofs)
{
// if (expert) user set proof mode to something other than off, enable
// proofs
- opts.smt.produceProofs = true;
+ opts.writeSmt().produceProofs = true;
}
// if proofs weren't enabled by user, and we are producing difficulty
if (opts.smt.produceDifficulty)
{
- opts.smt.produceProofs = true;
+ opts.writeSmt().produceProofs = true;
// ensure at least preprocessing proofs are enabled
if (opts.smt.proofMode == options::ProofMode::OFF)
{
- opts.smt.proofMode = options::ProofMode::PP_ONLY;
+ opts.writeSmt().proofMode = options::ProofMode::PP_ONLY;
}
}
// if proofs weren't enabled by user, and we are producing unsat cores
if (opts.smt.unsatCores)
{
- opts.smt.produceProofs = true;
+ opts.writeSmt().produceProofs = true;
if (opts.smt.unsatCoresMode == options::UnsatCoresMode::SAT_PROOF)
{
// if requested to be based on proofs, we produce (preprocessing +) SAT
// proofs
- opts.smt.proofMode = options::ProofMode::SAT;
+ opts.writeSmt().proofMode = options::ProofMode::SAT;
}
else if (opts.smt.proofMode == options::ProofMode::OFF)
{
// otherwise, we always produce preprocessing proofs
- opts.smt.proofMode = options::ProofMode::PP_ONLY;
+ opts.writeSmt().proofMode = options::ProofMode::PP_ONLY;
}
}
}
{
// these options must be disabled on internal subsolvers, as they are
// used by the user to rephrase the input.
- opts.quantifiers.sygusInference = false;
- opts.quantifiers.sygusRewSynthInput = false;
+ opts.writeQuantifiers().sygusInference = false;
+ opts.writeQuantifiers().sygusRewSynthInput = false;
// deep restart does not work with internal subsolvers?
- opts.smt.deepRestartMode = options::DeepRestartMode::NONE;
+ opts.writeSmt().deepRestartMode = options::DeepRestartMode::NONE;
}
}
&& logic.areIntegersUsed()))
&& !opts.base.incrementalSolving)
{
- opts.quantifiers.sygusInst = true;
+ opts.writeQuantifiers().sygusInst = true;
}
if (opts.bv.bitblastMode == options::BitblastMode::EAGER)
"functions. Try --bitblast=lazy"));
}
notifyModifyOption("bitblastMode", "lazy", "model generation");
- opts.bv.bitblastMode = options::BitblastMode::LAZY;
+ opts.writeBv().bitblastMode = options::BitblastMode::LAZY;
}
else if (!opts.base.incrementalSolving)
{
// if not incremental, we rely on ackermann to eliminate other theories.
- opts.smt.ackermann = true;
+ opts.writeSmt().ackermann = true;
}
else if (logic.isQuantified() || !logic.isPure(THEORY_BV))
{
"Ackermannization currently does not support model generation."));
}
notifyModifyOption("ackermann", "false", "model generation");
- opts.smt.ackermann = false;
+ opts.writeSmt().ackermann = false;
// we are not relying on ackermann to eliminate theories in this case
Assert(opts.bv.bitblastMode != options::BitblastMode::EAGER);
}
{
// If the user explicitly set a logic that includes strings, but is not
// the generic "ALL" logic, then enable stringsExp.
- opts.strings.stringExp = true;
+ opts.writeStrings().stringExp = true;
Trace("smt") << "Turning stringExp on since logic does not have everything "
"and string theory is enabled\n";
}
if (!opts.smt.produceAssertions)
{
verbose(1) << "SolverEngine: turning on produce-assertions." << std::endl;
- opts.smt.produceAssertions = true;
+ opts.writeSmt().produceAssertions = true;
}
if (opts.smt.solveBVAsInt != options::SolveBVAsIntMode::OFF)
* Therefore, we enable bv-to-bool, which runs before
* the translation to integers.
*/
- opts.bv.bitvectorToBool = true;
+ opts.writeBv().bitvectorToBool = true;
}
// Disable options incompatible with incremental solving, or output an error
&& !logic.isTheoryEnabled(THEORY_ARITH);
Trace("smt") << "setting unconstrained simplification to " << uncSimp
<< std::endl;
- opts.smt.unconstrainedSimp = uncSimp;
+ opts.writeSmt().unconstrainedSimp = uncSimp;
}
// by default, nonclausal simplification is off for QF_SAT
// quantifiers, not others opts.set(options::simplificationMode, qf_sat ||
// quantifiers ? options::SimplificationMode::NONE :
// options::SimplificationMode::BATCH);
- opts.smt.simplificationMode = qf_sat ? options::SimplificationMode::NONE
- : options::SimplificationMode::BATCH;
+ opts.writeSmt().simplificationMode =
+ qf_sat ? options::SimplificationMode::NONE
+ : options::SimplificationMode::BATCH;
}
}
verbose(1)
<< "SolverEngine: turning off bool-to-bitvector to support CBQI BV"
<< std::endl;
- opts.bv.boolToBitvector = options::BoolToBVMode::OFF;
+ opts.writeBv().boolToBitvector = options::BoolToBVMode::OFF;
}
}
&& (opts.smt.produceAssignments || usesSygus(opts)))
{
verbose(1) << "SolverEngine: turning on produce-models" << std::endl;
- opts.smt.produceModels = true;
+ opts.writeSmt().produceModels = true;
}
// --ite-simp is an experimental option designed for QF_LIA/nec. This
{
if (!opts.smt.earlyIteRemovalWasSetByUser)
{
- opts.smt.earlyIteRemoval = true;
+ opts.writeSmt().earlyIteRemoval = true;
}
}
&& !logic.isQuantified()))
{
Trace("smt") << "setting theoryof-mode to term-based" << std::endl;
- opts.theory.theoryOfMode = options::TheoryOfMode::THEORY_OF_TERM_BASED;
+ opts.writeTheory().theoryOfMode =
+ options::TheoryOfMode::THEORY_OF_TERM_BASED;
}
}
&& !safeUnsatCores(opts);
Trace("smt") << "setting uf symmetry breaker to " << qf_uf_noinc
<< std::endl;
- opts.uf.ufSymmetryBreaker = qf_uf_noinc;
+ opts.writeUf().ufSymmetryBreaker = qf_uf_noinc;
}
// If in arrays, set the UF handler to arrays
bool withCare = qf_aufbv;
Trace("smt") << "setting ite simplify with care to " << withCare
<< std::endl;
- opts.smt.simplifyWithCareEnabled = withCare;
+ opts.writeSmt().simplifyWithCareEnabled = withCare;
}
// Turn off array eager index splitting for QF_AUFLIA
if (!opts.arrays.arraysEagerIndexSplittingWasSetByUser)
{
Trace("smt") << "setting array eager index splitting to false"
<< std::endl;
- opts.arrays.arraysEagerIndexSplitting = false;
+ opts.writeArrays().arraysEagerIndexSplitting = false;
}
}
// Turn on multiple-pass non-clausal simplification for QF_AUFBV
&& !safeUnsatCores(opts);
Trace("smt") << "setting repeat simplification to " << repeatSimp
<< std::endl;
- opts.smt.repeatSimp = repeatSimp;
+ opts.writeSmt().repeatSimp = repeatSimp;
}
/* Disable bit-level propagation by default for the BITBLAST solver. */
if (opts.bv.bvSolver == options::BVSolver::BITBLAST)
{
- opts.bv.bitvectorPropagate = false;
+ opts.writeBv().bitvectorPropagate = false;
}
if (opts.bv.boolToBitvector == options::BoolToBVMode::ALL
}
verbose(1) << "SolverEngine: turning off bool-to-bv for non-bv logic: "
<< logic.getLogicString() << std::endl;
- opts.bv.boolToBitvector = options::BoolToBVMode::OFF;
+ opts.writeBv().boolToBitvector = options::BoolToBVMode::OFF;
}
// Turn on arith rewrite equalities only for pure arithmetic
logic.isPure(THEORY_ARITH) && logic.isLinear() && !logic.isQuantified();
Trace("smt") << "setting arith rewrite equalities " << arithRewriteEq
<< std::endl;
- opts.arith.arithRewriteEq = arithRewriteEq;
+ opts.writeArith().arithRewriteEq = arithRewriteEq;
}
if (!opts.arith.arithHeuristicPivotsWasSetByUser)
{
}
Trace("smt") << "setting arithHeuristicPivots " << heuristicPivots
<< std::endl;
- opts.arith.arithHeuristicPivots = heuristicPivots;
+ opts.writeArith().arithHeuristicPivots = heuristicPivots;
}
if (!opts.arith.arithPivotThresholdWasSetByUser)
{
}
Trace("smt") << "setting arith arithPivotThreshold " << pivotThreshold
<< std::endl;
- opts.arith.arithPivotThreshold = pivotThreshold;
+ opts.writeArith().arithPivotThreshold = pivotThreshold;
}
if (!opts.arith.arithStandardCheckVarOrderPivotsWasSetByUser)
{
}
Trace("smt") << "setting arithStandardCheckVarOrderPivots "
<< varOrderPivots << std::endl;
- opts.arith.arithStandardCheckVarOrderPivots = varOrderPivots;
+ opts.writeArith().arithStandardCheckVarOrderPivots = varOrderPivots;
}
if (logic.isPure(THEORY_ARITH) && !logic.areRealsUsed())
{
{
Trace("smt") << "setting nlExtTangentPlanesInterleave to true"
<< std::endl;
- opts.arith.nlExtTangentPlanesInterleave = true;
+ opts.writeArith().nlExtTangentPlanesInterleave = true;
}
}
if (!opts.arith.nlRlvAssertBoundsWasSetByUser)
{
// use bound inference to determine when bounds are irrelevant only when
// the logic is quantifier-free
- opts.arith.nlRlvAssertBounds = !logic.isQuantified();
+ opts.writeArith().nlRlvAssertBounds = !logic.isQuantified();
}
// set the default decision mode
if (!opts.arith.arithEqSolverWasSetByUser)
{
// use the arithmetic equality solver by default
- opts.arith.arithEqSolver = true;
+ opts.writeArith().arithEqSolver = true;
}
}
if (!opts.theory.assignFunctionValues)
{
// must assign function values
- opts.theory.assignFunctionValues = true;
+ opts.writeTheory().assignFunctionValues = true;
}
}
Trace("smt")
<< "Disabling shared selectors for quantified logic without SyGuS"
<< std::endl;
- opts.datatypes.dtSharedSelectors = false;
+ opts.writeDatatypes().dtSharedSelectors = false;
}
}
|| opts.smt.checkModels
|| (logic.isTheoryEnabled(THEORY_ARITH) && !logic.isLinear()))
{
- opts.prop.minisatSimpMode = options::MinisatSimpMode::CLAUSE_ELIM;
+ opts.writeProp().minisatSimpMode = options::MinisatSimpMode::CLAUSE_ELIM;
}
}
<< opts.arith.nlRlvMode << std::endl;
}
// must use relevance filtering techniques
- opts.theory.relevanceFilter = true;
+ opts.writeTheory().relevanceFilter = true;
}
}
if (opts.smt.produceModels || opts.smt.produceAssignments
|| opts.smt.checkModels)
{
- opts.arrays.arraysOptimizeLinear = false;
+ opts.writeArrays().arraysOptimizeLinear = false;
}
if (opts.strings.stringFMF && !opts.strings.stringProcessLoopModeWasSetByUser)
Trace("smt") << "settting stringProcessLoopMode to 'simple' since "
"--strings-fmf enabled"
<< std::endl;
- opts.strings.stringProcessLoopMode = options::ProcessLoopMode::SIMPLE;
+ opts.writeStrings().stringProcessLoopMode =
+ options::ProcessLoopMode::SIMPLE;
}
// !!! All options that require disabling models go here
}
verbose(1) << "SolverEngine: turning off produce-models to support "
<< sOptNoModel << std::endl;
- opts.smt.produceModels = false;
+ opts.writeSmt().produceModels = false;
}
if (opts.smt.produceAssignments)
{
}
verbose(1) << "SolverEngine: turning off produce-assignments to support "
<< sOptNoModel << std::endl;
- opts.smt.produceAssignments = false;
+ opts.writeSmt().produceAssignments = false;
}
if (opts.smt.checkModels)
{
}
verbose(1) << "SolverEngine: turning off check-models to support "
<< sOptNoModel << std::endl;
- opts.smt.checkModels = false;
+ opts.writeSmt().checkModels = false;
}
}
{
if (!opts.arith.nlCov && !opts.arith.nlCovWasSetByUser)
{
- opts.arith.nlCov = true;
+ opts.writeArith().nlCov = true;
if (!opts.arith.nlExtWasSetByUser)
{
- opts.arith.nlExt = options::NlExtMode::LIGHT;
+ opts.writeArith().nlExt = options::NlExtMode::LIGHT;
}
if (!opts.arith.nlRlvModeWasSetByUser)
{
- opts.arith.nlRlvMode = options::NlRlvMode::INTERLEAVE;
+ opts.writeArith().nlRlvMode = options::NlRlvMode::INTERLEAVE;
}
}
}
{
if (!opts.arith.nlCov && !opts.arith.nlCovWasSetByUser)
{
- opts.arith.nlCov = true;
+ opts.writeArith().nlCov = true;
if (!opts.arith.nlExtWasSetByUser)
{
- opts.arith.nlExt = options::NlExtMode::LIGHT;
+ opts.writeArith().nlExt = options::NlExtMode::LIGHT;
}
}
}
{
verbose(1) << "Cannot use --nl-cov without configuring with --poly."
<< std::endl;
- opts.arith.nlCov = false;
- opts.arith.nlExt = options::NlExtMode::FULL;
+ opts.writeArith().nlCov = false;
+ opts.writeArith().nlExt = options::NlExtMode::FULL;
}
}
#endif
{
if (!opts.arith.nlExtWasSetByUser)
{
- opts.arith.nlExt = options::NlExtMode::FULL;
+ opts.writeArith().nlExt = options::NlExtMode::FULL;
}
}
}
verbose(1)
<< "Disabling bv-assert-input since it is incompatible with proofs."
<< std::endl;
- opts.bv.bvAssertInput = false;
+ opts.writeBv().bvAssertInput = false;
}
// If proofs are required and the user did not specify a specific BV solver,
// we make sure to use the proof producing BITBLAST_INTERNAL solver.
{
verbose(1) << "Forcing internal bit-vector solver due to proof production."
<< std::endl;
- opts.bv.bvSolver = options::BVSolver::BITBLAST_INTERNAL;
+ opts.writeBv().bvSolver = options::BVSolver::BITBLAST_INTERNAL;
}
if (opts.arith.nlCovVarElim && !opts.arith.nlCovVarElimWasSetByUser)
{
verbose(1)
<< "Disabling nl-cov-var-elim since it is incompatible with proofs."
<< std::endl;
- opts.arith.nlCovVarElim = false;
+ opts.writeArith().nlCovVarElim = false;
}
if (opts.smt.deepRestartMode != options::DeepRestartMode::NONE)
{
return true;
}
notifyModifyOption("unconstrainedSimp", "false", "incremental solving");
- opts.smt.unconstrainedSimp = false;
+ opts.writeSmt().unconstrainedSimp = false;
}
if (opts.bv.bitblastMode == options::BitblastMode::EAGER
&& !logic.isPure(THEORY_BV))
return true;
}
notifyModifyOption("sygusInference", "false", "incremental solving");
- opts.quantifiers.sygusInference = false;
+ opts.writeQuantifiers().sygusInference = false;
}
if (opts.quantifiers.sygusInst)
{
return true;
}
notifyModifyOption("sygusInst", "false", "incremental solving");
- opts.quantifiers.sygusInst = false;
+ opts.writeQuantifiers().sygusInst = false;
}
if (opts.smt.solveIntAsBV > 0)
{
// disable modes not supported by incremental
notifyModifyOption("sortInference", "false", "incremental solving");
- opts.smt.sortInference = false;
- opts.uf.ufssFairnessMonotone = false;
+ opts.writeSmt().sortInference = false;
+ opts.writeUf().ufssFairnessMonotone = false;
notifyModifyOption("globalNegate", "false", "incremental solving");
- opts.quantifiers.globalNegate = false;
+ opts.writeQuantifiers().globalNegate = false;
notifyModifyOption("cegqiNestedQE", "false", "incremental solving");
- opts.quantifiers.cegqiNestedQE = false;
- opts.arith.arithMLTrick = false;
+ opts.writeQuantifiers().cegqiNestedQE = false;
+ opts.writeArith().arithMLTrick = false;
return false;
}
return true;
}
notifyModifyOption("simplificationMode", "none", "unsat cores");
- opts.smt.simplificationMode = options::SimplificationMode::NONE;
+ opts.writeSmt().simplificationMode = options::SimplificationMode::NONE;
if (opts.smt.deepRestartMode != options::DeepRestartMode::NONE)
{
verbose(1) << "SolverEngine: turning off deep restart to support unsat "
"cores"
<< std::endl;
- opts.smt.deepRestartMode = options::DeepRestartMode::NONE;
+ opts.writeSmt().deepRestartMode = options::DeepRestartMode::NONE;
}
}
return true;
}
notifyModifyOption("learnedRewrite", "false", "unsat cores");
- opts.smt.learnedRewrite = false;
+ opts.writeSmt().learnedRewrite = false;
}
if (opts.arith.pbRewrites)
return true;
}
notifyModifyOption("pbRewrites", "false", "unsat cores");
- opts.arith.pbRewrites = false;
+ opts.writeArith().pbRewrites = false;
}
if (opts.smt.sortInference)
return true;
}
notifyModifyOption("sortInference", "false", "unsat cores");
- opts.smt.sortInference = false;
+ opts.writeSmt().sortInference = false;
}
if (opts.quantifiers.preSkolemQuant != options::PreSkolemQuantMode::OFF)
return true;
}
notifyModifyOption("preSkolemQuant", "off", "unsat cores");
- opts.quantifiers.preSkolemQuant = options::PreSkolemQuantMode::OFF;
+ opts.writeQuantifiers().preSkolemQuant = options::PreSkolemQuantMode::OFF;
}
if (opts.bv.bitvectorToBool)
return true;
}
notifyModifyOption("bitvectorToBool", "false", "unsat cores");
- opts.bv.bitvectorToBool = false;
+ opts.writeBv().bitvectorToBool = false;
}
if (opts.bv.boolToBitvector != options::BoolToBVMode::OFF)
return true;
}
notifyModifyOption("boolToBitvector", "off", "unsat cores");
- opts.bv.boolToBitvector = options::BoolToBVMode::OFF;
+ opts.writeBv().boolToBitvector = options::BoolToBVMode::OFF;
}
if (opts.bv.bvIntroducePow2)
return true;
}
notifyModifyOption("bvIntroducePow2", "false", "unsat cores");
- opts.bv.bvIntroducePow2 = false;
+ opts.writeBv().bvIntroducePow2 = false;
}
if (opts.smt.repeatSimp)
return true;
}
notifyModifyOption("repeatSimp", "false", "unsat cores");
- opts.smt.repeatSimp = false;
+ opts.writeSmt().repeatSimp = false;
}
if (opts.quantifiers.globalNegate)
return true;
}
notifyModifyOption("globalNegate", "false", "unsat cores");
- opts.quantifiers.globalNegate = false;
+ opts.writeQuantifiers().globalNegate = false;
}
if (opts.smt.doITESimp)
return true;
}
notifyModifyOption("unconstrainedSimp", "false", "unsat cores");
- opts.smt.unconstrainedSimp = false;
+ opts.writeSmt().unconstrainedSimp = false;
}
if (opts.smt.deepRestartMode != options::DeepRestartMode::NONE)
{
bool SetDefaults::incompatibleWithSeparationLogic(Options& opts,
std::ostream& reason) const
{
- if (options().smt.simplificationBoolConstProp)
+ if (opts.smt.simplificationBoolConstProp)
{
// Spatial formulas in separation logic have a semantics that depends on
// their position in the AST (e.g. their nesting beneath separation
// predicates to the input formula. We disable this option altogether to
// ensure this is the case
notifyModifyOption("simplification-bcp", "false", "separation logic");
- options().smt.simplificationBoolConstProp = false;
+ opts.writeSmt().simplificationBoolConstProp = false;
}
return false;
}
if (opts.quantifiers.fullSaturateQuant)
{
Trace("smt") << "enabling enum-inst for full-saturate-quant" << std::endl;
- opts.quantifiers.enumInst = true;
+ opts.writeQuantifiers().enumInst = true;
}
if (opts.arrays.arraysExp)
{
if (!opts.quantifiers.fmfBoundWasSetByUser)
{
notifyModifyOption("fmfBound", "true", "arrays-exp");
- opts.quantifiers.fmfBound = true;
+ opts.writeQuantifiers().fmfBound = true;
}
}
if (logic.hasCardinalityConstraints())
{
// must have finite model finding on
- opts.quantifiers.finiteModelFind = true;
+ opts.writeQuantifiers().finiteModelFind = true;
}
if (opts.quantifiers.instMaxLevel != -1)
{
verbose(1) << "SolverEngine: turning off cbqi to support instMaxLevel"
<< std::endl;
- opts.quantifiers.cegqi = false;
+ opts.writeQuantifiers().cegqi = false;
}
if (opts.quantifiers.fmfBoundLazyWasSetByUser
&& opts.quantifiers.fmfBoundLazy)
{
- opts.quantifiers.fmfBound = true;
+ opts.writeQuantifiers().fmfBound = true;
Trace("smt")
<< "turning on fmf-bound, for fmf-bound-int or fmf-bound-lazy\n";
}
&& opts.quantifiers.fmfMbqiMode != options::FmfMbqiMode::FMC))
{
// if bounded integers are set, use no MBQI by default
- opts.quantifiers.fmfMbqiMode = options::FmfMbqiMode::NONE;
+ opts.writeQuantifiers().fmfMbqiMode = options::FmfMbqiMode::NONE;
}
if (!opts.quantifiers.prenexQuantUserWasSetByUser)
{
- opts.quantifiers.prenexQuant = options::PrenexQuantMode::NONE;
+ opts.writeQuantifiers().prenexQuant = options::PrenexQuantMode::NONE;
}
}
if (logic.isHigherOrder())
// cannot be used
if (opts.quantifiers.fmfMbqiMode != options::FmfMbqiMode::NONE)
{
- opts.quantifiers.fmfMbqiMode = options::FmfMbqiMode::NONE;
+ opts.writeQuantifiers().fmfMbqiMode = options::FmfMbqiMode::NONE;
}
if (!opts.quantifiers.hoElimStoreAxWasSetByUser)
{
// by default, use store axioms only if --ho-elim is set
- opts.quantifiers.hoElimStoreAx = opts.quantifiers.hoElim;
+ opts.writeQuantifiers().hoElimStoreAx = opts.quantifiers.hoElim;
}
// Cannot use macros, since lambda lifting and macro elimination are inverse
// operations.
if (opts.quantifiers.macrosQuant)
{
- opts.quantifiers.macrosQuant = false;
+ opts.writeQuantifiers().macrosQuant = false;
}
}
if (opts.quantifiers.fmfFunWellDefinedRelevant)
{
if (!opts.quantifiers.fmfFunWellDefinedWasSetByUser)
{
- opts.quantifiers.fmfFunWellDefined = true;
+ opts.writeQuantifiers().fmfFunWellDefined = true;
}
}
if (opts.quantifiers.fmfFunWellDefined)
{
if (!opts.quantifiers.finiteModelFindWasSetByUser)
{
- opts.quantifiers.finiteModelFind = true;
+ opts.writeQuantifiers().finiteModelFind = true;
}
}
// apply conservative quantifiers splitting
if (!opts.quantifiers.quantDynamicSplitWasSetByUser)
{
- opts.quantifiers.quantDynamicSplit = options::QuantDSplitMode::DEFAULT;
+ opts.writeQuantifiers().quantDynamicSplit =
+ options::QuantDSplitMode::DEFAULT;
}
if (!opts.quantifiers.eMatchingWasSetByUser)
{
// do not use E-matching by default. For E-matching + FMF, the user should
// specify --finite-model-find --e-matching.
- opts.quantifiers.eMatching = false;
+ opts.writeQuantifiers().eMatching = false;
}
if (!opts.quantifiers.instWhenModeWasSetByUser)
{
// instantiate only on last call
if (opts.quantifiers.eMatching)
{
- opts.quantifiers.instWhenMode = options::InstWhenMode::LAST_CALL;
+ opts.writeQuantifiers().instWhenMode = options::InstWhenMode::LAST_CALL;
}
}
}
{
if (!opts.quantifiers.cegqiWasSetByUser)
{
- opts.quantifiers.cegqi = true;
+ opts.writeQuantifiers().cegqi = true;
}
// check whether we should apply full cbqi
if (logic.isPure(THEORY_BV))
{
if (!opts.quantifiers.cegqiFullEffortWasSetByUser)
{
- opts.quantifiers.cegqiFullEffort = true;
+ opts.writeQuantifiers().cegqiFullEffort = true;
}
}
}
{
if (!opts.quantifiers.conflictBasedInstWasSetByUser)
{
- opts.quantifiers.conflictBasedInst = false;
+ opts.writeQuantifiers().conflictBasedInst = false;
}
if (!opts.quantifiers.instNoEntailWasSetByUser)
{
- opts.quantifiers.instNoEntail = false;
+ opts.writeQuantifiers().instNoEntail = false;
}
if (!opts.quantifiers.instWhenModeWasSetByUser)
{
// only instantiation should happen at last call when model is avaiable
- opts.quantifiers.instWhenMode = options::InstWhenMode::LAST_CALL;
+ opts.writeQuantifiers().instWhenMode = options::InstWhenMode::LAST_CALL;
}
}
else
{
// only supported in pure arithmetic or pure BV
- opts.quantifiers.cegqiNestedQE = false;
+ opts.writeQuantifiers().cegqiNestedQE = false;
}
if (opts.quantifiers.globalNegate)
{
if (!opts.quantifiers.prenexQuantWasSetByUser)
{
- opts.quantifiers.prenexQuant = options::PrenexQuantMode::NONE;
+ opts.writeQuantifiers().prenexQuant = options::PrenexQuantMode::NONE;
}
}
}
// implied options...
if (opts.quantifiers.cbqiModeWasSetByUser || opts.quantifiers.cbqiTConstraint)
{
- opts.quantifiers.conflictBasedInst = true;
+ opts.writeQuantifiers().conflictBasedInst = true;
}
if (opts.quantifiers.cegqiNestedQE)
{
- opts.quantifiers.prenexQuantUser = true;
+ opts.writeQuantifiers().prenexQuantUser = true;
if (!opts.quantifiers.preSkolemQuantWasSetByUser)
{
- opts.quantifiers.preSkolemQuant = options::PreSkolemQuantMode::ON;
+ opts.writeQuantifiers().preSkolemQuant = options::PreSkolemQuantMode::ON;
}
}
// for induction techniques
{
if (!opts.quantifiers.dtStcInductionWasSetByUser)
{
- opts.quantifiers.dtStcInduction = true;
+ opts.writeQuantifiers().dtStcInduction = true;
}
if (!opts.quantifiers.intWfInductionWasSetByUser)
{
- opts.quantifiers.intWfInduction = true;
+ opts.writeQuantifiers().intWfInduction = true;
}
}
if (opts.quantifiers.dtStcInduction)
// try to remove ITEs from quantified formulas
if (!opts.quantifiers.iteDtTesterSplitQuantWasSetByUser)
{
- opts.quantifiers.iteDtTesterSplitQuant = true;
+ opts.writeQuantifiers().iteDtTesterSplitQuant = true;
}
if (!opts.quantifiers.iteLiftQuantWasSetByUser)
{
- opts.quantifiers.iteLiftQuant = options::IteLiftQuantMode::ALL;
+ opts.writeQuantifiers().iteLiftQuant = options::IteLiftQuantMode::ALL;
}
}
if (opts.quantifiers.intWfInduction)
{
if (!opts.quantifiers.purifyTriggersWasSetByUser)
{
- opts.quantifiers.purifyTriggers = true;
+ opts.writeQuantifiers().purifyTriggers = true;
}
}
if (opts.quantifiers.conjectureGenPerRoundWasSetByUser)
{
if (opts.quantifiers.conjectureGenPerRound > 0)
{
- opts.quantifiers.conjectureGen = true;
+ opts.writeQuantifiers().conjectureGen = true;
}
else
{
- opts.quantifiers.conjectureGen = false;
+ opts.writeQuantifiers().conjectureGen = false;
}
}
// can't pre-skolemize nested quantifiers without UF theory
{
if (!opts.quantifiers.preSkolemQuantNestedWasSetByUser)
{
- opts.quantifiers.preSkolemQuantNested = false;
+ opts.writeQuantifiers().preSkolemQuantNested = false;
}
}
if (!logic.isTheoryEnabled(THEORY_DATATYPES))
{
- opts.quantifiers.quantDynamicSplit = options::QuantDSplitMode::NONE;
+ opts.writeQuantifiers().quantDynamicSplit = options::QuantDSplitMode::NONE;
}
if (opts.quantifiers.globalNegate)
{
notifyModifyOption("deep-restart", "false", "global-negate");
- opts.smt.deepRestartMode = options::DeepRestartMode::NONE;
+ opts.writeSmt().deepRestartMode = options::DeepRestartMode::NONE;
}
}
if (!opts.quantifiers.sygus)
{
notifyModifyOption("sygus", "true", "");
- opts.quantifiers.sygus = true;
+ opts.writeQuantifiers().sygus = true;
}
// must use Ferrante/Rackoff for real arithmetic
if (!opts.quantifiers.cegqiMidpointWasSetByUser)
{
- opts.quantifiers.cegqiMidpoint = true;
+ opts.writeQuantifiers().cegqiMidpoint = true;
}
// must disable cegqi-bv since it may introduce witness terms, which
// cannot appear in synthesis solutions
if (!opts.quantifiers.cegqiBvWasSetByUser)
{
- opts.quantifiers.cegqiBv = false;
+ opts.writeQuantifiers().cegqiBv = false;
}
if (opts.quantifiers.sygusRepairConst)
{
if (!opts.quantifiers.cegqiWasSetByUser)
{
- opts.quantifiers.cegqi = true;
+ opts.writeQuantifiers().cegqi = true;
}
}
if (opts.quantifiers.sygusInference)
// optimization: apply preskolemization, makes it succeed more often
if (!opts.quantifiers.preSkolemQuantWasSetByUser)
{
- opts.quantifiers.preSkolemQuant = options::PreSkolemQuantMode::ON;
+ opts.writeQuantifiers().preSkolemQuant = options::PreSkolemQuantMode::ON;
}
if (!opts.quantifiers.preSkolemQuantNestedWasSetByUser)
{
- opts.quantifiers.preSkolemQuantNested = true;
+ opts.writeQuantifiers().preSkolemQuantNested = true;
}
}
// counterexample-guided instantiation for sygus
if (!opts.quantifiers.cegqiSingleInvModeWasSetByUser)
{
- opts.quantifiers.cegqiSingleInvMode = options::CegqiSingleInvMode::USE;
+ opts.writeQuantifiers().cegqiSingleInvMode =
+ options::CegqiSingleInvMode::USE;
}
if (!opts.quantifiers.conflictBasedInstWasSetByUser)
{
- opts.quantifiers.conflictBasedInst = false;
+ opts.writeQuantifiers().conflictBasedInst = false;
}
if (!opts.quantifiers.instNoEntailWasSetByUser)
{
- opts.quantifiers.instNoEntail = false;
+ opts.writeQuantifiers().instNoEntail = false;
}
if (!opts.quantifiers.cegqiFullEffortWasSetByUser)
{
// should use full effort cbqi for single invocation and repair const
- opts.quantifiers.cegqiFullEffort = true;
+ opts.writeQuantifiers().cegqiFullEffort = true;
}
if (opts.quantifiers.sygusRewSynthInput)
{
// If we are using synthesis rewrite rules from input, we use
// sygusRewSynth after preprocessing. See passes/synth_rew_rules.h for
// details on this technique.
- opts.quantifiers.sygusRewSynth = true;
+ opts.writeQuantifiers().sygusRewSynth = true;
// we should not use the extended rewriter, since we are interested
// in rewrites that are not in the main rewriter
if (!opts.datatypes.sygusRewriterWasSetByUser)
{
- opts.datatypes.sygusRewriter = options::SygusRewriterMode::BASIC;
+ opts.writeDatatypes().sygusRewriter = options::SygusRewriterMode::BASIC;
}
}
// Whether we must use "basic" sygus algorithms. A non-basic sygus algorithm
// if doing abduction, we should filter strong solutions
if (!opts.quantifiers.sygusFilterSolModeWasSetByUser)
{
- opts.quantifiers.sygusFilterSolMode = options::SygusFilterSolMode::STRONG;
+ opts.writeQuantifiers().sygusFilterSolMode =
+ options::SygusFilterSolMode::STRONG;
}
// we must use basic sygus algorithms, since e.g. we require checking
// a sygus side condition for consistency with axioms.
|| opts.quantifiers.sygusQueryGen != options::SygusQueryGenMode::NONE)
{
// rewrite rule synthesis implies that sygus stream must be true
- opts.quantifiers.sygusStream = true;
+ opts.writeQuantifiers().sygusStream = true;
}
if (opts.quantifiers.sygusStream || opts.base.incrementalSolving)
{
{
if (!opts.quantifiers.sygusUnifPbeWasSetByUser)
{
- opts.quantifiers.sygusUnifPbe = false;
+ opts.writeQuantifiers().sygusUnifPbe = false;
}
if (opts.quantifiers.sygusUnifPiWasSetByUser)
{
- opts.quantifiers.sygusUnifPi = options::SygusUnifPiMode::NONE;
+ opts.writeQuantifiers().sygusUnifPi = options::SygusUnifPiMode::NONE;
}
if (!opts.quantifiers.sygusInvTemplModeWasSetByUser)
{
- opts.quantifiers.sygusInvTemplMode = options::SygusInvTemplMode::NONE;
+ opts.writeQuantifiers().sygusInvTemplMode =
+ options::SygusInvTemplMode::NONE;
}
if (!opts.quantifiers.cegqiSingleInvModeWasSetByUser)
{
- opts.quantifiers.cegqiSingleInvMode = options::CegqiSingleInvMode::NONE;
+ opts.writeQuantifiers().cegqiSingleInvMode =
+ options::CegqiSingleInvMode::NONE;
}
}
// do not miniscope
if (!opts.quantifiers.miniscopeQuantWasSetByUser)
{
- opts.quantifiers.miniscopeQuant = options::MiniscopeQuantMode::OFF;
+ opts.writeQuantifiers().miniscopeQuant = options::MiniscopeQuantMode::OFF;
}
// do not do macros
if (!opts.quantifiers.macrosQuantWasSetByUser)
{
- opts.quantifiers.macrosQuant = false;
+ opts.writeQuantifiers().macrosQuant = false;
}
}
void SetDefaults::setDefaultDecisionMode(const LogicInfo& logic,
? true
: false);
- opts.decision.decisionMode = decMode;
+ opts.writeDecision().decisionMode = decMode;
if (stoponly)
{
if (opts.decision.decisionMode == options::DecisionMode::JUSTIFICATION)
{
- opts.decision.decisionMode = options::DecisionMode::STOPONLY;
+ opts.writeDecision().decisionMode = options::DecisionMode::STOPONLY;
}
else
{