diff options
author | Richard Biener <rguenther@suse.de> | 2021-10-19 12:40:59 +0200 |
---|---|---|
committer | Richard Biener <rguenther@suse.de> | 2021-10-19 13:34:47 +0200 |
commit | 793d2549b173a0a2da6dd20ffc27acb9fd2de73e (patch) | |
tree | a3429be473786b7d96337556df61701ec542e039 /gcc/tree-vectorizer.h | |
parent | 9890b12c72c02828c691f22198c3e0afd8678991 (diff) | |
download | gcc-793d2549b173a0a2da6dd20ffc27acb9fd2de73e.zip gcc-793d2549b173a0a2da6dd20ffc27acb9fd2de73e.tar.gz gcc-793d2549b173a0a2da6dd20ffc27acb9fd2de73e.tar.bz2 |
Refactor load/store costing
This passes down the already available alignment scheme and
misalignment to the load/store costing routines, removing
redundant queries.
2021-10-19 Richard Biener <rguenther@suse.de>
* tree-vectorizer.h (vect_get_store_cost): Adjust signature.
(vect_get_load_cost): Likewise.
* tree-vect-data-refs.c (vect_get_data_access_cost): Get
alignment support scheme and misalignment as arguments
and pass them down.
(vect_get_peeling_costs_all_drs): Compute that info here
and note that we shouldn't need to.
* tree-vect-stmts.c (vect_model_store_cost): Get
alignment support scheme and misalignment as arguments.
(vect_get_store_cost): Likewise.
(vect_model_load_cost): Likewise.
(vect_get_load_cost): Likewise.
(vectorizable_store): Pass down alignment support scheme
and misalignment to costing.
(vectorizable_load): Likewise.
Diffstat (limited to 'gcc/tree-vectorizer.h')
-rw-r--r-- | gcc/tree-vectorizer.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/tree-vectorizer.h b/gcc/tree-vectorizer.h index 954a0e1..746e392 100644 --- a/gcc/tree-vectorizer.h +++ b/gcc/tree-vectorizer.h @@ -1957,11 +1957,13 @@ extern bool vect_nop_conversion_p (stmt_vec_info); extern opt_result vect_analyze_stmt (vec_info *, stmt_vec_info, bool *, slp_tree, slp_instance, stmt_vector_for_cost *); -extern void vect_get_load_cost (vec_info *, stmt_vec_info, int, bool, +extern void vect_get_load_cost (vec_info *, stmt_vec_info, int, + dr_alignment_support, int, bool, unsigned int *, unsigned int *, stmt_vector_for_cost *, stmt_vector_for_cost *, bool); extern void vect_get_store_cost (vec_info *, stmt_vec_info, int, + dr_alignment_support, int, unsigned int *, stmt_vector_for_cost *); extern bool vect_supportable_shift (vec_info *, enum tree_code, tree); extern tree vect_gen_perm_mask_any (tree, const vec_perm_indices &); |