[llvm] [Docs] Describe Tablegen Selection Structures (PR #178518)
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 28 13:51:14 PST 2026
================
@@ -1106,7 +1201,18 @@ class PatLeaf<dag frag, code pred = [{}], SDNodeXForm xform = NOOP_SDNodeXForm>
class ImmLeaf<ValueType vt, code pred, SDNodeXForm xform = NOOP_SDNodeXForm,
SDNode ImmNode = imm>
: PatFrag<(ops), (vt ImmNode), [{}], xform> {
+
+ // Specific C++ Checks for Immediate Values. This code is shared between
+ // SDISel and GlobalISel.
+ //
+ // The following variables are in scope:
+ // - `Imm` representing the sign-extended value of the immediate. This might
+ // be an APInt, an APFloat, or a sign-extended int64_t, depending on the
+ // `IsAPInt` and `IsAPFloat` fields below.
----------------
topperc wrote:
Should we point to IntImmleaf and FPImmLeaf. Users shouldn't set `IsAPInt` and `IsAPFloat` themselves.
https://github.com/llvm/llvm-project/pull/178518
More information about the llvm-commits
mailing list