[llvm] [RISCV][TableGen] Return instruction size from isCompressibleInst (PR #225660)

Sudharsan Veeravalli via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 23 22:51:01 PDT 2026


================
@@ -633,7 +633,9 @@ void CompressInstEmitter::emitCompressInstEmitter(raw_ostream &OS,
     FuncH.indent(27) << "const MCSubtargetInfo &STI) {\n";
   } else if (EType == EmitterType::CheckCompress) {
     FuncH << "static bool isCompressibleInst(const MachineInstr &MI,\n";
-    FuncH.indent(31) << "const " << TargetName << "Subtarget &STI) {\n";
+    FuncH.indent(31) << "const " << TargetName << "Subtarget &STI,\n";
+    FuncH.indent(31) << "unsigned *Size = nullptr) {\n";
----------------
svs-quic wrote:

I've added comments in the header of  llvm/utils/TableGen/CompressInstEmitter.cpp where the generated instruction definitions are present.

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


More information about the llvm-commits mailing list