Revert "[Hexagon] Don't build two halves of HVX vector in parallel"
authorKrzysztof Parzyszek <kparzysz@quicinc.com>
Thu, 30 Dec 2021 15:57:11 +0000 (07:57 -0800)
committerKrzysztof Parzyszek <kparzysz@quicinc.com>
Thu, 30 Dec 2021 15:57:11 +0000 (07:57 -0800)
commit95c7dd8810b0bc93c0f76a285f1bcc3bd73f6a50
treecd8e402186310153192c265949feba9c962e0753
parent7128bb61fb59bd1d170865b5a5f0fe8fe0c00491
Revert "[Hexagon] Don't build two halves of HVX vector in parallel"

This reverts commit ba07f300c6d67a2c6dde8eef216b7a77ac4600bb.

A build-vector sequence is made of pairs: rotate+insert. When constructing
a single vector, this results in a chain of 2*N instructions. The rotate
operation is a permute operation, but the insert uses a multiplication
resource: insert and rotate can execute in the same cycle, but obviously
they cannot operate on the same vector. The original halving idea is still
beneficial since it does allow for insert/rotate overlap, and for hiding
insert's latency.
llvm/lib/Target/Hexagon/HexagonISelLoweringHVX.cpp
llvm/test/CodeGen/Hexagon/autohvx/isel-build-vector.ll