[PATCH] D87883: [X86] Add support for calling SimplifyDemandedBits on the input of PDEP with a constant mask.

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 18 02:45:12 PDT 2020


RKSimon added inline comments.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:49499
+  if (auto *C = dyn_cast<ConstantSDNode>(Op1)) {
+    uint64_t Count = C->getAPIntValue().countPopulation();
+
----------------
Can you move this functionality inside X86TargetLowering::SimplifyDemandedBitsForTargetNode?

Hopefully we can then expand it in the future to handle incoming DemandedBits masks as well to adjust the PDEP mask.

X86TargetLowering::computeKnownBitsForTargetNode support would be useful eventually as well.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D87883



More information about the llvm-commits mailing list