diff options
author | Richard Biener <rguenther@suse.de> | 2020-07-03 10:09:39 +0200 |
---|---|---|
committer | Richard Biener <rguenther@suse.de> | 2020-07-03 11:29:16 +0200 |
commit | 9e5508c2d006f2d4f8670e6c3fed770ac1c85e64 (patch) | |
tree | 3fe50f35e5da1a34dd92b35c2ac38ef5461bc743 /gcc/tree-vectorizer.h | |
parent | 26b538cd81b9692eaf519fa1743ca8c282048793 (diff) | |
download | gcc-9e5508c2d006f2d4f8670e6c3fed770ac1c85e64.zip gcc-9e5508c2d006f2d4f8670e6c3fed770ac1c85e64.tar.gz gcc-9e5508c2d006f2d4f8670e6c3fed770ac1c85e64.tar.bz2 |
refactor SLP constant insertion and provde entry insert helper
This provides helpers to insert stmts on region entry abstracted
from loop/basic-block split out from vec_init_vector and used
from the SLP constant code generation path. The SLP constant
code generation path is also changed to avoid needless SSA
copying since we can store VECTOR_CSTs directly in the vectorized
defs array, improving the IL from the vectorizer.
2020-07-03 Richard Biener <rguenther@suse.de>
* tree-vectorizer.h (vec_info::insert_on_entry): New.
(vec_info::insert_seq_on_entry): Likewise.
* tree-vectorizer.c (vec_info::insert_on_entry): Implement.
(vec_info::insert_seq_on_entry): Likewise.
* tree-vect-stmts.c (vect_init_vector_1): Use
vec_info::insert_on_entry.
(vect_finish_stmt_generation): Set modified bit after
adjusting VUSE.
* tree-vect-slp.c (vect_create_constant_vectors): Simplify
by using vec_info::insert_seq_on_entry and bypassing
vec_init_vector.
(vect_schedule_slp_instance): Deal with all-constant
children later.
Diffstat (limited to 'gcc/tree-vectorizer.h')
-rw-r--r-- | gcc/tree-vectorizer.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/tree-vectorizer.h b/gcc/tree-vectorizer.h index dfe88cc..7c6de83 100644 --- a/gcc/tree-vectorizer.h +++ b/gcc/tree-vectorizer.h @@ -334,6 +334,8 @@ public: 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); /* The type of vectorization. */ vec_kind kind; |