[all-commits] [llvm/llvm-project] 7d06bd: [RISCV] Use isCompatible when we need runtime VSET...

Luke Lau via All-commits all-commits at lists.llvm.org
Sat Jun 15 06:23:45 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7d06bdcdfc0ef97fbc63d7a6b821070d160a64cd
      https://github.com/llvm/llvm-project/commit/7d06bdcdfc0ef97fbc63d7a6b821070d160a64cd
  Author: Luke Lau <luke at igalia.com>
  Date:   2024-06-15 (Sat, 15 Jun 2024)

  Changed paths:
    M llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp

  Log Message:
  -----------
  [RISCV] Use isCompatible when we need runtime VSETVLIInfo equality. NFC (#94340)

In VSETVLIInfo we define == as lattice equality, e.g. unknown == unknown
and invalid == invalid. We need this to check if the information at a
block's entry or exit has changed.

However I think we may have been conflating it with the notion that the
state of VL and VTYPE are the same, which isn't the case for two
unknowns, and potentially in an upcoming patch where we don't know the
value of an AVL register (see #93796)

This patch switches over the use in emitVSETVLIs to use isCompatible
with all fields demanded, since we need VL and VTYPE to be known equal
at runtime rather than just the VSETVLIInfos to be the same.

This should be NFC for now we shouldn't reach here with an unknown
state. But it's needed if we're to introduce the notion of an AVLReg
with a nullptr ValNo, which will need this non-reflexive equality.
Specifically, hasSameAVL should return false for this case, but ==
should return true.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list