mirror of
https://github.com/Z3Prover/z3
synced 2026-05-17 07:29:28 +00:00
bmc improvements, move fd_solver to self-contained directory
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
fd09b1a7d0
commit
e041ebbe80
21 changed files with 120 additions and 76 deletions
|
|
@ -57,7 +57,8 @@ namespace datalog {
|
|||
m_hnf(m),
|
||||
m_qe(m, params_ref(), false),
|
||||
m_rwr(m),
|
||||
m_ufproc(m) {}
|
||||
m_ufproc(m),
|
||||
m_fd_proc(m) {}
|
||||
|
||||
void rule_manager::inc_ref(rule * r) {
|
||||
if (r) {
|
||||
|
|
@ -928,6 +929,23 @@ namespace datalog {
|
|||
return exist || univ;
|
||||
}
|
||||
|
||||
bool rule_manager::is_finite_domain(rule const& r) const {
|
||||
m_visited.reset();
|
||||
m_fd_proc.reset();
|
||||
for (unsigned i = r.get_uninterpreted_tail_size(); i < r.get_tail_size(); ++i) {
|
||||
for_each_expr_core<fd_finder_proc,expr_sparse_mark, true, false>(m_fd_proc, m_visited, r.get_tail(i));
|
||||
}
|
||||
for (unsigned i = 0; i < r.get_uninterpreted_tail_size(); ++i) {
|
||||
for (expr* arg : *r.get_tail(i)) {
|
||||
for_each_expr_core<fd_finder_proc,expr_sparse_mark, true, false>(m_fd_proc, m_visited, arg);
|
||||
}
|
||||
}
|
||||
for (expr* arg : *r.get_head()) {
|
||||
for_each_expr_core<fd_finder_proc,expr_sparse_mark, true, false>(m_fd_proc, m_visited, arg);
|
||||
}
|
||||
return m_fd_proc.is_fd();
|
||||
}
|
||||
|
||||
bool rule::has_negation() const {
|
||||
for (unsigned i = 0; i < get_uninterpreted_tail_size(); ++i) {
|
||||
if (is_neg_tail(i)) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue