forked from OSchip/llvm-project
parent
e1dc73d9a7
commit
bd3ab097f6
|
@ -534,6 +534,16 @@ static typename ELFT::uint getOutFlags(InputSectionBase<ELFT> *S) {
|
|||
return S->Flags & ~SHF_GROUP & ~SHF_COMPRESSED;
|
||||
}
|
||||
|
||||
namespace llvm {
|
||||
template <> struct DenseMapInfo<lld::elf::SectionKey> {
|
||||
static lld::elf::SectionKey getEmptyKey();
|
||||
static lld::elf::SectionKey getTombstoneKey();
|
||||
static unsigned getHashValue(const lld::elf::SectionKey &Val);
|
||||
static bool isEqual(const lld::elf::SectionKey &LHS,
|
||||
const lld::elf::SectionKey &RHS);
|
||||
};
|
||||
}
|
||||
|
||||
template <class ELFT>
|
||||
static SectionKey createKey(InputSectionBase<ELFT> *C, StringRef OutsecName) {
|
||||
// The ELF spec just says
|
||||
|
@ -600,6 +610,10 @@ static SectionKey createKey(InputSectionBase<ELFT> *C, StringRef OutsecName) {
|
|||
return SectionKey{OutsecName, Flags, Alignment};
|
||||
}
|
||||
|
||||
template <class ELFT> OutputSectionFactory<ELFT>::OutputSectionFactory() {}
|
||||
|
||||
template <class ELFT> OutputSectionFactory<ELFT>::~OutputSectionFactory() {}
|
||||
|
||||
template <class ELFT>
|
||||
std::pair<OutputSectionBase *, bool>
|
||||
OutputSectionFactory<ELFT>::create(InputSectionBase<ELFT> *C,
|
||||
|
|
|
@ -232,6 +232,8 @@ template <class ELFT> class OutputSectionFactory {
|
|||
typedef typename ELFT::uint uintX_t;
|
||||
|
||||
public:
|
||||
OutputSectionFactory();
|
||||
~OutputSectionFactory();
|
||||
std::pair<OutputSectionBase *, bool> create(InputSectionBase<ELFT> *C,
|
||||
StringRef OutsecName);
|
||||
std::pair<OutputSectionBase *, bool> create(const SectionKey &Key,
|
||||
|
@ -262,14 +264,5 @@ template <class ELFT> OutputSectionBase *Out<ELFT>::FiniArray;
|
|||
} // namespace elf
|
||||
} // namespace lld
|
||||
|
||||
namespace llvm {
|
||||
template <> struct DenseMapInfo<lld::elf::SectionKey> {
|
||||
static lld::elf::SectionKey getEmptyKey();
|
||||
static lld::elf::SectionKey getTombstoneKey();
|
||||
static unsigned getHashValue(const lld::elf::SectionKey &Val);
|
||||
static bool isEqual(const lld::elf::SectionKey &LHS,
|
||||
const lld::elf::SectionKey &RHS);
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue