[llvm] [GISel][AArch64] Allow PatLeafs to be imported in GISel which were previously causing warnings (PR #140935)
via llvm-commits
llvm-commits at lists.llvm.org
Thu May 22 04:32:05 PDT 2025
================
@@ -7985,6 +7996,29 @@ bool AArch64InstructionSelector::isLoadStoreOfNumBytes(
return (*MI.memoperands_begin())->getSize() == NumBytes;
}
+bool AArch64InstructionSelector::isTop16Zero(const MachineOperand &MO) const {
+ Register Reg = MO.getReg();
+ return VT->maskedValueIsZero(Reg, APInt::getHighBitsSet(32, 16));
----------------
jyli0116 wrote:
>From what I understand from the code, VT is always be available - I could add in a check just to be safe, although I don't think it's super necessary
https://github.com/llvm/llvm-project/pull/140935
More information about the llvm-commits
mailing list