[PATCH] D158976: [RISCV] Add isCommutable for pseudos without merge operand

Michael Maitland via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 28 07:33:02 PDT 2023


michaelmaitland added a comment.

I'm not very familiar with how `isCommutable` works, but this change looks like a good idea as long as `isCommutable` only refers to the `$rs2 and $rs1` operands, and does not say anything about commutability of `$carry, $vl, or $sew`.



================
Comment at: llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td:3059
               SchedBinary<"WriteVICALUV", "ReadVICALUV", "ReadVICALUV", mx, forceMasked=1,
                           forceMergeOpRead=true>;
     defm "" : VPseudoBinaryV_XM<m, CarryOut=1, CarryIn=1, Constraint=Constraint>,
----------------
The description says:

> there is no merge operand for their pseudos

but it looks like we are forcing a merge operand.  It looks like `VPseudoBinaryV_VM` defines `VPseudoBinaryCarryIn` which does not have a merge operand. Maybe we should not set forceMergeOpRead here?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D158976



More information about the llvm-commits mailing list