[PATCH] D125717: [InstCombine] Optimize and of icmps with power-of-2 and contiguous masks

John McIver via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 23 20:50:29 PDT 2022


jmciver added a comment.

To reduce performance impact I am thinking that the call to `foldLogOpOfMaskedICmps_AllZeros_BMask_NotMixed_and_NotAllOnes` should be moved into a new function, `foldPowerOf2AndWithLesserContinuous`, and then call this function from `foldAndOrOfICmps`. This will help to keep the purpose of `foldLogOpOfMaskedICmps` clear and reduce the overhead by not testing for a less probable optimization early.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D125717/new/

https://reviews.llvm.org/D125717



More information about the llvm-commits mailing list