From f192e60e8ace79f06d57a6043e77fb8fb48dbabc Mon Sep 17 00:00:00 2001 From: Kshitij Bansal Date: Sun, 17 Jun 2012 22:04:41 +0000 Subject: [PATCH] --decision=justification-stoponly : use decision engine only for stopping search early, not to make decisions new options.h :) --- src/prop/theory_proxy.cpp | 2 +- src/util/options.cpp | 9 +++++++++ src/util/options.h | 1 + 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/prop/theory_proxy.cpp b/src/prop/theory_proxy.cpp index 93f8c0a5d..15a383d92 100644 --- a/src/prop/theory_proxy.cpp +++ b/src/prop/theory_proxy.cpp @@ -92,7 +92,7 @@ SatLiteral TheoryProxy::getNextDecisionRequest(bool &stopSearch) { if(stopSearch) { Trace("decision") << " *** Decision Engine stopped search *** " << std::endl; } - return ret; + return Options::current()->decisionOptions.stopOnly ? undefSatLiteral : ret; } bool TheoryProxy::theoryNeedCheck() const { diff --git a/src/util/options.cpp b/src/util/options.cpp index c912023ad..b9291f59c 100644 --- a/src/util/options.cpp +++ b/src/util/options.cpp @@ -64,6 +64,7 @@ const Options::DecisionOptions defaultDecOpt = { 1000, // maxRelTimeAsPermille true, // computeRelevancy false, // mustRelevancy + false, // stopOnly }; Options::Options() : @@ -355,6 +356,9 @@ internal (default)\n\ justification\n\ + An ATGP-inspired justification heuristic\n\ \n\ +justification-stoponly\n\ ++ Use the justification heuristic only to stop early, not for decisions\n\ +\n\ relevancy\n\ + Under development may-relevancy\n\ \n\ @@ -1012,12 +1016,17 @@ throw(OptionException) { } break; case DECISION_MODE: + decisionOptions = defaultDecOpt; // reset all options if(!strcmp(optarg, "internal")) { decisionMode = DECISION_STRATEGY_INTERNAL; decisionModeSetByUser = true; } else if(!strcmp(optarg, "justification")) { decisionMode = DECISION_STRATEGY_JUSTIFICATION; decisionModeSetByUser = true; + } else if(!strcmp(optarg, "justification-stoponly")) { + decisionMode = DECISION_STRATEGY_JUSTIFICATION; + decisionModeSetByUser = true; + decisionOptions.stopOnly = true; } else if(!strcmp(optarg, "relevancy")) { decisionMode = DECISION_STRATEGY_RELEVANCY; decisionModeSetByUser = true; diff --git a/src/util/options.h b/src/util/options.h index bc99b5feb..ac95c99ca 100644 --- a/src/util/options.h +++ b/src/util/options.h @@ -156,6 +156,7 @@ struct CVC4_PUBLIC Options { unsigned short maxRelTimeAsPermille; /* permille = part per thousand */ bool computeRelevancy; /* if false, do justification stuff using relevancy.h */ bool mustRelevancy; /* use the must be relevant */ + bool stopOnly; /* only use decision stuff to stop early, not to decide */ }; DecisionOptions decisionOptions; -- 2.30.2