[PATCH] D140478: [RISCV] For Dwarf v5, emit indices into .debug_addr for range list entries
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 24 10:59:23 PST 2023
craig.topper added inline comments.
================
Comment at: llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp:1299
+ return MF->hasRelaxationsEnabled();
+ return TM.getMCSubtargetInfo()->checkFeatures("+relax");
+}
----------------
This also feels like it should be a virtual function.
================
Comment at: llvm/lib/CodeGen/MachineFunction.cpp:635
+bool MachineFunction::hasRelaxationsEnabled() const {
+ if (getSubtarget().checkFeatures("-relax"))
+ return false;
----------------
This feels like there should be a virtual function somewhere that a target can override and answer using its own knowledge. Rather than using feature strings that don't exist on most targets.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D140478/new/
https://reviews.llvm.org/D140478
More information about the llvm-commits
mailing list