]> granicus.if.org Git - llvm/commit
[InstCombine] Shift amount reassociation in bittest: drop pointless one-use restriction
authorRoman Lebedev <lebedev.ri@gmail.com>
Sat, 10 Aug 2019 19:28:44 +0000 (19:28 +0000)
committerRoman Lebedev <lebedev.ri@gmail.com>
Sat, 10 Aug 2019 19:28:44 +0000 (19:28 +0000)
commit2a686e81e517d69f5eee88fc592fa988952f81d6
treed697172f83309f2d535ccb5907ab033599b90f51
parent6a7a2e85fc7afaa2e4bc7a7e213ddc7eb608e1af
[InstCombine] Shift amount reassociation in bittest: drop pointless one-use restriction

That one-use restriction is not needed for correctness - we have already
ensured that one of the shifts will go away, so we know we won't increase
the instruction count. So there is no need for that restriction.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@368518 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCompares.cpp
test/Transforms/InstCombine/shift-amount-reassociation-in-bittest.ll