sygusComp2018: update sygus-related options setting in smt engine (#2108)
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>
Tue, 3 Jul 2018 02:42:55 +0000 (21:42 -0500)
committerGitHub <noreply@github.com>
Tue, 3 Jul 2018 02:42:55 +0000 (21:42 -0500)
src/smt/smt_engine.cpp

index 53ea9fd58f0a3192dce96444c0efbaf4c9a56efb..22916e35474bff7f49161030af630551b91cc68c 100644 (file)
@@ -1292,8 +1292,10 @@ void SmtEngine::setDefaults() {
     options::bitvectorDivByZeroConst.set(
         language::isInputLang_smt2_6(options::inputLanguage()));
   }
+  bool is_sygus = false;
   if (options::inputLanguage() == language::input::LANG_SYGUS)
   {
+    is_sygus = true;
     if (!options::ceGuidedInst.wasSetByUser())
     {
       options::ceGuidedInst.set(true);
@@ -1303,17 +1305,14 @@ void SmtEngine::setDefaults() {
     {
       options::cbqiMidpoint.set(true);
     }
-    // do not assign function values (optimization)
-    if (!options::assignFunctionValues.wasSetByUser())
+    if (options::sygusRepairConst())
     {
-      options::assignFunctionValues.set(false);
+      if (!options::cbqi.wasSetByUser())
+      {
+        options::cbqi.set(true);
+      }
     }
   }
-  else
-  {
-    // cannot use sygus repair constants
-    options::sygusRepairConst.set(false);
-  }
 
   if (options::bitblastMode() == theory::bv::BITBLAST_MODE_EAGER)
   {
@@ -1603,7 +1602,7 @@ void SmtEngine::setDefaults() {
   // cases where we need produce models
   if (!options::produceModels()
       && (options::produceAssignments() || options::sygusRewSynthCheck()
-          || options::sygusRepairConst()))
+          || is_sygus))
   {
     Notice() << "SmtEngine: turning on produce-models" << endl;
     setOption("produce-models", SExpr("true"));