CBMC
|
#include <arrays.h>
Classes | |
struct | array_equalityt |
struct | lazy_constraintt |
Public Types | |
typedef equalityt | SUB |
![]() | |
using | SUB = prop_conv_solvert |
![]() | |
typedef std::map< irep_idt, literalt > | symbolst |
typedef std::unordered_map< exprt, literalt, irep_hash > | cachet |
![]() | |
enum class | resultt { D_SATISFIABLE , D_UNSATISFIABLE , D_ERROR } |
Result of running the decision procedure. More... | |
Public Member Functions | |
arrayst (const namespacet &_ns, propt &_prop, message_handlert &message_handler, bool get_array_constraints=false) | |
void | finish_eager_conversion () override |
literalt | record_array_equality (const equal_exprt &expr) |
void | record_array_index (const index_exprt &expr) |
![]() | |
equalityt (propt &_prop, message_handlert &message_handler) | |
virtual literalt | equality (const exprt &e1, const exprt &e2) |
void | finish_eager_conversion () override |
![]() | |
prop_conv_solvert (propt &_prop, message_handlert &message_handler) | |
virtual | ~prop_conv_solvert ()=default |
decision_proceduret::resultt | dec_solve (const exprt &) override |
Implementation of the decision procedure. | |
void | print_assignment (std::ostream &out) const override |
Print satisfying assignment to out . | |
std::string | decision_procedure_text () const override |
Return a textual description of the decision procedure. | |
exprt | get (const exprt &expr) const override |
Return expr with variables replaced by values from satisfying assignment if available. | |
tvt | l_get (literalt a) const override |
Return value of literal l from satisfying assignment. | |
exprt | handle (const exprt &expr) override |
Generate a handle, which is an expression that has the same value as the argument in any model that is generated; this offers an efficient way to refer to the expression in subsequent calls to get or set_to. | |
void | set_frozen (literalt) |
void | set_frozen (const bvt &) |
void | set_all_frozen () |
literalt | convert (const exprt &expr) override |
Convert a Boolean expression and return the corresponding literal. | |
bool | is_in_conflict (const exprt &expr) const override |
Returns true if an expression is in the final conflict leading to UNSAT. | |
void | set_to (const exprt &expr, bool value) override |
For a Boolean expression expr , add the constraint 'current_context => expr' if value is true , otherwise add 'current_context => not expr'. | |
void | push () override |
Push a new context on the stack This context becomes a child context nested in the current context. | |
void | push (const std::vector< exprt > &assumptions) override |
Push assumptions in form of literal_exprt | |
void | pop () override |
Pop whatever is on top of the stack. | |
virtual void | clear_cache () |
const cachet & | get_cache () const |
const symbolst & | get_symbols () const |
void | set_time_limit_seconds (uint32_t lim) override |
Set the limit for the solver to time out in seconds. | |
std::size_t | get_number_of_solver_calls () const override |
Return the number of incremental solver calls. | |
hardness_collectort * | get_hardness_collector () |
![]() | |
virtual | ~conflict_providert ()=default |
![]() | |
virtual | ~prop_convt () |
![]() | |
virtual | ~stack_decision_proceduret ()=default |
![]() | |
void | set_to_true (const exprt &) |
For a Boolean expression expr , add the constraint 'expr'. | |
void | set_to_false (const exprt &) |
For a Boolean expression expr , add the constraint 'not expr'. | |
resultt | operator() () |
Run the decision procedure to solve the problem This corresponds to SMT-LIB's check-sat. | |
resultt | operator() (const exprt &assumption) |
Run the decision procedure to solve the problem under the given assumption. | |
virtual | ~decision_proceduret () |
![]() | |
virtual | ~solver_resource_limitst ()=default |
Protected Types | |
enum class | lazy_typet { ARRAY_ACKERMANN , ARRAY_WITH , ARRAY_IF , ARRAY_OF , ARRAY_TYPECAST , ARRAY_CONSTANT , ARRAY_COMPREHENSION , ARRAY_LET } |
enum class | constraint_typet { ARRAY_ACKERMANN , ARRAY_WITH , ARRAY_IF , ARRAY_OF , ARRAY_TYPECAST , ARRAY_CONSTANT , ARRAY_COMPREHENSION , ARRAY_EQUALITY , ARRAY_LET } |
typedef std::list< array_equalityt > | array_equalitiest |
typedef std::set< exprt > | index_sett |
typedef std::map< std::size_t, index_sett > | index_mapt |
typedef std::map< constraint_typet, size_t > | array_constraint_countt |
![]() | |
typedef std::unordered_map< const exprt, unsigned, irep_hash > | elementst |
typedef std::map< std::pair< unsigned, unsigned >, literalt > | equalitiest |
typedef std::map< unsigned, exprt > | elements_revt |
typedef std::unordered_map< const typet, typestructt, irep_hash > | typemapt |
Protected Attributes | |
const namespacet & | ns |
messaget | log |
message_handlert & | message_handler |
array_equalitiest | array_equalities |
union_find< exprt, irep_hash > | arrays |
index_mapt | index_map |
bool | lazy_arrays |
bool | incremental_cache |
bool | get_array_constraints |
std::list< lazy_constraintt > | lazy_array_constraints |
std::map< exprt, bool > | expr_map |
array_constraint_countt | array_constraint_count |
std::set< std::size_t > | update_indices |
std::unordered_set< irep_idt > | array_comprehension_args |
![]() | |
typemapt | typemap |
![]() | |
bool | post_processing_done = false |
symbolst | symbols |
cachet | cache |
propt & | prop |
messaget | log |
bvt | assumption_stack |
Assumptions on the stack. | |
std::size_t | context_literal_counter = 0 |
To generate unique literal names for contexts. | |
std::vector< size_t > | context_size_stack |
assumption_stack is segmented in contexts; Number of assumptions in each context on the stack | |
Additional Inherited Members | |
![]() | |
bool | use_cache = true |
bool | equality_propagation = true |
bool | freeze_all = false |
![]() | |
static const char * | context_prefix = "prop_conv::context$" |
|
protected |
|
protected |
|
protected |
|
protected |
|
strongprotected |
|
strongprotected |
arrayst::arrayst | ( | const namespacet & | _ns, |
propt & | _prop, | ||
message_handlert & | message_handler, | ||
bool | get_array_constraints = false |
||
) |
Definition at line 29 of file arrays.cpp.
|
protected |
Definition at line 330 of file arrays.cpp.
|
protected |
adds array constraints (refine=true...lazily for the refinement loop)
Definition at line 255 of file arrays.cpp.
|
protected |
Definition at line 280 of file arrays.cpp.
|
protected |
Definition at line 475 of file arrays.cpp.
|
protected |
Definition at line 734 of file arrays.cpp.
|
protected |
Definition at line 709 of file arrays.cpp.
|
protected |
Definition at line 815 of file arrays.cpp.
|
protected |
Definition at line 441 of file arrays.cpp.
|
protected |
Definition at line 839 of file arrays.cpp.
|
protected |
Definition at line 652 of file arrays.cpp.
|
protected |
Definition at line 573 of file arrays.cpp.
Definition at line 131 of file arrays.cpp.
|
protected |
Definition at line 83 of file arrays.cpp.
Definition at line 91 of file arrays.cpp.
|
protected |
Definition at line 918 of file arrays.cpp.
|
protected |
Definition at line 891 of file arrays.cpp.
|
inlineoverridevirtual |
Reimplemented from prop_conv_solvert.
Reimplemented in bv_pointers_widet, boolbvt, and bv_pointerst.
Reimplemented in bv_refinementt.
Implemented in boolbvt.
literalt arrayst::record_array_equality | ( | const equal_exprt & | expr | ) |
Definition at line 55 of file arrays.cpp.
void arrayst::record_array_index | ( | const index_exprt & | expr | ) |
Definition at line 45 of file arrays.cpp.
Definition at line 407 of file arrays.cpp.
|
protected |
merge the indices into the root
Definition at line 393 of file arrays.cpp.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |