3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-10-04 15:03:57 +00:00

fix out-of-range integer comparison bug in string NFA

This commit is contained in:
Murphy Berzish 2016-08-17 20:58:57 -04:00
parent 71ad4d3a4a
commit 6263391c11
4 changed files with 243 additions and 165 deletions

View file

@ -25,6 +25,7 @@ Revision History:
#include"arith_decl_plugin.h"
#include<set>
#include<stack>
#include"str_rewriter.h"
namespace smt {
@ -137,6 +138,14 @@ namespace smt {
*/
bool opt_DisableIntegerTheoryIntegration;
/*
* If NoCheckRegexIn is set to true,
* an expensive regular expression membership test is skipped.
* This option is for experiment purposes only and should be set to 'false'
* as skipping this check impacts the correctness of the solver.
*/
bool opt_NoCheckRegexIn;
bool search_started;
arith_util m_autil;
str_util m_strutil;
@ -221,6 +230,8 @@ namespace smt {
std::map<std::pair<expr*, std::string>, expr*> regex_in_bool_map;
std::map<expr*, std::set<std::string> > regex_in_var_reg_str_map;
std::map<expr*, nfa> regex_nfa_cache; // Regex term --> NFA
char * char_set;
std::map<char, int> charSetLookupTable;
int charSetSize;
@ -423,6 +434,7 @@ namespace smt {
expr * gen_unroll_assign(expr * var, std::string lcmStr, expr * testerVar, int l, int h);
void reduce_virtual_regex_in(expr * var, expr * regex, expr_ref_vector & items);
std::string get_std_regex_str(expr * regex);
void check_regex_in(expr * nn1, expr * nn2);
void dump_assignments();
void initialize_charset();