summaryrefslogtreecommitdiffstats
path: root/lld/ELF/OutputSections.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lld/ELF/OutputSections.cpp')
-rw-r--r--lld/ELF/OutputSections.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp
index 8d2b1668eab..7998d89367e 100644
--- a/lld/ELF/OutputSections.cpp
+++ b/lld/ELF/OutputSections.cpp
@@ -565,6 +565,13 @@ static bool canMergeToProgbits(unsigned Type) {
Type == SHT_NOTE;
}
+template <class ELFT> static void reportDiscarded(InputSectionBase<ELFT> *IS) {
+ if (!Config->PrintGcSections)
+ return;
+ errs() << "removing unused section from '" << IS->Name << "' in file '"
+ << IS->getFile()->getName() << "'\n";
+}
+
template <class ELFT>
void OutputSectionFactory<ELFT>::addInputSec(InputSectionBase<ELFT> *IS,
StringRef OutsecName) {
OpenPOWER on IntegriCloud