[clang] [llvm] [dwarf] make dwarf fission compatible with RISCV relaxations (PR #164128)
David Blaikie via cfe-commits
cfe-commits at lists.llvm.org
Mon Oct 20 09:54:46 PDT 2025
================
@@ -83,8 +83,24 @@ void MCSymbol::print(raw_ostream &OS, const MCAsmInfo *MAI) const {
OS << '"';
}
-#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
-LLVM_DUMP_METHOD void MCSymbol::dump() const {
- dbgs() << *this;
+bool llvm::isRangeRelaxable(const MCSymbol *Begin, const MCSymbol *End) {
+ assert(Begin && "Range without a begin symbol?");
+ assert(End && "Range without an end symbol?");
+ llvm::SmallVector<const MCFragment *> RangeFragments{};
----------------
dwblaikie wrote:
I'm not quite following - why is this vector needed? (rather than computing the `IsRelaxableRange` via a single iteration over the fragments in this loop below?
https://github.com/llvm/llvm-project/pull/164128
More information about the cfe-commits
mailing list