History log of /external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
dce4a407a24b04eebc6a376f8e62b41aaa7b071f 29-May-2014 Stephen Hines <srhines@google.com> Update LLVM for 3.5 rebase (r209712).

Change-Id: I149556c940fb7dc92d075273c87ff584f400941f
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
36b56886974eae4f9c5ebc96befd3e7bfe5de338 24-Apr-2014 Stephen Hines <srhines@google.com> Update to LLVM 3.5a.

Change-Id: Ifadecab779f128e62e430c2b4f6ddd84953ed617
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
244d24597497c09ab68969c8bbbdf2576130262c 21-Oct-2013 Matt Arsenault <Matthew.Arsenault@amd.com> Use more type helper functions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193109 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
611082966190251fed33f3d0cf1b4c0d20ad777b 01-Oct-2013 Matt Arsenault <Matthew.Arsenault@amd.com> Fix code duplication

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191716 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
f80a63fa23862e578de919f4b44d4fcdee68fd0d 28-Sep-2013 Robert Wilhelm <robert.wilhelm@gmx.net> Fix spelling intruction -> instruction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191610 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
eaa8f5533f9f678fe3c56aec0201a34e46eaaf54 14-Aug-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Add initial stores to the write set when tracking uses

When computing the use set of a store, we need to add the store to the write
set prior to iterating over later instructions. Otherwise, if there is a later
aliasing load of that store, that load will not be tagged as a use, and bad
things will happen.

trackUsesOfI still adds later dependent stores of an instruction to that
instruction's write set, but it never sees the original instruction, and so
when tracking uses of a store, the store must be added to the write set by the
caller.

Fixes PR16834.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188329 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
a0ec3f9b7b826b9b40b80199923b664bad808cce 14-Jul-2013 Craig Topper <craig.topper@gmail.com> Use SmallVectorImpl& instead of SmallVector to avoid repeating small vector size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186274 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
6227d5c690504c7ada5780c00a635b282c46e275 04-Jul-2013 Craig Topper <craig.topper@gmail.com> Use SmallVectorImpl::iterator/const_iterator instead of SmallVector to avoid specifying the vector size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185606 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
76a05c93b13a8debec4497a6e4e753d7531709e5 10-Mar-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Fixup debugging statements

After the recent data-structure improvements, a couple of debugging statements
were broken (printing pointer values).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176791 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
f79f136cc64b0625b77c7b9008ed8c5b848b6b17 17-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Fix an invalid reference bug

This fixes PR15289. This bug was introduced (recently) in r175215; collecting
all std::vector references for candidate pairs to delete at once is invalid
because subsequent lookups in the owning DenseMap could invalidate the
references.

bugpoint was able to reduce a useful test case. Unfortunately, because whether
or not this asserts depends on memory layout, this test case will sometimes
appear to produce valid output. Nevertheless, running under valgrind will
reveal the error.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175397 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
f64a7a83bea5f1d2ab1e71231616c6cb0487d56e 15-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Call a DAG and DAG instead of a tree

Several functions and variable names used the term 'tree' to refer
to what is actually a DAG. Correcting this mistake will, hopefully,
prevent confusion in the future.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175278 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
ab90084bca42b74a5b5edad9b416bd81e105dad0 15-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Cap the number of candidate pairs in each instruction group

For some basic blocks, it is possible to generate many candidate pairs for
relatively few pairable instructions. When many (tens of thousands) of these pairs
are generated for a single instruction group, the time taken to generate and
rank the different vectorization plans can become quite large. As a result, we now
cap the number of candidate pairs within each instruction group. This is done by
closing out the group once the threshold is reached (set now at 3000 pairs).

Although this will limit the overall compile-time impact, this may not be the best
way to achieve this result. It might be better, for example, to prune excessive
candidate pairs after the fact the prevent the generation of short, but highly-connected
groups. We can experiment with this in the future.

This change reduces the overall compile-time slowdown of the csa.ll test case in
PR15222 to ~5x. If 5x is still considered too large, a lower limit can be
used as the default.

This represents a functionality change, but only for very large inputs
(thus, there is no regression test).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175251 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
97a241b173a1413df5a93fdd891ddfac36dabad9 14-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Remove the remaining instances of std::multimap

All instances of std::multimap have now been replaced by
DenseMap<K, std::vector<V> >, and this yields a speedup of 5% on the
csa.ll test case from PR15222.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175216 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
6ca6d3b1eac5b8611f3a9e2c270c2e794d37e1f5 14-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Don't store candidate pairs in a std::multimap

This is another commit on the road to removing std::multimap from
BBVectorize. This gives an ~1% speedup on the csa.ll test case
in PR15222.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@175215 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
c951003faf4d475d221f5e839971673d2350b983 12-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Don't over-search when building the dependency map

When building the pairable-instruction dependency map, don't search
past the last pairable instruction. For large blocks that have been
divided into multiple instruction groups, searching past the last
instruction in each group is very wasteful. This gives a 32% speedup
on the csa.ll test case from PR15222 (when using 50 instructions
in each group).

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174915 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
8f3359a4b396d3f1a7b2726e02f199be74c62e4c 12-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Omit unnecessary entries in PairableInstUsers

This map is queried only for instructions in pairs of pairable
instructions; so make sure that only pairs of pairable
instructions are added to the map. This gives a 3.5% speedup
on the csa.ll test case from PR15222.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174914 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
b1a82589339fed148c12b052d30861a539552f1a 11-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Eliminate one more restricted linear search

This eliminates one more linear search over a range of
std::multimap entries. This gives a 22% speedup on the
csa.ll test case from PR15222.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174893 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
00f63b1b84d059a1ffa572e76708e03750a9e523 11-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Remove the linear searches from pair connection searching

This removes the last of the linear searches over ranges of std::multimap
iterators, giving a 7% speedup on the doduc.bc input from PR15222.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174859 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
2f0e63cc16feb39480805bd00f53bbe5e3031d29 11-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Avoid linear searches within the load-move set

This is another cleanup aimed at eliminating linear searches
in ranges of std::multimap.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174858 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
3fc1e4aa159ec15058bb26acbec39f6e09990207 11-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: isa/cast cleanup in getInstructionTypes

Profiling suggests that getInstructionTypes is performance-sensitive,
this cleans up some double-casting in that function in favor of
using dyn_cast.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174857 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
da20ea696d8b24d89ae157106ddad2337296ed50 11-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Make the bookkeeping to support full cycle checking less expensive

By itself, this does not have much of an effect, but only because in the default
configuration the full cycle checks are used only for small problem sizes.
This is part of a general cleanup of uses of iteration over std::multimap
ranges only for the purpose of checking membership.

No functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174856 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
0cf5d396c14c71dd4fa1d102c2b3d178b1191436 08-Feb-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Use TTI->getAddressComputationCost

This is a follow-up to the cost-model change in r174713 which splits
the cost of a memory operation between the address computation and the
actual memory access. In r174713, this cost is always added to the
memory operation cost, and so BBVectorize will do the same.

Currently, this new cost function is used only by ARM, and I don't
have any ARM test cases for BBVectorize. Assistance in generating some
good ARM test cases for BBVectorize would be greatly appreciated!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174743 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
245b657ab636a505066ea6a81591a9a8b93604d2 27-Jan-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Better use of TTI->getShuffleCost

When flipping the pair of subvectors that form a vector, if the
vector length is 2, we can use the SK_Reverse shuffle kind to get
more-accurate cost information. Also we can use the SK_ExtractSubvector
shuffle kind to get accurate subvector extraction costs.

The current cost model implementations don't yet seem complex enough
for this to make a difference (thus, there are no test cases with this
commit), but it should help in future.

Depending on how the various targets optimize and combine shuffles in
practice, we might be able to get more-accurate costs by combining the
costs of multiple shuffle kinds. For example, the cost of flipping the
subvector pairs could be modeled as two extractions and two subvector
insertions. These changes, however, should probably be motivated
by specific test cases.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173621 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
ec5c3c2bd37828e9fbd913f5ac7b7f75711ddd59 26-Jan-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Add a additional comment about the cost computation

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173580 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
7a8aba906416b6998347b52c3c08610fdc190638 26-Jan-2013 Hal Finkel <hfinkel@anl.gov> BBVectorize: Fix anomalous capital letter in comment

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173579 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
8bd6c52396ab6e7955fdcc1bce099b7cba29a308 07-Jan-2013 Chandler Carruth <chandlerc@gmail.com> Switch BBVectorize to directly depend on having a TTI analysis.

This could be simplified further, but Hal has a specific feature for
ignoring TTI, and so I preserved that.

Also, I needed to use it because a number of tests fail when switching
from a null TTI to the NoTTI nonce implementation. That seems suspicious
to me and so may be something that you need to look into Hal. I worked
it by preserving the old behavior for these tests with the flag that
ignores all target info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
be04929f7fd76a921540e9901f24563e51dc1219 07-Jan-2013 Chandler Carruth <chandlerc@gmail.com> Move TargetTransformInfo to live under the Analysis library. This no
longer would violate any dependency layering and it is in fact an
analysis. =]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171686 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
abc227d9b39baed266c453f459ca14242f5c1eea 05-Jan-2013 Chandler Carruth <chandlerc@gmail.com> Switch the BB vectorizer from the VTTI interface to the simple TTI
interface.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171618 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
0b8c9a80f20772c3793201ab5b251d3520b9cea3 02-Jan-2013 Chandler Carruth <chandlerc@gmail.com> Move all of the header files which are involved in modelling the LLVM IR
into their new header subdirectory: include/llvm/IR. This matches the
directory structure of lib, and begins to correct a long standing point
of file layout clutter in LLVM.

There are still more header files to move here, but I wanted to handle
them in separate commits to make tracking what files make sense at each
layer easier.

The only really questionable files here are the target intrinsic
tablegen files. But that's a battle I'd rather not fight today.

I've updated both CMake and Makefile build systems (I think, and my
tests think, but I may have missed something).

I've also re-sorted the includes throughout the project. I'll be
committing updates to Clang, DragonEgg, and Polly momentarily.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
a77728415857196035c0090f7b2749d7971811a2 26-Dec-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Use VTTI to compute costs for intrinsics vectorization

For the time being this includes only some dummy test cases. Once the
generic implementation of the intrinsics cost function does something other
than assuming scalarization in all cases, or some target specializes the
interface, some real test cases can be added.

Also, for consistency, I changed the type of IID from unsigned to Intrinsic::ID
in a few other places.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171079 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
64a7a24edf719bb6ffacc030c23f4cd99312f3fb 25-Dec-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Enable vectorization of the fmuladd intrinsic

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171075 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
c2a537bd08d9deedefe184c9fb887c6d30ae9fd2 21-Dec-2012 Nadav Rotem <nrotem@apple.com> BB-Vectorizer: Check the cost of the store pointer type
and not the return type, which is void. A number of test
cases fail after adding the assertion in TTImpl.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@170828 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
d04a8d4b33ff316ca4cf961e06c9e312eff8e64f 03-Dec-2012 Chandler Carruth <chandlerc@gmail.com> Use the new script to sort the includes of every file under lib.

Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module
include to be the nearest plausible thing I could find. If you own or
care about any of these source files, I encourage you to take some time
and check that these edits were sensible. I can't have broken anything
(I strictly added headers, and reordered them, never removed), but they
may not be the headers you'd really like to identify as containing the
API being implemented.

Many forward declarations and missing includes were added to a header
files to allow them to parse cleanly when included first. The main
module rule does in fact have its merits. =]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169131 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
430b9079c614cd3f45015a6516590d33742cc802 28-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Correctly merge SubclassOptionalData

When two instructions are combined into a vector instruction,
the resulting instruction must have the most-conservative flags.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168765 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
97d19ebe5b5bf27617e536a16fa232116cefe914 14-Nov-2012 Hal Finkel <hfinkel@anl.gov> Replace std::vector -> SmallVector in BBVectorize

For now, this uses 8 on-stack elements. I'll need to do some profiling
to see if this is the best number.

Pointed out by Jakob in post-commit review.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167966 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
d7a3425f06d51ed579bd9aefeb835b7fa4ce7849 14-Nov-2012 Hal Finkel <hfinkel@anl.gov> Fix the largest offender of determinism in BBVectorize

Iterating over the children of each node in the potential vectorization
plan must happen in a deterministic order (because it affects which children
are erased when two children conflict). There was no need for this data
structure to be a map in the first place, so replacing it with a vector
is a small change.

I believe that this was the last remaining instance if iterating over the
elements of a Dense* container where the iteration order could matter.
There are some remaining iterations over std::*map containers where the order
might matter, but so long as the Value* for instructions in a block increase
with the order of the instructions in the block (or decrease) monotonically,
then this will appear to be deterministic.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167942 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
1a0be4d2a7e90b5207e0df98e2318d90e680c61f 13-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Remove temporary assert used for debugging

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167817 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
4387b8c95971a512e07bfda30dea6459e8419e8f 13-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Don't vectorize vector-manipulation chains

Don't choose a vectorization plan containing only shuffles and
vector inserts/extracts. Due to inperfections in the cost model,
these can lead to infinite recusion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167811 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
b2b2469a9178f7e22cd7a69f3093e54d67d6b712 13-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Only some insert element operand pairs are free.

This fixes another infinite recursion case when using target costs.
We can only replace insert element input chains that are pure (end
with inserting into an undef).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167784 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
86c88c938aec8006d2ce83325ec1f31e1154620b 12-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Use a more sophisticated check for input cost

The old checking code, which assumed that input shuffles and insert-elements
could always be folded (and thus were free) is too simple.
This can only happen in special circumstances.
Using the simple check caused infinite recursion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
5094257518ea7b615d87ef5bea657625ffa81991 12-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Check the types of compare instructions

The pass would previously assert when trying to compute the cost of
compare instructions with illegal vector types (like struct pointers).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167743 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
8b9796f4f83bea2bbefcd2822eb574abdb7f3d1b 12-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Check the input types of shuffles for legality

This fixes a bug where shuffles were being fused such that the
resulting input types were not legal on the target. This would
occur only when both inputs and dependencies were also foldable
operations (such as other shuffles) and there were other connected
pairs in the same block.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167731 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
78fd353d5e5daedc47ecc31b6193ca48793c249c 01-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Use target costs for incoming and outgoing values instead of the depth heuristic.

When target cost information is available, compute explicit costs of inserting and
extracting values from vectors. At this point, all costs are estimated using the
target information, and the chain-depth heuristic is not needed. As a result, it is now, by
default, disabled when using target costs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167256 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
86ccc55c82651f91fd6a312c5f6a4b511bcd1aec 01-Nov-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Account for internal shuffle costs

When target costs are available, use them to account for the costs of
shuffles on internal edges of the DAG of candidate pairs.

Because the shuffle costs here are currently for only the internal edges,
the current target cost model is trivial, and the chain depth requirement
is still in place, I don't yet have an easy test
case. Nevertheless, by looking at the debug output, it does seem to do the right
think to the effective "size" of each DAG of candidate pairs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167217 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
72465ea23d010507d3746adc126d719005981e05 31-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Choose pair ordering to minimize shuffles

BBVectorize would, except for loads and stores, always fuse instructions
so that the first instruction (in the current source order) would always
represent the low part of the input vectors and the second instruction
would always represent the high part. This lead to too many shuffles
being produced because sometimes the opposite order produces fewer of them.

