[llvm] [RISCV] Copy base instruction TSFlags in RVV pseudo TSFlags. NFC (PR #149785)

Pengcheng Wang via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 21 04:10:51 PDT 2025


================
@@ -543,12 +543,17 @@ defset list<VTypeInfoToWide> AllWidenableBFloatToFloatVectors = {
 // This represents the information we need in codegen for each pseudo.
 // The definition should be consistent with `struct PseudoInfo` in
 // RISCVInstrInfo.h.
-class RISCVVPseudo {
+class RISCVVPseudo<dag outs, dag ins, list<dag> pattern, string opcodestr = "", string argstr = "">
+    : Pseudo<outs, ins, pattern, opcodestr, argstr> {
   Pseudo Pseudo = !cast<Pseudo>(NAME); // Used as a key.
   Instruction BaseInstr = !cast<Instruction>(PseudoToVInst<NAME>.VInst);
   // SEW = 0 is used to denote that the Pseudo is not SEW specific (or unknown).
   bits<8> SEW = 0;
   bit IncludeInInversePseudoTable = 1;
+
+  // Set common TSFlags in RVInst from the base instruction.
+  let ElementsDependOn = !cast<RVInst>(BaseInstr).ElementsDependOn;
----------------
wangpc-pp wrote:

What is this for?

https://github.com/llvm/llvm-project/pull/149785


More information about the llvm-commits mailing list