diff options
Diffstat (limited to 'lld/ELF/OutputSections.cpp')
| -rw-r--r-- | lld/ELF/OutputSections.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp index 22470c107ac..0565f36a561 100644 --- a/lld/ELF/OutputSections.cpp +++ b/lld/ELF/OutputSections.cpp @@ -216,6 +216,14 @@ RelocationSection<ELFT>::RelocationSection(StringRef Name, bool IsRela) } template <class ELFT> +void RelocationSection<ELFT>::addReloc(const DynamicReloc<ELFT> &Reloc) { + SymbolBody *Sym = Reloc.Sym; + if (!Reloc.UseSymVA && Sym) + Sym->setUsedInDynamicReloc(); + Relocs.push_back(Reloc); +} + +template <class ELFT> static typename ELFFile<ELFT>::uintX_t getOffset(const DynamicReloc<ELFT> &Rel) { typedef typename ELFFile<ELFT>::uintX_t uintX_t; |