With this change, BBVectorize tracks the kind of pair connections that form
the DAG of candidate pairs, and uses that information to reorder the pairs to
avoid excess shuffles. Using this information, a future commit will be able
to add VTTI-based shuffle costs to the pair selection procedure. Importantly,
the number of remaining shuffles can now be estimated during pair selection.

There are some trivial instruction reorderings in the test cases, and one
simple additional test where we certainly want to do a reordering to
avoid an unnecessary shuffle.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167122 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
a9779bfbc9ab0cf3f157453fd0afd110b04a9fdc 30-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Cache fixed-order pairs instead of recomputing pointer info.

Instead of recomputing relative pointer information just prior to fusing,
cache this information (which also needs to be computed during the
candidate-pair selection process). This cuts down on the total number of
SE queries made, and also is a necessary intermediate step on the road toward
including shuffle costs in the pair selection procedure.

No functionality change is intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167049 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
8a69a95f913dadae92d2ce0b3ac551610bf868e0 30-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Fix a small bug introduced in r167042.

We need to make sure that we take the correct load/store alignment
when the inputs are flipped.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167044 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
202d1cb8a587a9513d8bb65bf4a3d88a55132860 30-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Simplify how input swapping is handled.

Stop propagating the FlipMemInputs variable into the routines that
create the replacement instructions. Instead, just flip the arguments
of those routines. This allows for some associated cleanup (not all
of which is done here). No functionality change is intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167042 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
93f6f457614299eee3d22f376ab8f42a130f1912 30-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize: Don't make calls to SE when the result is unused.

SE was being called during the instruction-fusion process (when the result
is unreliable, and thus ignored). No functionality change is intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167037 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
46fb81cf4009cc34af97c5a1c0e824e2633fb4e4 27-Oct-2012 Hal Finkel <hfinkel@anl.gov> Update BBVectorize to use the new VTTI instr. cost interfaces.

The monolithic interface for instruction costs has been split into
several functions. This is the corresponding change. No functionality
change is intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166865 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
dc330f75b732b4ce1beace69ae7ed8e19d89bd9f 26-Oct-2012 Hal Finkel <hfinkel@anl.gov> Use VTTI->getNumberOfParts in BBVectorize.

This change reflects VTTI refactoring; no functionality change intended.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166752 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
822ab00847da841a63be4e3883cb5f442dc69069 26-Oct-2012 Hal Finkel <hfinkel@anl.gov> Disable generation of pointer vectors by BBVectorize.

Once vector-of-pointer support works, then this can be reverted.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166741 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
82149a9106f221aa6a7271977c236b078e621f21 26-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize, when using VTTI, should not form types that will be split.

This is needed so that perl's SHA can be compiled (otherwise
BBVectorize takes far too long to find its fixed point).

I'll try to come up with a reduced test case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166738 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
65309660fa61a837cc05323f69c618a7d8134d56 25-Oct-2012 Hal Finkel <hfinkel@anl.gov> Begin incorporating target information into BBVectorize.

This is the first of several steps to incorporate information from the new
TargetTransformInfo infrastructure into BBVectorize. Two things are done here:

1. Target information is used to determine if it is profitable to fuse two
instructions. This means that the cost of the vector operation must not
be more expensive than the cost of the two original operations. Pairs that
are not profitable are no longer considered (because current cost information
is incomplete, for intrinsics for example, equal-cost pairs are still
considered).

2. The 'cost savings' computed for the profitability check are also used to
rank the DAGs that represent the potential vectorization plans. Specifically,
for nodes of non-trivial depth, the cost savings is used as the node
weight.

The next step will be to incorporate the shuffle costs into the DAG weighting;
this will give the edges of the DAG weights as well. Once that is done, when
target information is available, we should be able to dispense with the
depth heuristic.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166716 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
e29c19091cca58db668407dfc5dd86c70e8b3d49 22-Oct-2012 Hal Finkel <hfinkel@anl.gov> BBVectorize should ignore unreachable blocks.

