]> granicus.if.org Git - llvm/commit
[InstCombine] Fold x u<= x & C to x u<= C
authorRoman Lebedev <lebedev.ri@gmail.com>
Sat, 14 Jul 2018 16:44:54 +0000 (16:44 +0000)
committerRoman Lebedev <lebedev.ri@gmail.com>
Sat, 14 Jul 2018 16:44:54 +0000 (16:44 +0000)
commitd8e175bca5919de13fe003cab6b10f23af3d055d
treea215c01b0091a487bf24c7c4fd66f0f71c238e0a
parent67041dddbe76f663877ab9a4dfe3e0e99a70f7d3
[InstCombine] Fold  x u<= x & C  to  x u<= C

https://bugs.llvm.org/show_bug.cgi?id=38123
https://rise4fun.com/Alive/Fqp

This pattern is not commutative. But InstSimplify will
already have taken care of the 'commutative' variant.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@337102 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCompares.cpp
test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ule-to-icmp-ule.ll