summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lld/ELF/InputSection.cpp1
-rw-r--r--lld/ELF/SyntheticSections.cpp1
2 files changed, 1 insertions, 1 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp
index ef941bc40d4..addfe8f3fc4 100644
--- a/lld/ELF/InputSection.cpp
+++ b/lld/ELF/InputSection.cpp
@@ -923,6 +923,7 @@ MergeInputSection::MergeInputSection(ObjFile<ELFT> *F,
// Note that this function is called from parallelForEach. This must be
// thread-safe (i.e. no memory allocation from the pools).
void MergeInputSection::splitIntoPieces() {
+ assert(Pieces.empty());
ArrayRef<uint8_t> Data = this->Data;
uint64_t EntSize = this->Entsize;
if (this->Flags & SHF_STRINGS)
diff --git a/lld/ELF/SyntheticSections.cpp b/lld/ELF/SyntheticSections.cpp
index ebd77c83be1..c4e1e1140c2 100644
--- a/lld/ELF/SyntheticSections.cpp
+++ b/lld/ELF/SyntheticSections.cpp
@@ -112,7 +112,6 @@ template <class ELFT> MergeInputSection *elf::createCommentSection() {
auto *Ret =
make<MergeInputSection>((ObjFile<ELFT> *)nullptr, &Hdr, ".comment");
Ret->Data = getVersion();
- Ret->splitIntoPieces();
return Ret;
}
OpenPOWER on IntegriCloud