Unreachable blocks can have invalid instructions. For example,
jump threading can produce self-referential instructions in
unreachable blocks. Also, we should not be spending time
optimizing unreachable code. Fixes PR14133.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166423 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
3574eca1b02600bac4e625297f4ecf745f4c4f32 08-Oct-2012 Micah Villmow <villmow@gmail.com> Move TargetData to DataLayout.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
94c22716d60ff5edf6a98a3c67e0faa001be1142 27-Sep-2012 Sylvestre Ledru <sylvestre@debian.org> Revert 'Fix a typo 'iff' => 'if''. iff is an abreviation of if and only if. See: http://en.wikipedia.org/wiki/If_and_only_if Commit 164767

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@164768 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
7e2c793a2b5c746344652b6579e958ee42fafdcc 27-Sep-2012 Sylvestre Ledru <sylvestre@debian.org> Fix a typo 'iff' => 'if'

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@164767 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
8e0d1c03ca7fd86e6879b4e37d0d7f0e982feef6 29-Aug-2012 Benjamin Kramer <benny.kra@googlemail.com> Make MemoryBuiltins aware of TargetLibraryInfo.

This disables malloc-specific optimization when -fno-builtin (or -ffreestanding)
is specified. This has been a problem for a long time but became more severe
with the recent memory builtin improvements.

Since the memory builtin functions are used everywhere, this required passing
TLI in many places. This means that functions that now have an optional TLI
argument, like RecursivelyDeleteTriviallyDeadFunctions, won't remove dead
mallocs anymore if the TLI argument is missing. I've updated most passes to do
the right thing.

Fixes PR13694 and probably others.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162841 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
282969ed3641ffa426e0440d3824dd219152b2d8 28-Jun-2012 Hal Finkel <hfinkel@anl.gov> Precompute SCEV pointer analysis prior to instruction fusion in BBVectorize.

When both a load/store and its address computation are being vectorized, it can
happen that the address-computation vectorization destroys SCEV's ability
to analyize the relative pointer offsets. As a result (like with the aliasing
analysis info), we need to precompute the necessary information prior to
instruction fusing.

This was found during stress testing (running through the test suite with a very
low required chain length); unfortunately, I don't have a small test case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159332 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
a9ad9f64d56890852ff92639935eaf72b1157a98 28-Jun-2012 Hal Finkel <hfinkel@anl.gov> Remove a useless check in BBVectorize.

A shuffle mask will always be a constant, but I did not realize that
when I originally wrote the code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159331 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
64e1b28643d87e70734deb5f3d2d298e859c2fd2 28-Jun-2012 Hal Finkel <hfinkel@anl.gov> Allow BBVectorize to form non-2^n-length vectors.

The original algorithm only used recursive pair fusion of equal-length
types. This is now extended to allow pairing of any types that share
the same underlying scalar type. Because we would still generally
prefer the 2^n-length types, those are formed first. Then a second
set of iterations form the non-2^n-length types.

Also, a call to SimplifyInstructionsInBlock has been added after each
pairing iteration. This takes care of DCE (and a few other things)
that make the following iterations execute somewhat faster. For the
same reason, some of the simple shuffle-combination cases are now
handled internally.

There is some additional refactoring work to be done, but I've had
many requests for this feature, so additional refactoring will come
soon in future commits (as will additional test cases).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159330 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
ec4e85e3364f50802f2007e4b1e23661d4610366 28-Jun-2012 Hal Finkel <hfinkel@anl.gov> Refactor operation equivalence checking in BBVectorize by extending Instruction::isSameOperationAs.

Maintaining this kind of checking in different places is dangerous, extending
Instruction::isSameOperationAs consolidates this logic into one place. Here
I've added an optional flags parameter and two flags that are important for
vectorization: CompareIgnoringAlignment and CompareUsingScalarTypes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159329 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
768edf3cd037aab10391abc279f71470df8e3156 24-Jun-2012 Hal Finkel <hfinkel@anl.gov> Allow controlling vectorization of boolean values separately from other integer types.

