GCC Middle and Back End API Reference
tree-scalar-evolution.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

tree number_of_latch_executions (struct loop *)
tree number_of_exit_cond_executions (struct loop *)
gimple get_loop_exit_condition (const struct loop *)
void scev_initialize (void)
bool scev_initialized_p (void)
void scev_reset (void)
void scev_reset_htab (void)
void scev_finalize (void)
tree analyze_scalar_evolution (struct loop *, tree)
tree instantiate_scev (basic_block, struct loop *, tree)
tree resolve_mixers (struct loop *, tree)
void gather_stats_on_scev_database (void)
unsigned int scev_const_prop (void)
bool expression_expensive_p (tree)
bool simple_iv (struct loop *, struct loop *, tree, affine_iv *, bool)
tree compute_overall_effect_of_inner_loop (struct loop *, tree)
static basic_block block_before_loop ()
static tree instantiate_parameters ()
static struct loopget_chrec_loop ()

Function Documentation

tree analyze_scalar_evolution ( struct loop ,
tree   
)
static basic_block block_before_loop ( )
inlinestatic
Returns the basic block preceding LOOP or ENTRY_BLOCK_PTR when the
   loop is function's body.   

References loop_preheader_edge(), and edge_def::src.

Referenced by analyze_scalar_evolution(), analyze_scalar_evolution_1(), dr_analyze_indices(), instantiate_parameters(), and resolve_mixers().

tree compute_overall_effect_of_inner_loop ( struct loop ,
tree   
)
bool expression_expensive_p ( tree  )
void gather_stats_on_scev_database ( void  )
gimple get_loop_exit_condition ( const struct loop )
static tree instantiate_parameters ( )
inlinestatic
Analyze all the parameters of the chrec that were left under a
   symbolic form.  LOOP is the loop in which symbolic names have to
   be analyzed and instantiated.   

References block_before_loop(), and instantiate_scev().

Referenced by adjust_range_with_scev(), compute_overall_effect_of_inner_loop(), idx_infer_loop_bounds(), infer_loop_bounds_from_pointer_arith(), infer_loop_bounds_from_signedness(), simplify_using_outer_evolutions(), and vrp_var_may_overflow().

tree instantiate_scev ( basic_block  instantiate_below,
struct loop evolution_loop,
tree  chrec 
)
Analyze all the parameters of the chrec that were left under a
   symbolic form.  INSTANTIATE_BELOW is the basic block that stops the
   recursive instantiation of parameters: a parameter is a variable
   that is defined in a basic block that dominates INSTANTIATE_BELOW or
   a function parameter.   

References cache, dump_file, dump_flags, basic_block_def::index, instantiate_scev_r(), loop::num, and print_generic_expr().

Referenced by dr_analyze_indices(), graphite_can_represent_expr(), instantiate_parameters(), and scalar_evolution_in_region().

tree number_of_exit_cond_executions ( struct loop )
tree number_of_latch_executions ( struct loop )
tree resolve_mixers ( struct loop ,
tree   
)
bool scev_initialized_p ( void  )
Return true if SCEV is initialized.   

References scalar_evolution_info.

Referenced by estimated_loop_iterations(), fini_copy_prop(), and max_loop_iterations().

void scev_reset_htab ( void  )
Cleans up the information cached by the scalar evolutions analysis
   in the hash table.   

References scalar_evolution_info.

Referenced by rewrite_commutative_reductions_out_of_ssa(), rewrite_cross_bb_scalar_deps_out_of_ssa(), and scev_reset().

bool simple_iv ( struct loop wrto_loop,
struct loop use_loop,
tree  op,
affine_iv iv,
bool  allow_nonconstant_step 
)
Checks whether use of OP in USE_LOOP behaves as a simple affine iv with
   respect to WRTO_LOOP and returns its base and step in IV if possible
   (see analyze_scalar_evolution_in_loop for more details on USE_LOOP
   and WRTO_LOOP).  If ALLOW_NONCONSTANT_STEP is true, we want step to be
   invariant in LOOP.  Otherwise we require it to be an integer constant.

   IV->no_overflow is set to true if we are sure the iv cannot overflow (e.g.
   because it is computed in signed arithmetics).  Consequently, adding an
   induction variable

   for (i = IV->base; ; i += IV->step)

   is only safe if IV->no_overflow is false, or TYPE_OVERFLOW_UNDEFINED is
   false for the type of the induction variable, or you can prove that i does
   not wrap by some other argument.  Otherwise, this might introduce undefined
   behavior, and

   for (i = iv->base; ; i = (type) ((unsigned type) i + (unsigned type) iv->step))

   must be used instead.   

References analyze_scalar_evolution_in_loop(), affine_iv::base, build_int_cst(), chrec_contains_symbols_defined_in_loop(), chrec_contains_undetermined(), affine_iv::no_overflow, loop::num, affine_iv::step, tree_contains_chrecs(), tree_does_not_contain_chrecs(), and type().

Referenced by constant_after_peeling(), determine_biv_step(), dr_analyze_innermost(), estimate_function_body_sizes(), find_givs_in_stmt_scev(), gather_scalar_reductions(), idx_analyze_ref(), inhibit_phi_insertion(), is_comparison_with_loop_invariant_p(), number_of_iterations_exit(), ref_at_iteration(), rewrite_phi_with_iv(), try_create_reduction_list(), and vect_analyze_data_refs().