15 #ifndef CPROVER_GOTO_PROGRAMS_GOTO_INLINE_CLASS_H
16 #define CPROVER_GOTO_PROGRAMS_GOTO_INLINE_CLASS_H
18 #include <unordered_set>
41 :
log(message_handler),
54 typedef std::pair<goto_programt::targett, bool>
callt;
70 const bool force_full=
false);
80 const bool force_full =
false);
85 const bool force_full=
false);
128 const unsigned begin_location_number,
129 const unsigned end_location_number,
130 const unsigned call_location_number,
162 const bool force_full);
167 const bool force_full);
187 const bool transitive,
188 const bool force_full,
dstringt has one field, an unsigned integer no which is an index into a static table of strings.
Base class for all expressions.
std::vector< exprt > operandst
A collection of goto functions.
std::map< irep_idt, goto_functiont > function_mapt
::goto_functiont goto_functiont
A goto function, consisting of function body (see body) and parameter identifiers (see parameter_iden...
std::vector< irep_idt > parameter_identifierst
goto_programt::const_targett end
unsigned end_location_number
unsigned begin_location_number
unsigned call_location_number
void copy_from(const goto_programt &from, const goto_programt &to)
jsont output_inline_log_json() const
std::map< goto_programt::const_targett, goto_inline_log_infot, goto_programt::target_less_than > log_mapt
void cleanup(const goto_programt &goto_program)
void add_segment(const goto_programt &goto_program, const unsigned begin_location_number, const unsigned end_location_number, const unsigned call_location_number, const irep_idt function)
bool is_ignored(const irep_idt id) const
void goto_inline_nontransitive(const irep_idt identifier, goto_functiont &goto_function, const inline_mapt &inline_map, const bool force_full)
std::list< callt > call_listt
goto_functionst & goto_functions
static void get_call(goto_programt::const_targett target, exprt &lhs, exprt &function, exprt::operandst &arguments)
goto_inlinet(goto_functionst &goto_functions, const namespacet &ns, message_handlert &message_handler, bool adjust_function, bool caching=true)
Sets up the class with the program to operate on.
jsont output_inline_log_json()
const goto_functiont & goto_inline_transitive(const irep_idt identifier, const goto_functiont &goto_function, const bool force_full)
void goto_inline(const irep_idt identifier, goto_functiont &goto_function, const inline_mapt &inline_map, const bool force_full=false)
Inline all of the chosen calls in a given function.
recursion_sett recursion_set
void insert_function_body(const goto_functiont &f, goto_programt &dest, goto_programt::targett target, const exprt &lhs, const symbol_exprt &function, const exprt::operandst &arguments)
bool check_inline_map(const inline_mapt &inline_map) const
void parameter_destruction(const goto_programt::targett target, const goto_functiont::parameter_identifierst ¶meter_identifiers, goto_programt &dest)
const bool adjust_function
goto_inline_logt inline_log
void output_inline_map(std::ostream &out, const inline_mapt &inline_map)
std::unordered_set< irep_idt > finished_sett
goto_functionst::goto_functiont goto_functiont
void parameter_assignments(const goto_programt::targett target, const irep_idt &function_name, const goto_functiont::parameter_identifierst ¶meter_identifiers, const exprt::operandst &arguments, goto_programt &dest)
std::pair< goto_programt::targett, bool > callt
std::map< irep_idt, call_listt > inline_mapt
std::unordered_set< irep_idt > no_body_sett
void replace_return(goto_programt &body, const exprt &lhs)
finished_sett finished_set
std::unordered_set< irep_idt > recursion_sett
goto_functionst::function_mapt cachet
void expand_function_call(goto_programt &dest, const inline_mapt &inline_map, const bool transitive, const bool force_full, goto_programt::targett target)
Inlines a single function call Calls out to goto_inline_transitive or goto_inline_nontransitive.
void output_cache(std::ostream &out) const
A generic container class for the GOTO intermediate representation of one function.
instructionst::iterator targett
instructionst::const_iterator const_targett
Class that provides messages with a built-in verbosity 'level'.
A namespacet is essentially one or two symbol tables bound together, to allow for symbol lookups in t...
Expression to hold a symbol (variable)
Goto Programs with Functions.
A total order over targett and const_targett.