These are used as the result of comparisons, and often handled differently from larger integer types.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159111 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
e415f96b6a43ac8861148a11a4258bc38c247e8f 23-Jun-2012 Hal Finkel <hfinkel@anl.gov> Allow BBVectorize to fuse compare instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159088 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
ab4684e26fe21857d8c8bc6ba7a5234c35117c83 16-Jun-2012 Hal Finkel <hfinkel@anl.gov> Teach BBVectorize to combine, when possible, or discard metadata when fusing instructions.

The present implementation handles only TBAA and FP metadata, discarding everything else.
For debug metadata, the current behavior is maintained (the debug metadata associated with
one of the instructions will be kept, discarding that attached to the other).

This should address PR 13040.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158606 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
e32e5440d6aaff8a77517e9d286846ae9e380770 27-Apr-2012 Hal Finkel <hfinkel@anl.gov> Don't vectorize target-specific types (ppc_fp128, x86_fp80, etc.).

Target specific types should not be vectorized. As a practical matter,
these types are already register matched (at least in the x86 case),
and codegen does not always work correctly (at least in the ppc case,
and this is not worth fixing because ppc_fp128 is currently broken and
will probably go away soon).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155729 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
05bc5087a25bbcf59936d71ebfc878b545ef3e5c 16-Apr-2012 Hal Finkel <hfinkel@anl.gov> Fix style violation in BBVectorize (pointed out by Bill Wendling)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154810 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
831a6e86d50414aa715846707e1f9f54f98513cb 16-Apr-2012 Hal Finkel <hfinkel@anl.gov> Simplify checking for pointer types in BBVectorize (this change was suggested by Duncan).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154787 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
bba23ed672c4cedd61a302497f45bf6f53fec7b2 14-Apr-2012 Hal Finkel <hfinkel@anl.gov> Fix an error in BBVectorize important for vectorizing pointer types.

When vectorizing pointer types it is important to realize that potential
pairs cannot be connected via the address pointer argument of a load or store.
This is because even after vectorization, the address is still a scalar because
the address of the higher half of the pair is implicit from the address of the
lower half (it need not be, and should not be, explicitly computed).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154735 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
f3f5a1e6f77a842ccb24cc81766437da5197d712 14-Apr-2012 Hal Finkel <hfinkel@anl.gov> Enhance BBVectorize to more-properly handle pointer values and vectorize GEPs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154734 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
fc3665c87519850f629c9565535e3be447e10add 13-Apr-2012 Hal Finkel <hfinkel@anl.gov> Add support to BBVectorize for vectorizing selects.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154700 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
86312cc15f29ce2bbd9647b94862e068045280c3 07-Apr-2012 Hongbin Zheng <etherzhhb@gmail.com> Refactor: Use positive field names in VectorizeConfig.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154249 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
940371bc65570ec0add1ede4f4d9f0a41ba25e09 05-Apr-2012 Hongbin Zheng <etherzhhb@gmail.com> BBVectorize: Add the const modifier to the VectorizeConfig because we won't
modify it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154098 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
bef377b7d7ce31edb40c87f8786d1b7bb6cdd6b1 05-Apr-2012 Hongbin Zheng <etherzhhb@gmail.com> Introduce the VectorizeConfig class, with which we can control the behavior
of the BBVectorizePass without using command line option. As pointed out
by Hal, we can ask the TargetLoweringInfo for the architecture specific
VectorizeConfig to perform vectorizing with architecture specific
information.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154096 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
87825e7970a361ce5a8bab19bc880ff7f6242ca2 05-Apr-2012 Hongbin Zheng <etherzhhb@gmail.com> Add the function "vectorizeBasicBlock" which allow users vectorize a
BasicBlock in other passes, e.g. we can call vectorizeBasicBlock in the
loop unroll pass right after the loop is unrolled.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154089 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
6173ed95daf2f209fe3883faee45967e4800ae75 31-Mar-2012 Hal Finkel <hfinkel@anl.gov> Correctly vectorize powi.

