GCC Middle and Back End API Reference
_loop_vec_info Class Reference

#include <tree-vectorizer.h>

Inheritance diagram for _loop_vec_info:
Collaboration diagram for _loop_vec_info:

Public Types

enum  vec_kind { bb , loop }
 
typedef hash_set< int_hash< machine_mode, E_VOIDmode, E_BLKmode > > mode_set
 

Public Member Functions

 _loop_vec_info (class loop *, vec_info_shared *)
 
 ~_loop_vec_info ()
 
stmt_vec_info add_stmt (gimple *)
 
stmt_vec_info add_pattern_stmt (gimple *, stmt_vec_info)
 
stmt_vec_info resync_stmt_addr (gimple *)
 
stmt_vec_info lookup_stmt (gimple *)
 
stmt_vec_info lookup_def (tree)
 
stmt_vec_info lookup_single_use (tree)
 
class dr_vec_infolookup_dr (data_reference *)
 
void move_dr (stmt_vec_info, stmt_vec_info)
 
void remove_stmt (stmt_vec_info)
 
void replace_stmt (gimple_stmt_iterator *, stmt_vec_info, gimple *)
 
void insert_on_entry (stmt_vec_info, gimple *)
 
void insert_seq_on_entry (stmt_vec_info, gimple_seq)
 

Data Fields

class looploop
 
tree num_itersm1
 
tree num_iters
 
tree num_iters_unchanged
 
tree num_iters_assumptions
 
class vector_costsvector_costs
 
class vector_costsscalar_costs
 
unsigned int th
 
poly_uint64 versioning_threshold
 
poly_uint64 vectorization_factor
 
edge main_loop_edge
 
edge skip_main_loop_edge
 
edge skip_this_loop_edge
 
hash_map< tree, vect_reusable_accumulatorreusable_accumulators
 
unsigned int suggested_unroll_factor
 
unsigned HOST_WIDE_INT max_vectorization_factor
 
vec_loop_masks masks
 
vec_loop_lens lens
 
scalar_cond_masked_set_type scalar_cond_masked_set
 
vec_cond_masked_set_type vec_cond_masked_set
 
tree mask_skip_niters
 
tree rgroup_compare_type
 
tree simd_if_cond
 
tree rgroup_iv_type
 
vect_partial_vector_style partial_vector_style
 
class dr_vec_infounaligned_dr
 
int peeling_for_alignment
 
int ptr_mask
 
auto_vec< ddr_pmay_alias_ddrs
 
auto_vec< dr_with_seg_len_pair_tcomp_alias_ddrs
 
auto_vec< vec_object_paircheck_unequal_addrs
 
auto_vec< treecheck_nonzero
 
auto_vec< vec_lower_boundlower_bounds
 
auto_vec< stmt_vec_infomay_misalign_stmts
 
auto_vec< stmt_vec_inforeductions
 
auto_vec< stmt_vec_inforeduction_chains
 
auto_vec< stmt_info_for_costscalar_cost_vec
 
hash_map< tree_operand_hash, tree > * ivexpr_map
 
hash_map< tree, tree > * scan_map
 
poly_uint64 slp_unrolling_factor
 
unsigned int inner_loop_cost_factor
 
bool vectorizable
 
bool can_use_partial_vectors_p
 
bool must_use_partial_vectors_p
 
bool using_partial_vectors_p
 
bool using_decrementing_iv_p
 
bool using_select_vl_p
 
bool epil_using_partial_vectors_p
 
signed char partial_load_store_bias
 
bool peeling_for_gaps
 
bool peeling_for_niter
 
bool early_breaks
 
auto_vec< gcond * > conds
 
gcondloop_iv_cond
 
bool no_data_dependencies
 
bool has_mask_store
 
profile_probability scalar_loop_scaling
 
class loopscalar_loop
 
_loop_vec_infomain_loop_info
 
_loop_vec_infoorig_loop_info
 
_loop_vec_infoepilogue_vinfo
 
tree drs_advanced_by
 
edge vec_loop_iv_exit
 
edge vec_epilogue_loop_iv_exit
 
edge scalar_loop_iv_exit
 
auto_vec< gimple * > early_break_stores
 
basic_block early_break_dest_bb
 
auto_vec< gimple * > early_break_vuses
 
auto_vec< stmt_vec_infoearly_break_live_ivs
 
vec_kind kind
 
vec_info_sharedshared
 
vec< stmt_vec_infostmt_vec_infos
 
bool stmt_vec_info_ro
 
bool any_known_not_updated_vssa
 
auto_vec< slp_instanceslp_instances
 
vec_base_alignments base_alignments
 
auto_vec< stmt_vec_infogrouped_stores
 
mode_set used_vector_modes
 
