3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-24 01:25:31 +00:00

Fix some spelling errors (mostly in comments).

This commit is contained in:
Florian Pigorsch 2018-10-20 17:07:41 +02:00
parent 880ce12e2d
commit 326bf401b9
121 changed files with 205 additions and 205 deletions

View file

@ -492,7 +492,7 @@ bool arith_eq_solver::solve_integer_equations_omega(
return false;
}
else if (r[index].is_zero()) {
// Row is trival
// Row is trivial
rows_solved.pop_back();
continue;
}

View file

@ -64,14 +64,14 @@ struct qi_params {
Enodes in the input problem have generation 0.
Some combinations of m_qi_cost and m_qi_new_gen will prevent Z3 from breaking matching loops.
For example, the "Weight 0" peformace bug was triggered by the following combination:
For example, the "Weight 0" performance bug was triggered by the following combination:
- m_qi_cost: (+ weight generation)
- m_qi_new_gen: cost
If a quantifier has weight 0, then the cost of instantiating it with a term in the input problem has cost 0.
The new enodes created during the instantiation will be tagged with generation = const = 0. So, every enode
will have generation 0, and consequently every quantifier instantiation will have cost 0.
Although dangerous, this feature was requested by the Boogie team. In their case, the patterns are carefully constructred,
Although dangerous, this feature was requested by the Boogie team. In their case, the patterns are carefully constructed,
and there are no matching loops. Moreover, the tag some quantifiers with weight 0 to instruct Z3 to never block their instances.
An example is the select-store axiom. They need this feature to be able to analyze code that contains very long execution paths.

View file

@ -12,7 +12,7 @@ def_module_params(module_name='smt',
('ematching', BOOL, True, 'E-Matching based quantifier instantiation'),
('phase_selection', UINT, 3, 'phase selection heuristic: 0 - always false, 1 - always true, 2 - phase caching, 3 - phase caching conservative, 4 - phase caching conservative 2, 5 - random, 6 - number of occurrences'),
('restart_strategy', UINT, 1, '0 - geometric, 1 - inner-outer-geometric, 2 - luby, 3 - fixed, 4 - arithmetic'),
('restart_factor', DOUBLE, 1.1, 'when using geometric (or inner-outer-geometric) progression of restarts, it specifies the constant used to multiply the currect restart threshold'),
('restart_factor', DOUBLE, 1.1, 'when using geometric (or inner-outer-geometric) progression of restarts, it specifies the constant used to multiply the current restart threshold'),
('case_split', UINT, 1, '0 - case split based on variable activity, 1 - similar to 0, but delay case splits created during the search, 2 - similar to 0, but cache the relevancy, 3 - case split based on relevancy (structural splitting), 4 - case split on relevancy and activity, 5 - case split on relevancy and current goal, 6 - activity-based case split with theory-aware branching activity'),
('delay_units', BOOL, False, 'if true then z3 will not restart when a unit clause is learned'),
('delay_units_threshold', UINT, 32, 'maximum number of learned unit clauses before restarting, ignored if delay_units is false'),

View file

@ -175,7 +175,7 @@ namespace smt {
}
}
m_new_entries.reset();
TRACE("new_entries_bug", tout << "[qi:instatiate]\n";);
TRACE("new_entries_bug", tout << "[qi:instantiate]\n";);
}
void qi_queue::display_instance_profile(fingerprint * f, quantifier * q, unsigned num_bindings, enode * const * bindings, unsigned proof_id, unsigned generation) {

View file

@ -51,7 +51,7 @@ namespace smt {
}
/**
\brief Mark all enodes in a 'proof' tree brach starting at n
\brief Mark all enodes in a 'proof' tree branch starting at n
n -> ... -> root
*/
template<bool Set>

View file

@ -518,7 +518,7 @@ namespace smt {
// 2. r1 is interpreted but r2 is not.
//
// The second condition is used to enforce the invariant that if a class contain
// an interepreted enode then the root is also interpreted.
// an interpreted enode then the root is also interpreted.
if ((r1->get_class_size() > r2->get_class_size() && !r2->is_interpreted()) || r1->is_interpreted()) {
SASSERT(!r2->is_interpreted());
std::swap(n1, n2);
@ -529,7 +529,7 @@ namespace smt {
" n1: #" << n1->get_owner_id() << "\n";);
// It is necessary to propagate relevancy to other elements of
// the equivalence class. This is nessary to enforce the invariant
// the equivalence class. This is necessary to enforce the invariant
// in the field m_parent of the enode class.
if (is_relevant(r1)) { // && !m_manager.is_eq(r1->get_owner())) !is_eq HACK
// NOTE for !is_eq HACK... the !is_eq HACK does not propagate relevancy when two
@ -4067,7 +4067,7 @@ namespace smt {
A literal may have been marked relevant within the scope that gets popped during
conflict resolution. In this case, the literal is no longer marked as relevant after
the pop. This can cause quantifier instantiation to miss relevant triggers and thereby
cause incmpleteness.
cause incompleteness.
*/
void context::record_relevancy(unsigned n, literal const* lits) {
m_relevant_conflict_literals.reset();
@ -4281,7 +4281,7 @@ namespace smt {
return true;
}
// the variabe is shared if the equivalence class of n
// the variable is shared if the equivalence class of n
// contains a parent application.
theory_var_list * l = n->get_th_var_list();

View file

@ -73,7 +73,7 @@ namespace smt {
class tmp_enode;
/**
\brief Aditional data-structure for implementing congruence closure,
\brief Additional data-structure for implementing congruence closure,
equality propagation, and the theory central bus of equalities.
*/
class enode {

View file

@ -96,7 +96,7 @@ namespace smt {
class model_value_dependency {
bool m_fresh; //!< True if the dependency is a new fresh value;
union {
enode * m_enode; //!< When m_fresh == false, contains an enode depedency.
enode * m_enode; //!< When m_fresh == false, contains an enode dependency.
extra_fresh_value * m_value; //!< When m_fresh == true, contains the sort of the fresh value
};
public:

View file

@ -203,7 +203,7 @@ namespace smt {
static void check_no_arithmetic(static_features const & st, char const * logic) {
if (st.m_num_arith_ineqs > 0 || st.m_num_arith_terms > 0 || st.m_num_arith_eqs > 0)
throw default_exception("Benchmark constains arithmetic, but specified loging does not support it.");
throw default_exception("Benchmark constains arithmetic, but specified logic does not support it.");
}
void setup::setup_QF_UF() {
@ -519,7 +519,7 @@ namespace smt {
m_params.m_arith_eq2ineq = true;
m_params.m_eliminate_term_ite = true;
// if (st.m_num_exprs < 5000 && st.m_num_ite_terms < 50) { // safeguard to avoid high memory consumption
// TODO: implement analsysis function to decide where lift ite is too expensive.
// TODO: implement analysis function to decide where lift ite is too expensive.
// m_params.m_lift_ite = LI_FULL;
// }
}

View file

@ -68,7 +68,7 @@ namespace smt {
public:
/**
\brief Return ture if the given enode is attached to a
\brief Return true if the given enode is attached to a
variable of the theory.
\remark The result is not equivalent to
@ -389,7 +389,7 @@ namespace smt {
\brief When an eq atom n is created during the search, the default behavior is
to make sure that the n->get_arg(0)->get_id() < n->get_arg(1)->get_id().
This may create some redundant atoms, since some theories/families use different
convetions in their simplifiers. For example, arithmetic always force a numeral
conventions in their simplifiers. For example, arithmetic always force a numeral
to be in the right hand side. So, this method should be redefined if the default
behavior conflicts with a convention used by the theory/family.
*/

View file

@ -1073,7 +1073,7 @@ namespace smt {
/**
\brief: Create an atom that enforces the inequality v > val
The arithmetical expression encoding the inequality suffices
for the theory of aritmetic.
for the theory of arithmetic.
*/
template<typename Ext>
expr_ref theory_arith<Ext>::mk_gt(theory_var v) {
@ -1146,7 +1146,7 @@ namespace smt {
template<typename Ext>
void theory_arith<Ext>::enable_record_conflict(expr* bound) {
m_params.m_arith_bound_prop = BP_NONE;
SASSERT(propagation_mode() == BP_NONE); // bound propagtion rules are not (yet) handled.
SASSERT(propagation_mode() == BP_NONE); // bound propagation rules are not (yet) handled.
if (bound) {
context& ctx = get_context();
m_bound_watch = ctx.get_bool_var(bound);

View file

@ -3128,7 +3128,7 @@ namespace smt {
//
// 1) Handling inequalities: (n1, k1) <= (n2, k2)
//
// The only intersting case is n1 < n2 and k1 > k2.
// The only interesting case is n1 < n2 and k1 > k2.
// Using the definition of infinitesimal numbers
// we have:
// n1 + k1 * epsilon <= n2 + k2 - epsilon
@ -3533,7 +3533,7 @@ namespace smt {
}
/**
\brief reset and retrieve built-in explanation hints for arithmetic lemmmas.
\brief reset and retrieve built-in explanation hints for arithmetic lemmas.
*/
template<typename Ext>

View file

@ -1337,7 +1337,7 @@ namespace smt {
}
/**
\brief Diplay a nested form expression
\brief Display a nested form expression
*/
template<typename Ext>
void theory_arith<Ext>::display_nested_form(std::ostream & out, expr * p) {
@ -1682,7 +1682,7 @@ namespace smt {
if (!get_manager().int_real_coercions() && is_mixed_real_integer(r))
return true; // giving up... see comment above
TRACE("cross_nested", tout << "cheking problematic row...\n";);
TRACE("cross_nested", tout << "checking problematic row...\n";);
rational c = rational::one();
if (is_integer(r))
@ -1764,7 +1764,7 @@ namespace smt {
updated with the fixed variables in m. A variable is only
added to dep if it is not already in already_found.
Return null if the monomial was simplied to 0.
Return null if the monomial was simplified to 0.
*/
template<typename Ext>
grobner::monomial * theory_arith<Ext>::mk_gb_monomial(rational const & _coeff, expr * m, grobner & gb, v_dependency * & dep, var_set & already_found) {

View file

@ -756,7 +756,7 @@ namespace smt {
(n_x, k_x) <= (n_y + n_c, k_y + k_c)
The only intersting case is n_x < n_y + n_c and k_x > k_y + k_c.
The only interesting case is n_x < n_y + n_c and k_x > k_y + k_c.
Using the definition of infinitesimal numbers
we have:

View file

@ -3225,7 +3225,7 @@ public:
theory_var w;
if (m_solver->is_term(ti.var())) {
//w = m_term_index2theory_var.get(m_solver->adjust_term_index(ti.var()), null_theory_var);
//if (w == null_theory_var) // if extracing expressions directly from nested term
//if (w == null_theory_var) // if extracting expressions directly from nested term
lp::lar_term const& term1 = m_solver->get_term(ti.var());
rational coeff2 = coeff * ti.coeff();
term2coeffs(term1, coeffs, coeff2, offset);

View file

@ -107,7 +107,7 @@ namespace smt {
struct ineq {
unsynch_mpz_manager& m_mpz; // mpz manager.
literal m_lit; // literal repesenting predicate
literal m_lit; // literal representing predicate
bool m_is_eq; // is this an = or >=.
arg_t m_args[2]; // encode args[0]*coeffs[0]+...+args[n-1]*coeffs[n-1] >= k();
// Watch the first few positions until the sum satisfies:
@ -192,7 +192,7 @@ namespace smt {
// If none are available, then perform unit propagation.
//
class card {
literal m_lit; // literal repesenting predicate
literal m_lit; // literal representing predicate
literal_vector m_args;
unsigned m_bound;
unsigned m_num_propagations;

View file

@ -1412,7 +1412,7 @@ bool theory_seq::is_complex(eq const& e) {
\brief Decompose ls = rs into Xa = bYc, such that
1.
- X != Y
- |b| <= |X| <= |bY| in currrent model
- |b| <= |X| <= |bY| in current model
- b is non-empty.
2. X != Y
- b is empty

View file

@ -5074,7 +5074,7 @@ namespace smt {
}
} else {
// ------------------------------------------------------------------------------------------------
// subStr doesn't have an eqc contant value
// subStr doesn't have an eqc constant value
// however, subStr equals to some concat(arg_1, arg_2, ..., arg_n)
// if arg_j is a constant and is not a part of the strConst, it's sure that the contains is false
// ** This check is needed here because the "strConst" and "strAst" may not be in a same eqc yet