commit | 48b20392ac828dd7696a0a4e4c2cb6727e08daa7 | [log] [tgz] |
---|---|---|
author | Sanjay Patel <spatel@rotateright.com> | Tue Nov 13 23:27:23 2018 +0000 |
committer | Sanjay Patel <spatel@rotateright.com> | Tue Nov 13 23:27:23 2018 +0000 |
tree | 43174bd6828f4561c8f1970b618538d47062364a | |
parent | 108bc88c84d9281e46cfff1fdf9890053f3c06a0 [diff] |
[InstCombine] fold funnel shift amount based on demanded bits The shift amount of a funnel shift is modulo the scalar bitwidth: http://llvm.org/docs/LangRef.html#llvm-fshl-intrinsic ...so we can use demanded bits analysis on that operand to simplify it when we have a power-of-2 bitwidth. This is another step towards canonicalizing {shift/shift/or} to the intrinsics in IR. Differential Revision: https://reviews.llvm.org/D54478 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@346814 91177308-0d34-0410-b5e6-96231b3b80d8