[llvm] [InstCombine] Remove over-generalization from computeKnownBitsFromCmp() (PR #72637)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 20 06:56:16 PST 2023


nikic wrote:

I've made two additional updates here:

 * Also drop non-constant RHS support for plain (non-mask) comparison. When using computeKnownBitsFromCmp() for dominating conditions, I found that supporting non-constant RHS here has significant compile-time impact but very little impact on results.
 * Explicitly handle the comparison with null pointer case. I'm not sure this is really important, but there were additional test changes when implementing the previous point, so I just did it to be safe.

https://github.com/llvm/llvm-project/pull/72637


More information about the llvm-commits mailing list