summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuy <katz911@gmail.com>2016-07-24 22:35:05 -0700
committerGuy <katz911@gmail.com>2016-07-24 22:35:05 -0700
commit1aa6f7798ff47c3a6af665adb95a6d5266f3c34b (patch)
tree8632d0906768a9a9f99c8c2ff02e41d8601a9e84
parent1d07595a25267066a77ffce8216a759be5fbbdde (diff)
Use letification for the aliasing declarations as well (consequently, print the global let map before the aliasing part)
-rw-r--r--src/proof/arith_proof.cpp2
-rw-r--r--src/proof/arith_proof.h2
-rw-r--r--src/proof/array_proof.cpp2
-rw-r--r--src/proof/array_proof.h2
-rw-r--r--src/proof/bitvector_proof.cpp5
-rw-r--r--src/proof/bitvector_proof.h2
-rw-r--r--src/proof/proof_manager.cpp6
-rw-r--r--src/proof/theory_proof.cpp6
-rw-r--r--src/proof/theory_proof.h10
-rw-r--r--src/proof/uf_proof.cpp2
-rw-r--r--src/proof/uf_proof.h2
11 files changed, 19 insertions, 22 deletions
diff --git a/src/proof/arith_proof.cpp b/src/proof/arith_proof.cpp
index 4864cbf46..100f60600 100644
--- a/src/proof/arith_proof.cpp
+++ b/src/proof/arith_proof.cpp
@@ -830,7 +830,7 @@ void LFSCArithProof::printDeferredDeclarations(std::ostream& os, std::ostream& p
// Nothing to do here at this point.
}
-void LFSCArithProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCArithProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
// Nothing to do here at this point.
}
diff --git a/src/proof/arith_proof.h b/src/proof/arith_proof.h
index d980654c4..126e89ed2 100644
--- a/src/proof/arith_proof.h
+++ b/src/proof/arith_proof.h
@@ -74,7 +74,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren);
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
};
diff --git a/src/proof/array_proof.cpp b/src/proof/array_proof.cpp
index 18e01728b..63758e573 100644
--- a/src/proof/array_proof.cpp
+++ b/src/proof/array_proof.cpp
@@ -1380,7 +1380,7 @@ void LFSCArrayProof::printDeferredDeclarations(std::ostream& os, std::ostream& p
}
}
-void LFSCArrayProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCArrayProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
// Nothing to do here at this point.
}
diff --git a/src/proof/array_proof.h b/src/proof/array_proof.h
index 69e62dbf3..61f168a16 100644
--- a/src/proof/array_proof.h
+++ b/src/proof/array_proof.h
@@ -124,7 +124,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren);
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
};
diff --git a/src/proof/bitvector_proof.cpp b/src/proof/bitvector_proof.cpp
index f557d5063..2da0d5362 100644
--- a/src/proof/bitvector_proof.cpp
+++ b/src/proof/bitvector_proof.cpp
@@ -656,7 +656,7 @@ void LFSCBitVectorProof::printDeferredDeclarations(std::ostream& os, std::ostrea
// Nothing to do here at this point.
}
-void LFSCBitVectorProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCBitVectorProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
// Print "trust" statements to bind complex bv variables to their associated terms
ExprToString::const_iterator it = d_assignedAliases.begin();
@@ -673,8 +673,7 @@ void LFSCBitVectorProof::printAliasingDeclarations(std::ostream& os, std::ostrea
os << "(trust_f ";
os << "(= (BitVec " << utils::getSize(it->first) << ") ";
os << "(a_var_bv " << utils::getSize(it->first) << " " << it->second << ") ";
- ProofLetMap emptyMap;
- d_proofEngine->printBoundTerm(it->first, os, emptyMap);
+ d_proofEngine->printBoundTerm(it->first, os, globalLetMap);
os << ")) ";
os << "(\\ "<< d_aliasToBindDeclaration[it->second] << "\n";
paren << "))";
diff --git a/src/proof/bitvector_proof.h b/src/proof/bitvector_proof.h
index a52292ec9..8d0871ef8 100644
--- a/src/proof/bitvector_proof.h
+++ b/src/proof/bitvector_proof.h
@@ -148,7 +148,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren);
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
virtual void printBitblasting(std::ostream& os, std::ostream& paren);
virtual void printResolutionProof(std::ostream& os, std::ostream& paren, ProofLetMap& letMap);
void calculateAtomsInBitblastingProof();
diff --git a/src/proof/proof_manager.cpp b/src/proof/proof_manager.cpp
index cb6eee330..835990613 100644
--- a/src/proof/proof_manager.cpp
+++ b/src/proof/proof_manager.cpp
@@ -515,18 +515,16 @@ void LFSCProof::toStream(std::ostream& out) {
out << " ;; Printing deferred declarations \n\n";
d_theoryProof->printDeferredDeclarations(out, paren);
+ out << "\n ;; Printing the global let map";
d_theoryProof->finalizeBvConflicts(used_lemmas, out);
ProofManager::getBitVectorProof()->calculateAtomsInBitblastingProof();
-
- out << "\n ;; Printing the global let map \n";
-
ProofLetMap globalLetMap;
if (options::lfscLetification()) {
ProofManager::currentPM()->printGlobalLetMap(atoms, globalLetMap, out, paren);
}
out << " ;; Printing aliasing declarations \n\n";
- d_theoryProof->printAliasingDeclarations(out, paren);
+ d_theoryProof->printAliasingDeclarations(out, paren, globalLetMap);
out << " ;; Rewrites for Lemmas \n";
d_theoryProof->printLemmaRewrites(rewrites, out, paren);
diff --git a/src/proof/theory_proof.cpp b/src/proof/theory_proof.cpp
index f0f333598..f544f5ff5 100644
--- a/src/proof/theory_proof.cpp
+++ b/src/proof/theory_proof.cpp
@@ -406,13 +406,13 @@ void LFSCTheoryProofEngine::printDeferredDeclarations(std::ostream& os, std::ost
}
}
-void LFSCTheoryProofEngine::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCTheoryProofEngine::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
Debug("pf::tp") << "LFSCTheoryProofEngine::printAliasingDeclarations called" << std::endl;
TheoryProofTable::const_iterator it = d_theoryProofTable.begin();
TheoryProofTable::const_iterator end = d_theoryProofTable.end();
for (; it != end; ++it) {
- it->second->printAliasingDeclarations(os, paren);
+ it->second->printAliasingDeclarations(os, paren, globalLetMap);
}
}
@@ -1168,7 +1168,7 @@ void LFSCBooleanProof::printDeferredDeclarations(std::ostream& os, std::ostream&
// Nothing to do here at this point.
}
-void LFSCBooleanProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCBooleanProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
// Nothing to do here at this point.
}
diff --git a/src/proof/theory_proof.h b/src/proof/theory_proof.h
index 5907f9bd5..968d46e68 100644
--- a/src/proof/theory_proof.h
+++ b/src/proof/theory_proof.h
@@ -109,7 +109,7 @@ public:
* @param os
* @param paren closing parenthesis
*/
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren) = 0;
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) = 0;
/**
* Print proofs of all the theory lemmas (must prove
@@ -173,7 +173,7 @@ public:
virtual void printAssertions(std::ostream& os, std::ostream& paren);
virtual void printLemmaRewrites(NodePairSet& rewrites, std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
virtual void printTheoryLemmas(const IdToSatClause& lemmas,
std::ostream& os,
std::ostream& paren,
@@ -274,7 +274,7 @@ public:
* @param os
* @param paren
*/
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren) = 0;
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) = 0;
/**
* Register a term of this theory that appears in the proof.
*
@@ -312,7 +312,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren) = 0;
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren) = 0;
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren) = 0;
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren) = 0;
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) = 0;
};
class LFSCBooleanProof : public BooleanProof {
@@ -326,7 +326,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren);
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
void treatBoolsAsFormulas(bool value) {
d_treatBoolsAsFormulas = value;
diff --git a/src/proof/uf_proof.cpp b/src/proof/uf_proof.cpp
index 139ce5ed2..e122a46bc 100644
--- a/src/proof/uf_proof.cpp
+++ b/src/proof/uf_proof.cpp
@@ -797,7 +797,7 @@ void LFSCUFProof::printDeferredDeclarations(std::ostream& os, std::ostream& pare
// Nothing to do here at this point.
}
-void LFSCUFProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren) {
+void LFSCUFProof::printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap) {
// Nothing to do here at this point.
}
diff --git a/src/proof/uf_proof.h b/src/proof/uf_proof.h
index 444b602dc..ff0f9a879 100644
--- a/src/proof/uf_proof.h
+++ b/src/proof/uf_proof.h
@@ -70,7 +70,7 @@ public:
virtual void printSortDeclarations(std::ostream& os, std::ostream& paren);
virtual void printTermDeclarations(std::ostream& os, std::ostream& paren);
virtual void printDeferredDeclarations(std::ostream& os, std::ostream& paren);
- virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren);
+ virtual void printAliasingDeclarations(std::ostream& os, std::ostream& paren, const ProofLetMap &globalLetMap);
};
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback