| GCC Middle and Back End API Reference
    | 
#include <region.h>


| Public Types | |
| typedef unsigned | id_t | 
| Static Public Member Functions | |
| static int | cmp_ptr_ptr (const void *, const void *) | 
| static int | cmp_ids (const symbol *s1, const symbol *s2) | 
| Protected Member Functions | |
| region (complexity c, symbol::id_t id, const region *parent, tree type) | |
| Private Member Functions | |
| region_offset | calc_offset (region_model_manager *mgr) const | 
| const svalue * | calc_initial_value_at_main (region_model_manager *mgr) const | 
| virtual void | print_dump_widget_label (pretty_printer *pp) const =0 | 
| virtual void | add_dump_widget_children (text_art::tree_widget &, const text_art::dump_widget_info &dwi) const | 
| Private Attributes | |
| const region * | m_parent | 
| tree | m_type | 
| region_offset * | m_cached_offset | 
| const svalue * | m_cached_init_sval_at_main | 
| complexity | m_complexity | 
| id_t | m_id | 
Region and its subclasses.
The class hierarchy looks like this (using indentation to show
inheritance, and with region_kinds shown for the concrete subclasses):
region
  space_region
    frame_region (RK_FRAME): a function frame on the stack
    globals_region (RK_GLOBALS): holds globals variables (data and bss)
    code_region (RK_CODE): represents the code segment, containing functions
    stack_region (RK_STACK): a stack, containing all stack frames
    heap_region (RK_HEAP): the heap, containing heap_allocated_regions
    thread_local_region (RK_THREAD_LOCAL): thread-local data for the thread
                                           being analyzed
  root_region (RK_ROOT): the top-level region
  function_region (RK_FUNCTION): the code for a particular function
  label_region (RK_LABEL): a particular label within a function
  symbolic_region (RK_SYMBOLIC): dereferencing a symbolic pointer
  decl_region (RK_DECL): the memory occupied by a particular global, local,
                    or SSA name
  field_region (RK_FIELD): the memory occupied by a field within a struct
                      or union
  element_region (RK_ELEMENT): an element within an array
  offset_region (RK_OFFSET): a byte-offset within another region, for
                        handling pointer arithmetic as a region
  sized_region (RK_SIZED): a subregion of symbolic size (in bytes)
                      within its parent
  cast_region (RK_CAST): a region that views another region using a
                    different type
  heap_allocated_region (RK_HEAP_ALLOCATED): an untyped region dynamically
                                        allocated on the heap via
                                        "malloc" or similar
  alloca_region (RK_ALLOCA): an untyped region dynamically allocated on the
                        stack via "alloca"
  string_region (RK_STRING): a region for a STRING_CST
  bit_range_region (RK_BIT_RANGE): a region for a specific range of bits
                              within another region
  var_arg_region (RK_VAR_ARG): a region for the N-th vararg within a
                          frame_region for a variadic call
  errno_region (RK_ERRNO): a region for holding "errno"
  private_region (RK_PRIVATE): a region for internal state of an API
  unknown_region (RK_UNKNOWN): for handling unimplemented tree codes.    Abstract base class for representing ways of accessing chunks of memory. Regions form a tree-like hierarchy, with a root region at the base, with memory space regions within it, representing the stack and globals, with frames within the stack, and regions for variables within the frames and the "globals" region. Regions for structs can have subregions for fields.
| 
 | inherited | 
| 
 | virtual | 
| 
 | protected | 
References region().
Referenced by ana::alloca_region::alloca_region(), ana::bit_range_region::bit_range_region(), ana::cast_region::cast_region(), ana::decl_region::decl_region(), descendent_of_p(), ana::element_region::element_region(), ana::errno_region::errno_region(), ana::field_region::field_region(), ana::function_region::function_region(), get_base_region(), get_parent_region(), ana::heap_allocated_region::heap_allocated_region(), ana::bit_range_region::key_t::is_deleted(), ana::cast_region::key_t::is_deleted(), ana::bit_range_region::key_t::key_t(), ana::cast_region::key_t::key_t(), ana::element_region::key_t::key_t(), ana::field_region::key_t::key_t(), ana::offset_region::key_t::key_t(), ana::sized_region::key_t::key_t(), ana::symbolic_region::key_t::key_t(), ana::label_region::label_region(), ana::bit_range_region::key_t::mark_deleted(), ana::cast_region::key_t::mark_deleted(), ana::offset_region::offset_region(), ana::private_region::private_region(), region(), ana::sized_region::sized_region(), ana::space_region::space_region(), ana::string_region::string_region(), ana::symbolic_region::symbolic_region(), ana::unknown_region::unknown_region(), and ana::var_arg_region::var_arg_region().
| 
 | virtual | 
Reimplemented in ana::element_region, ana::frame_region, ana::offset_region, ana::sized_region, and ana::symbolic_region.
| 
 | privatevirtual | 
Reimplemented in ana::element_region, ana::offset_region, ana::sized_region, and ana::symbolic_region.
| bool ana::region::base_region_p | ( | ) | const | 
| 
 | private | 
| 
 | private | 
| bool ana::region::can_have_initial_svalue_p | ( | ) | const | 
References symbol().
| 
 | static | 
| void ana::region::dump | ( | ) | const | 
| void ana::region::dump | ( | bool | simple | ) | const | 
| 
 | pure virtual | 
Implemented in ana::alloca_region, ana::bit_range_region, ana::cast_region, ana::code_region, ana::decl_region, ana::element_region, ana::errno_region, ana::field_region, ana::frame_region, ana::function_region, ana::globals_region, ana::heap_allocated_region, ana::heap_region, ana::label_region, ana::offset_region, ana::private_region, ana::root_region, ana::sized_region, ana::stack_region, ana::string_region, ana::symbolic_region, ana::thread_local_region, ana::unknown_region, and ana::var_arg_region.
| 
 | inlinevirtual | 
Reimplemented in ana::bit_range_region.
| 
 | inlinevirtual | 
Reimplemented in ana::cast_region.
| 
 | inlinevirtual | 
Reimplemented in ana::decl_region.
| 
 | inlinevirtual | 
Reimplemented in ana::element_region.
| 
 | inlinevirtual | 
Reimplemented in ana::field_region.
| 
 | inlinevirtual | 
Reimplemented in ana::frame_region.
| 
 | inlinevirtual | 
Reimplemented in ana::function_region.
| 
 | inlinevirtual | 
Reimplemented in ana::offset_region.
| 
 | inlinevirtual | 
Reimplemented in ana::sized_region.
| 
 | inlinevirtual | 
Reimplemented in ana::string_region.
| 
 | inlinevirtual | 
Reimplemented in ana::symbolic_region.
| 
 | inlinevirtual | 
Reimplemented in ana::var_arg_region.
| bool ana::region::empty_p | ( | ) | const | 
| 
 | virtual | 
Reimplemented in ana::bit_range_region, and ana::sized_region.
| 
 | virtual | 
Reimplemented in ana::bit_range_region, and ana::sized_region.
| 
 | virtual | 
Reimplemented in ana::bit_range_region, and ana::sized_region.
| 
 | virtual | 
Reimplemented in ana::bit_range_region, and ana::sized_region.
| 
 | inlineinherited | 
References m_complexity.
Referenced by ana::binop_svalue::binop_svalue(), and ana::widening_svalue::widening_svalue().
| const svalue * ana::region::get_initial_value_at_main | ( | region_model_manager * | mgr | ) | const | 
| 
 | pure virtual | 
Implemented in ana::alloca_region, ana::bit_range_region, ana::cast_region, ana::code_region, ana::decl_region, ana::element_region, ana::errno_region, ana::field_region, ana::frame_region, ana::function_region, ana::globals_region, ana::heap_allocated_region, ana::heap_region, ana::label_region, ana::offset_region, ana::private_region, ana::root_region, ana::sized_region, ana::stack_region, ana::string_region, ana::symbolic_region, ana::thread_local_region, ana::unknown_region, and ana::var_arg_region.
Referenced by remap_enclosing_frame().
| enum memory_space ana::region::get_memory_space | ( | ) | const | 
| region_offset ana::region::get_next_offset | ( | region_model_manager * | mgr | ) | const | 
| region_offset ana::region::get_offset | ( | region_model_manager * | mgr | ) | const | 
| 
 | inline | 
References m_parent, and region().
Referenced by remap_enclosing_frame().
| bool ana::region::get_relative_concrete_byte_range | ( | byte_range * | out | ) | const | 
| 
 | virtual | 
Reimplemented in ana::bit_range_region, ana::cast_region, ana::element_region, ana::field_region, and ana::offset_region.
| 
 | virtual | 
Reimplemented in ana::bit_range_region, ana::element_region, ana::field_region, and ana::offset_region.
| void ana::region::get_subregions_for_binding | ( | region_model_manager * | mgr, | 
| bit_offset_t | start_bit_offset, | ||
| bit_size_t | size_in_bits, | ||
| tree | type, | ||
| auto_vec< const region * > * | out ) const | 
| bool ana::region::is_named_decl_p | ( | const char * | decl_name | ) | const | 
| std::unique_ptr< text_art::tree_widget > ana::region::make_dump_widget | ( | const text_art::dump_widget_info & | dwi, | 
| const char * | prefix = nullptr ) const | 
| tree ana::region::maybe_get_decl | ( | ) | const | 
| const frame_region * ana::region::maybe_get_frame_region | ( | ) | const | 
Referenced by sufficiently_different_region_binding_p().
| bool ana::region::maybe_print_for_user | ( | pretty_printer * | pp, | 
| const region_model & | model ) const | 
| bool ana::region::non_null_p | ( | ) | const | 
| void ana::region::print | ( | const region_model & | model, | 
| pretty_printer * | pp ) const | 
| 
 | privatepure virtual | 
Implemented in ana::alloca_region, ana::bit_range_region, ana::cast_region, ana::code_region, ana::decl_region, ana::element_region, ana::errno_region, ana::field_region, ana::frame_region, ana::function_region, ana::globals_region, ana::heap_allocated_region, ana::heap_region, ana::label_region, ana::offset_region, ana::private_region, ana::root_region, ana::sized_region, ana::stack_region, ana::string_region, ana::symbolic_region, ana::thread_local_region, ana::unknown_region, and ana::var_arg_region.
| bool ana::region::symbolic_for_unknown_ptr_p | ( | ) | const | 
| bool ana::region::symbolic_p | ( | ) | const | 
| std::unique_ptr< json::value > ana::region::to_json | ( | ) | const | 
| 
 | inlinevirtual | 
Reimplemented in ana::decl_region, and ana::string_region.
| 
 | mutableprivate | 
| 
 | mutableprivate | 
| 
 | privateinherited | 
Referenced by get_complexity(), and symbol().
| 
 | private | 
Referenced by get_parent_region().
| 
 | private | 
Referenced by get_type().