summaryrefslogtreecommitdiff
path: root/src/theory/arrays/theory_arrays.cpp
diff options
context:
space:
mode:
authorMorgan Deters <mdeters@gmail.com>2012-08-16 21:30:41 +0000
committerMorgan Deters <mdeters@gmail.com>2012-08-16 21:30:41 +0000
commitdd30200795d4b37398c29f0d20998c9bd63a7fe7 (patch)
tree494e235520553c0f20654bb991e8359e6b0f1b9e /src/theory/arrays/theory_arrays.cpp
parentd260caa58d462f7e1eb0d94f73789f844f5f5596 (diff)
Replace propagateAsDecision() with Theory::getNextDecisionRequest():
* arrays now uses the new approach by using a CDQueue<> * uf strong solver has had the feature disabled, pending a merge from Andy * theory kinds files now have a getNextDecisionRequest property (if you want to take part in such decision requests you have to list that property) * the staticLearning property has been renamed ppStaticLearn to match the function name * theory kinds files are now checked again for correctly-declared properties (this had been disabled) * minor documentation and other fixups
Diffstat (limited to 'src/theory/arrays/theory_arrays.cpp')
-rw-r--r--src/theory/arrays/theory_arrays.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/src/theory/arrays/theory_arrays.cpp b/src/theory/arrays/theory_arrays.cpp
index 47f3e31db..4f2497d2b 100644
--- a/src/theory/arrays/theory_arrays.cpp
+++ b/src/theory/arrays/theory_arrays.cpp
@@ -76,6 +76,7 @@ TheoryArrays::TheoryArrays(context::Context* c, context::UserContext* u, OutputC
d_sharedOther(c),
d_sharedTerms(c, false),
d_reads(c),
+ d_decisionRequests(c),
d_permRef(c)
{
StatisticsRegistry::registerStat(&d_numRow);
@@ -1082,7 +1083,6 @@ void TheoryArrays::checkRowLemmas(TNode a, TNode b)
Trace("arrays-crl")<<"Arrays::checkLemmas done.\n";
}
-
void TheoryArrays::queueRowLemma(RowLemmaType lem)
{
if (d_conflict || d_RowAlreadyAdded.count(lem) != 0) {
@@ -1148,8 +1148,7 @@ void TheoryArrays::queueRowLemma(RowLemmaType lem)
// Prefer equality between indexes so as not to introduce new read terms
if (d_eagerIndexSplitting && !bothExist && !d_equalityEngine.areDisequal(i,j, false)) {
- Node split = d_valuation.ensureLiteral(i.eqNode(j));
- d_out->propagateAsDecision(split);
+ d_decisionRequests.push(i.eqNode(j));
}
// TODO: maybe add triggers here
@@ -1215,6 +1214,17 @@ void TheoryArrays::queueRowLemma(RowLemmaType lem)
}
+Node TheoryArrays::getNextDecisionRequest() {
+ if(! d_decisionRequests.empty()) {
+ Node n = d_valuation.ensureLiteral(d_decisionRequests.front());
+ d_decisionRequests.pop();
+ return n;
+ } else {
+ return Node::null();
+ }
+}
+
+
void TheoryArrays::dischargeLemmas()
{
size_t sz = d_RowQueue.size();
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback