[clang] [llvm] [dwarf] make dwarf fission compatible with RISCV relaxations (PR #164128)

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 20 09:54:46 PDT 2025


================
@@ -3290,34 +3275,70 @@ static MCSymbol *emitLoclistsTableHeader(AsmPrinter *Asm,
   return TableEnd;
 }
 
-template <typename Ranges, typename PayloadEmitter>
-static void emitRangeList(
-    DwarfDebug &DD, AsmPrinter *Asm, MCSymbol *Sym, const Ranges &R,
-    const DwarfCompileUnit &CU, unsigned BaseAddressx, unsigned OffsetPair,
-    unsigned StartxLength, unsigned EndOfList,
-    StringRef (*StringifyEnum)(unsigned),
-    bool ShouldUseBaseAddress,
-    PayloadEmitter EmitPayload) {
+namespace {
+
+struct DebugLocSpanList {
+  MCSymbol *Label;
+  const DwarfCompileUnit *CU;
+  llvm::ArrayRef<llvm::DebugLocStream::Entry> Ranges;
+};
----------------
dwblaikie wrote:

Not sure that this structure's pulling its weight here - does it make much of a difference to stick with the original API, passing a few more parameters directly?

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


More information about the llvm-commits mailing list