diff options
-rw-r--r-- | lld/ELF/OutputSections.cpp | 7 | ||||
-rw-r--r-- | lld/ELF/OutputSections.h | 2 |
2 files changed, 4 insertions, 5 deletions
diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp index 92e6c9ba1f5..86c45bf63cb 100644 --- a/lld/ELF/OutputSections.cpp +++ b/lld/ELF/OutputSections.cpp @@ -1027,14 +1027,13 @@ void EHOutputSection<ELFT>::addSectionAux( if (Config->EhFrameHdr) C.FdeEncoding = getFdeEncoding(D); - StringRef Personality; + SymbolBody *Personality = nullptr; if (HasReloc) { uint32_t SymIndex = RelI->getSymbol(Config->Mips64EL); - SymbolBody &Body = *S->getFile()->getSymbolBody(SymIndex)->repl(); - Personality = Body.getName(); + Personality = S->getFile()->getSymbolBody(SymIndex)->repl(); } - std::pair<StringRef, StringRef> CieInfo(Entry, Personality); + std::pair<StringRef, SymbolBody *> CieInfo(Entry, Personality); auto P = CieMap.insert(std::make_pair(CieInfo, Cies.size())); if (P.second) { Cies.push_back(C); diff --git a/lld/ELF/OutputSections.h b/lld/ELF/OutputSections.h index a7b67484c94..3d3984f0847 100644 --- a/lld/ELF/OutputSections.h +++ b/lld/ELF/OutputSections.h @@ -342,7 +342,7 @@ private: std::vector<Cie<ELFT>> Cies; // Maps CIE content + personality to a index in Cies. - llvm::DenseMap<std::pair<StringRef, StringRef>, unsigned> CieMap; + llvm::DenseMap<std::pair<StringRef, SymbolBody *>, unsigned> CieMap; }; template <class ELFT> |