From 6373f8c31720e7d9712acc5914ed9176df5dabde Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Sun, 13 Nov 2022 11:52:14 -0800 Subject: [PATCH] [RISCV] Add BREV8 to hasAllWUsers in RISCVSExtWRemoval. This instruction reverses the bits in each byte. Since we're only interested in whether the upper 32 bits are used or not, we can look through them to check their users. --- llvm/lib/Target/RISCV/RISCVSExtWRemoval.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/llvm/lib/Target/RISCV/RISCVSExtWRemoval.cpp b/llvm/lib/Target/RISCV/RISCVSExtWRemoval.cpp index 169d186..62154c7 100644 --- a/llvm/lib/Target/RISCV/RISCVSExtWRemoval.cpp +++ b/llvm/lib/Target/RISCV/RISCVSExtWRemoval.cpp @@ -198,6 +198,7 @@ static bool hasAllWUsers(const MachineInstr &OrigMI, MachineRegisterInfo &MRI) { case RISCV::XORI: case RISCV::ANDN: + case RISCV::BREV8: case RISCV::CLMUL: case RISCV::ORC_B: case RISCV::ORN: -- 2.7.4