The powi intrinsic requires special handling because it always takes a single
integer power regardless of the result type. As a result, we can vectorize
only if the powers are equal. Fixes PR12364.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153797 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
43ec0f4921e315dd9507be7467e633a837ad23db 05-Mar-2012 Sebastian Pop <spop@codeaurora.org> fix typos

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152035 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
3706ac7aa83ab0aed9e2da7d5fc2386ac1f035f5 05-Mar-2012 Sebastian Pop <spop@codeaurora.org> remove spaces on empty lines

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152034 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
38a7f22445b8782682d1f8f253454ea0390d4ac5 10-Feb-2012 Hal Finkel <hfinkel@anl.gov> Update BBVectorize to use aliasesUnknownInst.

This allows BBVectorize to check the "unknown instruction" list in the
alias sets. This is important to prevent instruction fusing from reordering
function calls. Resolves PR11920.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150250 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
1230ad6e8cb7977527ac64dcf5005464d7d6c20b 06-Feb-2012 Sebastian Pop <spop@codeaurora.org> fix indentation

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149857 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
0b2500c504156c45cd71817a9ef6749b6cde5703 05-Feb-2012 David Blaikie <dblaikie@gmail.com> Simplify contains tests using 'count'.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149813 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
5c05f2b99e6d377786b4384925e61577f385f49c 05-Feb-2012 NAKAMURA Takumi <geek4civic@gmail.com> BBVectorize.cpp: Get rid of comparision to bool to fix a warning.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149810 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
edc8db87dc2ed4d2971e7f50464f5f4d0fead537 04-Feb-2012 Hal Finkel <hfinkel@anl.gov> Boost the effective chain depth of loads and stores.

By default, boost the chain depth contribution of loads and stores. This will allow a load/store pair to vectorize even when it would not otherwise be long enough to satisfy the chain depth requirement.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149761 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
ded681d2725907c7de9db53d59cee0c51fad6fcb 02-Feb-2012 Benjamin Kramer <benny.kra@googlemail.com> BBVectorize: Simplify code, no functionality change.

Also silences warnings about bodyless for loops.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149612 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
35564dc3ae1c377abad425cb09928eaf676dcb3c 02-Feb-2012 Hal Finkel <hfinkel@anl.gov> Minor changes from review.

As suggested by Nick Lewycky, the tree traversal queues have been changed to SmallVectors and the associated loops have been rotated. Also, an 80-col violation was fixed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149607 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
5d4e18bc39fea892f523d960213906d296d3cb38 02-Feb-2012 Hal Finkel <hfinkel@anl.gov> Vectorize long blocks in groups.

Long basic blocks with many candidate pairs (such as in the SHA implementation in Perl 5.14; thanks to Roman Divacky for the example) used to take an unacceptably-long time to compile. Instead, break long blocks into groups so that no group has too many candidate pairs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149595 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
478eed85f96f0d93da43e26cfb7fc6dee981c9aa 01-Feb-2012 NAKAMURA Takumi <geek4civic@gmail.com> BBVectorize.cpp: Try to fix MSVC build. map::iterator and multimap::iterator are incompatible.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149475 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
7e004d177fe76145f75a9417ed2e281f1b9abaf7 01-Feb-2012 Hal Finkel <hfinkel@anl.gov> A few of the changes suggested in code review (by Nick Lewycky)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149472 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp
de5e5ec3045a73a06b1054417f9ac6c02929e9ce 01-Feb-2012 Hal Finkel <hfinkel@anl.gov> Add a basic-block autovectorization pass.

This is the initial checkin of the basic-block autovectorization pass along with some supporting vectorization infrastructure.
Special thanks to everyone who helped review this code over the last several months (especially Tobias Grosser).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149468 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/Transforms/Vectorize/BBVectorize.cpp