Avoid recomputing data references in BB SLP
authorRichard Sandiford <richard.sandiford@arm.com>
Sun, 20 Oct 2019 12:58:22 +0000 (12:58 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Sun, 20 Oct 2019 12:58:22 +0000 (12:58 +0000)
commitfa0c8df71d4f0476834db0b7cd88524878b46cf7
tree1308c01dcb8bc9938758c3c6bab4f813000992fe
parentb4edf5c524fd0d8fef50f991ce876c6eb5ed3a28
Avoid recomputing data references in BB SLP

If the first attempt at applying BB SLP to a region fails, the main loop
in vect_slp_bb recomputes the region's bounds and datarefs for the next
vector size.  AFAICT this isn't needed any more; we should be able
to reuse the datarefs from the first attempt instead.

2019-10-20  Richard Sandiford  <richard.sandiford@arm.com>

gcc/
* tree-vect-slp.c (vect_slp_analyze_bb_1): Call save_datarefs
when processing the given datarefs for the first time and
check_datarefs subsequently.
(vect_slp_bb_region): New function, split out of...
(vect_slp_bb): ...here.  Don't recompute the region bounds and
dataref sets when retrying with a different vector size.

From-SVN: r277210
gcc/ChangeLog
gcc/tree-vect-slp.c