[llvm] [RISCV][GISel] Add ISel supports for SHXADD from Zba extension (PR #67863)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 2 11:33:13 PDT 2023
================
@@ -235,10 +235,7 @@ def SimmShiftRightBy3XForm : SDNodeXForm<imm, [{
}]>;
// Pattern to exclude simm12 immediates from matching.
-def non_imm12 : PatLeaf<(XLenVT GPR:$a), [{
- auto *C = dyn_cast<ConstantSDNode>(N);
- return !C || !isInt<12>(C->getSExtValue());
-}]>;
+def non_imm12 : ComplexPattern<XLenVT, 1, "selectNonImm12", [], [], 0>;
----------------
topperc wrote:
I used `PredicateCodeUsesOperands` so that I could know which operand wasn't the `shl` since add is commutable and tblgen will generate both patterns.
https://github.com/llvm/llvm-project/pull/67863
More information about the llvm-commits
mailing list