diff options
author | Martin <martin.brain@diffblue.com> | 2017-09-14 04:51:50 +0100 |
---|---|---|
committer | Aina Niemetz <aina.niemetz@gmail.com> | 2017-09-13 20:51:50 -0700 |
commit | 4a014a12d7f72c4f73dfbee8c9f62868e920bc15 (patch) | |
tree | d6bcf71456c10122cb0e90bebebba095f0f75900 /src/theory | |
parent | daf1d6bf1176834fa697dd57c6fe28142e715585 (diff) |
Floating point symfpu support (#1093)
Changes needed for the bit-blasting floating-point solver which are outside of it's area and / or applicable independently.
Diffstat (limited to 'src/theory')
-rw-r--r-- | src/theory/fp/theory_fp_type_rules.h | 2 | ||||
-rw-r--r-- | src/theory/theory_engine.cpp | 6 | ||||
-rw-r--r-- | src/theory/theory_engine.h | 2 |
3 files changed, 6 insertions, 4 deletions
diff --git a/src/theory/fp/theory_fp_type_rules.h b/src/theory/fp/theory_fp_type_rules.h index 296a2f475..8dddf5065 100644 --- a/src/theory/fp/theory_fp_type_rules.h +++ b/src/theory/fp/theory_fp_type_rules.h @@ -180,7 +180,7 @@ class FloatingPointRoundingOperationTypeRule { for (size_t i = 2; i < children; ++i) { if (!(n[i].getType(check) == firstOperand)) { throw TypeCheckingExceptionPrivate( - n, "floating-point test applied to mixed sorts"); + n, "floating-point operation applied to mixed sorts"); } } } diff --git a/src/theory/theory_engine.cpp b/src/theory/theory_engine.cpp index 59a52a048..892b331ea 100644 --- a/src/theory/theory_engine.cpp +++ b/src/theory/theory_engine.cpp @@ -2208,7 +2208,7 @@ void TheoryEngine::handleUserAttribute(const char* attr, Theory* t) { d_attr_handle[ str ].push_back( t ); } -void TheoryEngine::checkTheoryAssertionsWithModel() { +void TheoryEngine::checkTheoryAssertionsWithModel(bool hardFailure) { for(TheoryId theoryId = THEORY_FIRST; theoryId < THEORY_LAST; ++theoryId) { Theory* theory = d_theoryTable[theoryId]; if(theory && d_logicInfo.isTheoryEnabled(theoryId)) { @@ -2223,7 +2223,9 @@ void TheoryEngine::checkTheoryAssertionsWithModel() { ss << theoryId << " has an asserted fact that the model doesn't satisfy." << endl << "The fact: " << assertion << endl << "Model value: " << val << endl; - InternalError(ss.str()); + if(hardFailure) { + InternalError(ss.str()); + } } } } diff --git a/src/theory/theory_engine.h b/src/theory/theory_engine.h index 7dd3f57a6..3ae0b840b 100644 --- a/src/theory/theory_engine.h +++ b/src/theory/theory_engine.h @@ -883,7 +883,7 @@ public: * Check that the theory assertions are satisfied in the model. * This function is called from the smt engine's checkModel routine. */ - void checkTheoryAssertionsWithModel(); + void checkTheoryAssertionsWithModel(bool hardFailure); private: IntStat d_arithSubstitutionsAdded; |