Two fixes to the vpermilvar optimization.
authorRafael Espindola <rafael.espindola@gmail.com>
Tue, 29 Apr 2014 20:41:54 +0000 (20:41 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Tue, 29 Apr 2014 20:41:54 +0000 (20:41 +0000)
commit984f2fc09e64f9a96ee36cfbf7acfd6c0fb0c7a9
tree5b79a02c8bf50d72ae37c2c782e89fbd7d328368
parent6149bc1e104d56274be18ac2270818cb6bd93091
Two fixes to the vpermilvar optimization.

The instcomine logic to handle vpermilvar's pd and 256 variants was incorrect.
The _256 variants have indexes into the individual 128 bit lanes and in all
cases it also has to mask out unused bits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207577 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCalls.cpp
test/Transforms/InstCombine/vec_demanded_elts.ll