[lld] r294057 - Simplify. NFC.

Rafael Espindola via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 3 13:59:15 PST 2017


Author: rafael
Date: Fri Feb  3 15:59:15 2017
New Revision: 294057

URL: http://llvm.org/viewvc/llvm-project?rev=294057&view=rev
Log:
Simplify. NFC.

Modified:
    lld/trunk/ELF/OutputSections.cpp
    lld/trunk/ELF/OutputSections.h

Modified: lld/trunk/ELF/OutputSections.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/OutputSections.cpp?rev=294057&r1=294056&r2=294057&view=diff
==============================================================================
--- lld/trunk/ELF/OutputSections.cpp (original)
+++ lld/trunk/ELF/OutputSections.cpp Fri Feb  3 15:59:15 2017
@@ -554,13 +554,6 @@ template <class ELFT> OutputSectionFacto
 
 template <class ELFT> OutputSectionFactory<ELFT>::~OutputSectionFactory() {}
 
-template <class ELFT>
-std::pair<OutputSectionBase *, bool>
-OutputSectionFactory<ELFT>::create(InputSectionBase<ELFT> *C,
-                                   StringRef OutsecName) {
-  SectionKey Key = createKey(C, OutsecName);
-  return create(Key, C);
-}
 
 static uint64_t getIncompatibleFlags(uint64_t Flags) {
   return Flags & (SHF_ALLOC | SHF_TLS);
@@ -580,8 +573,9 @@ static bool canMergeToProgbits(unsigned
 
 template <class ELFT>
 std::pair<OutputSectionBase *, bool>
-OutputSectionFactory<ELFT>::create(const SectionKey &Key,
-                                   InputSectionBase<ELFT> *C) {
+OutputSectionFactory<ELFT>::create(InputSectionBase<ELFT> *C,
+                                   StringRef OutsecName) {
+  SectionKey Key = createKey(C, OutsecName);
   uintX_t Flags = getOutFlags(C);
   OutputSectionBase *&Sec = Map[Key];
   if (Sec) {

Modified: lld/trunk/ELF/OutputSections.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/OutputSections.h?rev=294057&r1=294056&r2=294057&view=diff
==============================================================================
--- lld/trunk/ELF/OutputSections.h (original)
+++ lld/trunk/ELF/OutputSections.h Fri Feb  3 15:59:15 2017
@@ -216,9 +216,6 @@ public:
   ~OutputSectionFactory();
   std::pair<OutputSectionBase *, bool> create(InputSectionBase<ELFT> *C,
                                               StringRef OutsecName);
-  std::pair<OutputSectionBase *, bool> create(const SectionKey &Key,
-                                              InputSectionBase<ELFT> *C);
-
 private:
   llvm::SmallDenseMap<SectionKey, OutputSectionBase *> Map;
 };




More information about the llvm-commits mailing list