Go to the documentation of this file.
40 #ifndef CPROVER_ANALYSES_AI_DOMAIN_H
41 #define CPROVER_ANALYSES_AI_DOMAIN_H
125 virtual bool is_top()
const = 0;
179 virtual std::unique_ptr<statet>
copy(
const statet &s)
const = 0;
195 template <
typename domainT>
205 return util_make_unique<domainT>(
static_cast<const domainT &
>(s));
212 return static_cast<domainT &
>(dest).
merge(
213 static_cast<const domainT &
>(src), from, to);
217 template <
typename domainT>
228 auto d = util_make_unique<domainT>();
230 return std::unique_ptr<statet>(d.release());
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
virtual bool merge(statet &dest, const statet &src, trace_ptrt from, trace_ptrt to) const =0
ai_domain_factory_baset::trace_ptrt trace_ptrt
virtual void make_bottom()=0
no states
ai_domain_baset(const ai_domain_baset &old)
A copy constructor is part of the domain interface.
#define CHECK_RETURN(CONDITION)
ai_domain_baset::trace_ptrt trace_ptrt
virtual std::unique_ptr< statet > make(locationt l) const =0
Base class for all expressions.
virtual jsont output_json(const ai_baset &ai, const namespacet &ns) const
virtual bool is_bottom() const =0
ai_history_baset::trace_ptrt trace_ptrt
virtual std::unique_ptr< statet > copy(const statet &s) const =0
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
virtual void transform(const irep_idt &function_from, trace_ptrt from, const irep_idt &function_to, trace_ptrt to, ai_baset &ai, const namespacet &ns)=0
how function calls are treated: a) there is an edge from each call site to the function head b) there...
ai_domain_factory_baset::trace_ptrt trace_ptrt
ai_domain_baset()
The constructor is expected to produce 'false' or 'bottom' A default constructor is not part of the d...
virtual bool ai_simplify_lhs(exprt &condition, const namespacet &ns) const
Simplifies the expression but keeps it as an l-value.
virtual xmlt output_xml(const ai_baset &ai, const namespacet &ns) const
The Boolean constant false.
ai_domain_factory_baset::locationt locationt
bool merge(statet &dest, const statet &src, trace_ptrt from, trace_ptrt to) const override
virtual ~ai_domain_factory_baset()
virtual ~ai_domain_baset()
std::unique_ptr< statet > make(locationt l) const override
ai_domain_factory_baset::locationt locationt
goto_programt::const_targett locationt
ai_domain_factory_baset::statet statet
ai_domain_factory_baset::statet statet
std::shared_ptr< const ai_history_baset > trace_ptrt
History objects are intended to be immutable so they can be shared to reduce memory overhead.
virtual exprt to_predicate(void) const
Gives a Boolean condition that is true for all values represented by the domain.
This is the basic interface of the abstract interpreter with default implementations of the core func...
ai_domain_baset::locationt locationt
instructionst::const_iterator const_targett
virtual void make_entry()=0
Make this domain a reasonable entry-point state.
virtual bool is_top() const =0
virtual bool ai_simplify(exprt &condition, const namespacet &) const
also add
The Boolean constant true.
The interface offered by a domain, allows code to manipulate domains without knowing their exact type...
virtual void output(std::ostream &, const ai_baset &, const namespacet &) const
std::unique_ptr< statet > copy(const statet &s) const override
virtual void make_top()=0
all states – the analysis doesn't use this, and domains may refuse to implement it.