summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCObjectFileInfo.cpp
diff options
context:
space:
mode:
authorAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2014-03-06 20:19:52 +0000
committerAndrea Di Biagio <Andrea_DiBiagio@sn.scee.net>2014-03-06 20:19:52 +0000
commit6292a140ee10c47bb1562d15e174b48a7c43f48b (patch)
treecd351cd9d74254a141bdd2622893e1c46adb8843 /llvm/lib/MC/MCObjectFileInfo.cpp
parent39a0965a3ce69339e6d519a51f731773cebabc36 (diff)
downloadbcm5719-llvm-6292a140ee10c47bb1562d15e174b48a7c43f48b.tar.gz
bcm5719-llvm-6292a140ee10c47bb1562d15e174b48a7c43f48b.zip
[X86] Teach the DAGCombiner how to fold a OR of two shufflevector nodes.
This patch teaches the DAGCombiner how to fold a binary OR between two shufflevector into a single shuffle vector when possible. The rules are: 1. fold (or (shuf A, V_0, MA), (shuf B, V_0, MB)) -> (shuf A, B, Mask1) 2. fold (or (shuf A, V_0, MA), (shuf B, V_0, MB)) -> (shuf B, A, Mask2) The DAGCombiner can take advantage of the fact that OR is commutative and compute two possible shuffle masks (Mask1 and Mask2) for the resulting shuffle node. Before folding a dag according to either rule 1 or 2, DAGCombiner verifies that the resulting shuffle mask is legal for the target. DAGCombiner would firstly try to fold according to 1.; If not possible then it will try to fold according to 2. If both Mask1 and Mask2 are illegal then we conservatively don't fold the OR instruction. llvm-svn: 203156
Diffstat (limited to 'llvm/lib/MC/MCObjectFileInfo.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud