[llvm] [RISC-V][Mach-O] Add codegen support for Mach-O object format. (PR #178263)
Jessica Clarke via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 30 10:29:08 PST 2026
================
@@ -179,3 +181,11 @@ MCSection *RISCVELFTargetObjectFile::getSectionForConstant(
return TargetLoweringObjectFileELF::getSectionForConstant(DL, Kind, C,
Alignment);
}
+
+void RISCVMachOTargetObjectFile::getNameWithPrefix(
+ SmallVectorImpl<char> &OutName, const GlobalValue *GV,
+ const TargetMachine &TM) const {
+ // RISC-V does not use section-relative relocations so any global symbol must
+ // be accessed via at least a linker-private symbol.
+ getMangler().getNameWithPrefix(OutName, GV, /* CannotUsePrivateLabel */ true);
----------------
jrtc27 wrote:
Isn't /*Foo=*/bar the modern convention?
https://github.com/llvm/llvm-project/pull/178263
More information about the llvm-commits
mailing list