[llvm] 01cc1d1 - [RISCV] Use Priv tablegen class for sf.cease instruction.

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 25 18:46:16 PST 2025


Author: Craig Topper
Date: 2025-02-25T18:45:54-08:00
New Revision: 01cc1d13cd0c54bd4c29185b052fa5c16285dca7

URL: https://github.com/llvm/llvm-project/commit/01cc1d13cd0c54bd4c29185b052fa5c16285dca7
DIFF: https://github.com/llvm/llvm-project/commit/01cc1d13cd0c54bd4c29185b052fa5c16285dca7.diff

LOG: [RISCV] Use Priv tablegen class for sf.cease instruction.

The encoding for sf.cease is only one bit different than wfi which
I believe was an intentional choice. wfi uses the Priv class so
this makes them consistent.

Added: 
    

Modified: 
    llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td b/llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td
index 0654f1ac19a82..5649268b406a0 100644
--- a/llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td
+++ b/llvm/lib/Target/RISCV/RISCVInstrInfoXSf.td
@@ -859,9 +859,9 @@ let Predicates = [HasVendorXSiFivecflushdlone] in {
 let Predicates = [HasVendorXSfcease] in {
   let hasNoSchedulingInfo = 1, hasSideEffects = 1, mayLoad = 0, mayStore = 0,
       DecoderNamespace = "XSfcease" in
-  def SF_CEASE : RVInstIUnary<0b001100000101, 0b000, OPC_SYSTEM, (outs), (ins),
-                              "sf.cease", "">, Sched<[]> {
-    let rs1 = 0b00000;
+  def SF_CEASE : Priv<"sf.cease", 0b0011000>, Sched<[]> {
     let rd = 0b00000;
+    let rs1 = 0b00000;
+    let rs2 = 0b00101;
 }
 }


        


More information about the llvm-commits mailing list