[SLP] Look-ahead operand reordering heuristic.
authorVasileios Porpodas <vasileios.porpodas@intel.com>
Mon, 11 Nov 2019 18:50:20 +0000 (18:50 +0000)
committerVasileios Porpodas <vasileios.porpodas@intel.com>
Tue, 12 Nov 2019 05:06:51 +0000 (21:06 -0800)
commit6a18a9548761b266b28a49f705a568677c24b59b
tree15d34b49e0fdaa29083698bb098d64d39b9d237b
parentac385ca63fe8bc283d7f5be213319cc3b930b4cc
[SLP] Look-ahead operand reordering heuristic.

Summary: This patch introduces a new heuristic for guiding operand reordering. The new "look-ahead" heuristic can look beyond the immediate predecessors. This helps break ties when the immediate predecessors have identical opcodes (see lit test for examples).

Reviewers: RKSimon, ABataev, dtemirbulatov, Ayal, hfinkel, rnk

Reviewed By: RKSimon, dtemirbulatov

Subscribers: xbolva00, Carrot, hiraditya, phosek, rnk, rcorcs, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D60897
llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
llvm/test/Transforms/SLPVectorizer/AArch64/transpose.ll
llvm/test/Transforms/SLPVectorizer/X86/lookahead.ll