machine_mode vector_mode
 
basic_blockbbs
 
unsigned int nbbs
 
gimple_seq inv_pattern_def_seq
 

Private Member Functions

stmt_vec_info new_stmt_vec_info (gimple *stmt)
 
void set_vinfo_for_stmt (gimple *, stmt_vec_info, bool=true)
 
void free_stmt_vec_infos ()
 
void free_stmt_vec_info (stmt_vec_info)
 

Detailed Description

Info on vectorized loops.                                        

Member Typedef Documentation

◆ mode_set

hash_set<int_hash<machine_mode, E_VOIDmode, E_BLKmode> > vec_info::mode_set
inherited

Member Enumeration Documentation

◆ vec_kind

enum vec_info::vec_kind
inherited
Enumerator
bb 
loop 

Constructor & Destructor Documentation

◆ _loop_vec_info()

◆ ~_loop_vec_info()

_loop_vec_info::~_loop_vec_info ( )
Free all memory used by the _loop_vec_info, as well as all the
stmt_vec_info structs of all the stmts in the loop.   

References loop::aux, vec_info::bbs, free(), ivexpr_map, lens, masks, NULL, release_vec_loop_controls(), vec_loop_masks::rgc_vec, scalar_costs, scan_map, and vector_costs.

Member Function Documentation

◆ add_pattern_stmt()

stmt_vec_info vec_info::add_pattern_stmt ( gimple * stmt,
stmt_vec_info stmt_info )
inherited
Record that STMT belongs to the vectorizable region.  Create a new
stmt_vec_info and mark VECINFO as being related and return the new
stmt_vec_info.   

References vec_info::new_stmt_vec_info(), vec_info::set_vinfo_for_stmt(), and STMT_VINFO_RELATED_STMT.

Referenced by addsub_pattern::build(), and complex_pattern::build().

◆ add_stmt()

◆ free_stmt_vec_info()

void vec_info::free_stmt_vec_info ( stmt_vec_info stmt_info)
privateinherited

◆ free_stmt_vec_infos()

void vec_info::free_stmt_vec_infos ( void )
privateinherited
Free the contents of stmt_vec_infos.   

References vec_info::free_stmt_vec_info(), NULL, and vec_info::stmt_vec_infos.

Referenced by vec_info::~vec_info().

◆ insert_on_entry()

void vec_info::insert_on_entry ( stmt_vec_info context,
gimple * new_stmt )
inherited
Like insert_seq_on_entry but just inserts the single stmt NEW_STMT.   

References gsi_insert_before_without_update(), GSI_SAME_STMT, gsi_start(), vec_info::insert_seq_on_entry(), and NULL.

Referenced by vect_init_vector_1().

◆ insert_seq_on_entry()

void vec_info::insert_seq_on_entry ( stmt_vec_info context,
gimple_seq seq )
inherited
Insert stmts in SEQ on the VEC_INFO region entry.  If CONTEXT is
not NULL it specifies whether to use the sub-region entry
determined by it, currently used for loop vectorization to insert
on the inner loop entry vs. the outer loop entry.   

References vec_info::bbs, dyn_cast(), gcc_assert, gsi_after_labels(), gsi_insert_seq_before(), gsi_insert_seq_on_edge_immediate(), GSI_SAME_STMT, loop::inner, loop_preheader_edge(), LOOP_VINFO_LOOP, and nested_in_vect_loop_p().

Referenced by vec_info::insert_on_entry(), vect_create_constant_vectors(), and vect_slp_region().

◆ lookup_def()

◆ lookup_dr()

◆ lookup_single_use()

stmt_vec_info vec_info::lookup_single_use ( tree lhs)
inherited
See whether there is a single non-debug statement that uses LHS and
whether that statement has an associated stmt_vec_info.  Return the
stmt_vec_info if so, otherwise return null.   

References vec_info::lookup_stmt(), NULL, and single_imm_use().

◆ lookup_stmt()

stmt_vec_info vec_info::lookup_stmt ( gimple * stmt)
inherited
If STMT has an associated stmt_vec_info, return that vec_info, otherwise
return null.  It is safe to call this function on any statement, even if
it might not be part of the vectorizable region.   

References gimple_uid(), NULL, and vec_info::stmt_vec_infos.

