[SLP][NFC]Fix PR58476: Fix compile time for reductions, NFC.
authorAlexey Bataev <a.bataev@outlook.com>
Thu, 20 Oct 2022 19:54:32 +0000 (12:54 -0700)
committerAlexey Bataev <a.bataev@outlook.com>
Mon, 24 Oct 2022 17:13:24 +0000 (10:13 -0700)
commitda4e0f7ac58711ddeaf86943ae82c1928e26801f
treed61c46f11a711a3fdb9624e44dc9a6022212ab16
parentb9e63abe61203578518fe30dcbf862097f6b8aaa
[SLP][NFC]Fix PR58476: Fix compile time for reductions, NFC.

Improve O(N^2) to O(N) in some cases, reduce number of allocations by
reserving memory.
Also, improve analysis of loads reduction values to avoid analysis
of not vectorizable cases.
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp