From 5211c2a1a037300833275da67b509169c6c7c355 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Tue, 11 Aug 2015 23:19:06 +0000 Subject: [PATCH] Delete dead code. llvm-svn: 244696 --- lld/ELF/Chunks.h | 8 -------- lld/ELF/Writer.cpp | 1 - 2 files changed, 9 deletions(-) diff --git a/lld/ELF/Chunks.h b/lld/ELF/Chunks.h index e2e7d9a..db205db 100644 --- a/lld/ELF/Chunks.h +++ b/lld/ELF/Chunks.h @@ -48,11 +48,6 @@ public: // It is illegal to call this function on non-section chunks. virtual StringRef getSectionName() const = 0; - // An output section has pointers to chunks in the section, and each - // chunk has a back pointer to an output section. - void setOutputSection(OutputSection *O) { Out = O; } - OutputSection *getOutputSection() { return Out; } - protected: // The VA of this chunk in the output. The writer sets a value. uint64_t VA = 0; @@ -60,9 +55,6 @@ protected: // The offset from beginning of the output file. The writer sets a value. uint64_t FileOff = 0; - // The output section for this chunk. - OutputSection *Out = nullptr; - // The alignment of this chunk. The writer uses the value. uint32_t Align = 1; }; diff --git a/lld/ELF/Writer.cpp b/lld/ELF/Writer.cpp index ee5bc027..67b967b 100644 --- a/lld/ELF/Writer.cpp +++ b/lld/ELF/Writer.cpp @@ -119,7 +119,6 @@ void OutputSection::addSectionChunk(SectionChunk *C) { typedef typename llvm::object::ELFFile::uintX_t uintX_t; Chunks.push_back(C); - C->setOutputSection(this); uintX_t Off = Header.sh_size; Off = RoundUpToAlignment(Off, C->getAlign()); C->setVA(Off); -- 2.7.4