Referenced by check_scan_store(), gather_scalar_reductions(), vec_info::lookup_def(), vec_info::lookup_dr(), vec_info::lookup_single_use(), maybe_push_to_hybrid_worklist(), maybe_set_vectorized_backedge_value(), move_early_exit_stmts(), vec_slp_has_scalar_use(), vect_analyze_data_refs(), vect_analyze_early_break_dependences(), vect_analyze_loop_2(), vect_analyze_loop_operations(), vect_analyze_scalar_cycles_1(), vect_analyze_slp(), vect_analyze_stmt(), vect_bb_slp_mark_live_stmts(), vect_bb_slp_scalar_cost(), vect_build_slp_instance(), vect_build_slp_tree_2(), vect_can_advance_ivs_p(), vect_compute_single_scalar_iteration_cost(), vect_create_loop_vinfo(), vect_detect_hybrid_slp(), vect_determine_min_output_precision_1(), vect_determine_precisions(), vect_determine_vectorization_factor(), vect_determine_vf_for_stmt(), vect_dissolve_slp_only_groups(), vect_init_pattern_stmt(), vect_mark_pattern_stmts(), vect_mark_stmts_to_be_vectorized(), vect_pattern_recog(), vect_pattern_recog_1(), vect_set_loop_condition(), vect_slp_analyze_load_dependences(), vect_slp_analyze_store_dependences(), vect_slp_check_for_roots(), vect_transform_loop(), vect_update_ivs_after_vectorizer(), vect_update_vf_for_slp(), vectorizable_induction(), vectorizable_live_operation(), vectorizable_reduction(), and vectorizable_scan_store().

◆ move_dr()

void vec_info::move_dr ( stmt_vec_info new_stmt_info,
stmt_vec_info old_stmt_info )
inherited

◆ new_stmt_vec_info()

◆ remove_stmt()

void vec_info::remove_stmt ( stmt_vec_info stmt_info)
inherited

◆ replace_stmt()

void vec_info::replace_stmt ( gimple_stmt_iterator * gsi,
stmt_vec_info stmt_info,
gimple * new_stmt )
inherited
Replace the statement at GSI by NEW_STMT, both the vectorization
information and the function itself.  STMT_INFO describes the statement
at GSI.   

References gcc_assert, gimple_set_uid(), gimple_uid(), gsi_replace(), and gsi_stmt().

Referenced by vect_remove_slp_scalar_calls(), vectorizable_call(), and vectorizable_simd_clone_call().

◆ resync_stmt_addr()

stmt_vec_info vec_info::resync_stmt_addr ( gimple * stmt)
inherited
If STMT was previously associated with a stmt_vec_info and STMT now resides
at a different address than before (e.g., because STMT is a phi node that has
been resized), update the stored address to match the new one.  It is not
possible to use lookup_stmt () to perform this task, because that function
returns NULL if the stored stmt pointer does not match the one being looked
up.   

References gimple_uid(), and vec_info::stmt_vec_infos.

Referenced by vect_loop_versioning().

◆ set_vinfo_for_stmt()

void vec_info::set_vinfo_for_stmt ( gimple * stmt,
stmt_vec_info info,
bool check_ro = true )
privateinherited

Field Documentation

◆ any_known_not_updated_vssa

bool vec_info::any_known_not_updated_vssa
inherited

◆ base_alignments

vec_base_alignments vec_info::base_alignments
inherited

◆ bbs

◆ can_use_partial_vectors_p

bool _loop_vec_info::can_use_partial_vectors_p

◆ check_nonzero

auto_vec<tree> _loop_vec_info::check_nonzero

◆ check_unequal_addrs

auto_vec<vec_object_pair> _loop_vec_info::check_unequal_addrs

◆ comp_alias_ddrs

auto_vec<dr_with_seg_len_pair_t> _loop_vec_info::comp_alias_ddrs

◆ conds

auto_vec<gcond *> _loop_vec_info::conds

◆ drs_advanced_by

tree _loop_vec_info::drs_advanced_by

◆ early_break_dest_bb

basic_block _loop_vec_info::early_break_dest_bb

◆ early_break_live_ivs

auto_vec<stmt_vec_info> _loop_vec_info::early_break_live_ivs

◆ early_break_stores

auto_vec<gimple *> _loop_vec_info::early_break_stores

◆ early_break_vuses

auto_vec<gimple*> _loop_vec_info::early_break_vuses

◆ early_breaks

bool _loop_vec_info::early_breaks

◆ epil_using_partial_vectors_p

bool _loop_vec_info::epil_using_partial_vectors_p

◆ epilogue_vinfo

_loop_vec_info* _loop_vec_info::epilogue_vinfo

◆ grouped_stores

◆ has_mask_store

bool _loop_vec_info::has_mask_store

◆ inner_loop_cost_factor

unsigned int _loop_vec_info::inner_loop_cost_factor

◆ inv_pattern_def_seq

gimple_seq vec_info::inv_pattern_def_seq
inherited

◆ ivexpr_map

hash_map<tree_operand_hash, tree>* _loop_vec_info::ivexpr_map

◆ kind

vec_kind vec_info::kind
inherited

◆ lens

vec_loop_lens _loop_vec_info::lens

Referenced by ~_loop_vec_info().

◆ loop

class loop* _loop_vec_info::loop

◆ loop_iv_cond

gcond* _loop_vec_info::loop_iv_cond

◆ lower_bounds

auto_vec<vec_lower_bound> _loop_vec_info::lower_bounds

◆ main_loop_edge

◆ main_loop_info

_loop_vec_info* _loop_vec_info::main_loop_info

◆ mask_skip_niters

tree _loop_vec_info::mask_skip_niters

◆ masks

vec_loop_masks _loop_vec_info::masks

Referenced by ~_loop_vec_info().

◆ max_vectorization_factor

unsigned HOST_WIDE_INT _loop_vec_info::max_vectorization_factor

◆ may_alias_ddrs

auto_vec<ddr_p> _loop_vec_info::may_alias_ddrs

◆ may_misalign_stmts

auto_vec<stmt_vec_info> _loop_vec_info::may_misalign_stmts

◆ must_use_partial_vectors_p

bool _loop_vec_info::must_use_partial_vectors_p

◆ nbbs

◆ no_data_dependencies

bool _loop_vec_info::no_data_dependencies

◆ num_iters

tree _loop_vec_info::num_iters

◆ num_iters_assumptions

tree _loop_vec_info::num_iters_assumptions

◆ num_iters_unchanged

tree _loop_vec_info::num_iters_unchanged

◆ num_itersm1

tree _loop_vec_info::num_itersm1

◆ orig_loop_info

_loop_vec_info* _loop_vec_info::orig_loop_info

◆ partial_load_store_bias

signed char _loop_vec_info::partial_load_store_bias

◆ partial_vector_style

vect_partial_vector_style _loop_vec_info::partial_vector_style

◆ peeling_for_alignment

int _loop_vec_info::peeling_for_alignment

Referenced by vect_transform_loop().

◆ peeling_for_gaps

bool _loop_vec_info::peeling_for_gaps

Referenced by vect_transform_loop().

◆ peeling_for_niter

bool _loop_vec_info::peeling_for_niter

◆ ptr_mask

int _loop_vec_info::ptr_mask

◆ reduction_chains

auto_vec<stmt_vec_info> _loop_vec_info::reduction_chains

Referenced by vect_analyze_slp().

◆ reductions

auto_vec<stmt_vec_info> _loop_vec_info::reductions

◆ reusable_accumulators

◆ rgroup_compare_type

tree _loop_vec_info::rgroup_compare_type

◆ rgroup_iv_type

tree _loop_vec_info::rgroup_iv_type

◆ scalar_cond_masked_set

◆ scalar_cost_vec

auto_vec<stmt_info_for_cost> _loop_vec_info::scalar_cost_vec

◆ scalar_costs

◆ scalar_loop

class loop* _loop_vec_info::scalar_loop

◆ scalar_loop_iv_exit

edge _loop_vec_info::scalar_loop_iv_exit

◆ scalar_loop_scaling

profile_probability _loop_vec_info::scalar_loop_scaling

◆ scan_map

◆ shared

◆ simd_if_cond

tree _loop_vec_info::simd_if_cond

Referenced by _loop_vec_info().

◆ skip_main_loop_edge

◆ skip_this_loop_edge

edge _loop_vec_info::skip_this_loop_edge

◆ slp_instances

◆ slp_unrolling_factor

poly_uint64 _loop_vec_info::slp_unrolling_factor

◆ stmt_vec_info_ro

bool vec_info::stmt_vec_info_ro
inherited

◆ stmt_vec_infos

◆ suggested_unroll_factor

unsigned int _loop_vec_info::suggested_unroll_factor

◆ th

unsigned int _loop_vec_info::th

◆ unaligned_dr

class dr_vec_info* _loop_vec_info::unaligned_dr

◆ used_vector_modes

mode_set vec_info::used_vector_modes
inherited

◆ using_decrementing_iv_p

bool _loop_vec_info::using_decrementing_iv_p

◆ using_partial_vectors_p

bool _loop_vec_info::using_partial_vectors_p

◆ using_select_vl_p

bool _loop_vec_info::using_select_vl_p

◆ vec_cond_masked_set

◆ vec_epilogue_loop_iv_exit

edge _loop_vec_info::vec_epilogue_loop_iv_exit

◆ vec_loop_iv_exit

edge _loop_vec_info::vec_loop_iv_exit

◆ vector_costs

◆ vector_mode

◆ vectorizable

bool _loop_vec_info::vectorizable

◆ vectorization_factor

poly_uint64 _loop_vec_info::vectorization_factor

Referenced by vect_transform_loops().

◆ versioning_threshold

poly_uint64 _loop_vec_info::versioning_threshold

The documentation for this class was generated from the following files: