[InstCombine] Add tests for cases where we don't recognize type promoted rotate idioms.
authorCraig Topper <craig.topper@intel.com>
Fri, 11 May 2018 00:46:09 +0000 (00:46 +0000)
committerCraig Topper <craig.topper@intel.com>
Fri, 11 May 2018 00:46:09 +0000 (00:46 +0000)
commit4b026e5ebdacf7fec3f57bc829728f175a61df97
tree94abd5354a5ca502894b6ab2514fa4680d4c5510
parent9702c963ab3ab77cad2e1f1c917b058ddd645099
[InstCombine] Add tests for cases where we don't recognize type promoted rotate idioms.

These rotates take the form

(x << (n & mask)) | (x >> (-n & mask)) where mask is bitwidth - 1.

If x has been promoted to a wider type than its original bit width due to type promotion we fail to narrower it and therefore don't recognize it as a rotate.

llvm-svn: 332068
llvm/test/Transforms/InstCombine/rotate.ll