mirror of git://gcc.gnu.org/git/gcc.git
[39/46] Change STMT_VINFO_UNALIGNED_DR to a dr_vec_info
After previous changes, it makes more sense for STMT_VINFO_UNALIGNED_DR to be dr_vec_info rather than a data_reference. 2018-07-31 Richard Sandiford <richard.sandiford@arm.com> gcc/ * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to dr_vec_info. * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update accordingly. * tree-vect-loop.c (vect_analyze_loop_2): Likewise. * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise. (vect_gen_prolog_loop_niters): Likewise. From-SVN: r263154
This commit is contained in:
parent
89fa689a9e
commit
1e5e6ff5e6
|
|
@ -1,3 +1,13 @@
|
||||||
|
2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
|
||||||
|
|
||||||
|
* tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
|
||||||
|
dr_vec_info.
|
||||||
|
* tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
|
||||||
|
accordingly.
|
||||||
|
* tree-vect-loop.c (vect_analyze_loop_2): Likewise.
|
||||||
|
* tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
|
||||||
|
(vect_gen_prolog_loop_niters): Likewise.
|
||||||
|
|
||||||
2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
|
2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
|
||||||
|
|
||||||
* tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
|
* tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
|
||||||
|
|
|
||||||
|
|
@ -2135,7 +2135,7 @@ vect_enhance_data_refs_alignment (loop_vec_info loop_vinfo)
|
||||||
vect_update_misalignment_for_peel (dr_info, dr0_info, npeel);
|
vect_update_misalignment_for_peel (dr_info, dr0_info, npeel);
|
||||||
}
|
}
|
||||||
|
|
||||||
LOOP_VINFO_UNALIGNED_DR (loop_vinfo) = dr0_info->dr;
|
LOOP_VINFO_UNALIGNED_DR (loop_vinfo) = dr0_info;
|
||||||
if (npeel)
|
if (npeel)
|
||||||
LOOP_VINFO_PEELING_FOR_ALIGNMENT (loop_vinfo) = npeel;
|
LOOP_VINFO_PEELING_FOR_ALIGNMENT (loop_vinfo) = npeel;
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -1560,7 +1560,7 @@ vect_update_ivs_after_vectorizer (loop_vec_info loop_vinfo,
|
||||||
static tree
|
static tree
|
||||||
get_misalign_in_elems (gimple **seq, loop_vec_info loop_vinfo)
|
get_misalign_in_elems (gimple **seq, loop_vec_info loop_vinfo)
|
||||||
{
|
{
|
||||||
dr_vec_info *dr_info = DR_VECT_AUX (LOOP_VINFO_UNALIGNED_DR (loop_vinfo));
|
dr_vec_info *dr_info = LOOP_VINFO_UNALIGNED_DR (loop_vinfo);
|
||||||
stmt_vec_info stmt_info = dr_info->stmt;
|
stmt_vec_info stmt_info = dr_info->stmt;
|
||||||
tree vectype = STMT_VINFO_VECTYPE (stmt_info);
|
tree vectype = STMT_VINFO_VECTYPE (stmt_info);
|
||||||
|
|
||||||
|
|
@ -1627,7 +1627,7 @@ static tree
|
||||||
vect_gen_prolog_loop_niters (loop_vec_info loop_vinfo,
|
vect_gen_prolog_loop_niters (loop_vec_info loop_vinfo,
|
||||||
basic_block bb, int *bound)
|
basic_block bb, int *bound)
|
||||||
{
|
{
|
||||||
dr_vec_info *dr_info = DR_VECT_AUX (LOOP_VINFO_UNALIGNED_DR (loop_vinfo));
|
dr_vec_info *dr_info = LOOP_VINFO_UNALIGNED_DR (loop_vinfo);
|
||||||
tree var;
|
tree var;
|
||||||
tree niters_type = TREE_TYPE (LOOP_VINFO_NITERS (loop_vinfo));
|
tree niters_type = TREE_TYPE (LOOP_VINFO_NITERS (loop_vinfo));
|
||||||
gimple_seq stmts = NULL, new_stmts = NULL;
|
gimple_seq stmts = NULL, new_stmts = NULL;
|
||||||
|
|
|
||||||
|
|
@ -2142,8 +2142,7 @@ start_over:
|
||||||
/* Niters for peeled prolog loop. */
|
/* Niters for peeled prolog loop. */
|
||||||
if (LOOP_VINFO_PEELING_FOR_ALIGNMENT (loop_vinfo) < 0)
|
if (LOOP_VINFO_PEELING_FOR_ALIGNMENT (loop_vinfo) < 0)
|
||||||
{
|
{
|
||||||
dr_vec_info *dr_info
|
dr_vec_info *dr_info = LOOP_VINFO_UNALIGNED_DR (loop_vinfo);
|
||||||
= DR_VECT_AUX (LOOP_VINFO_UNALIGNED_DR (loop_vinfo));
|
|
||||||
tree vectype = STMT_VINFO_VECTYPE (dr_info->stmt);
|
tree vectype = STMT_VINFO_VECTYPE (dr_info->stmt);
|
||||||
niters_th += TYPE_VECTOR_SUBPARTS (vectype) - 1;
|
niters_th += TYPE_VECTOR_SUBPARTS (vectype) - 1;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -437,7 +437,7 @@ typedef struct _loop_vec_info : public vec_info {
|
||||||
tree mask_compare_type;
|
tree mask_compare_type;
|
||||||
|
|
||||||
/* Unknown DRs according to which loop was peeled. */
|
/* Unknown DRs according to which loop was peeled. */
|
||||||
struct data_reference *unaligned_dr;
|
struct dr_vec_info *unaligned_dr;
|
||||||
|
|
||||||
/* peeling_for_alignment indicates whether peeling for alignment will take
|
/* peeling_for_alignment indicates whether peeling for alignment will take
|
||||||
place, and what the peeling factor should be:
|
place, and what the peeling factor should be:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue