Skip to content

Commit

Permalink
[ELF] Delete dead SHT_NOBITS->SHT_PROGBITS code after r358981
Browse files Browse the repository at this point in the history
After D60131/r358981, we no longer create SHT_NOBITS sections that may
contain ByteCommand (BYTE, SHORT, LONG, QUAD).

llvm-svn: 362108
  • Loading branch information
MaskRay committed May 30, 2019
1 parent 7316670 commit 0317e46
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions lld/ELF/OutputSections.cpp
Expand Up @@ -273,11 +273,6 @@ static void finalizeShtGroup(OutputSection *OS,
}

void OutputSection::finalize() {
if (Type == SHT_NOBITS)
for (BaseCommand *Base : SectionCommands)
if (isa<ByteCommand>(Base))
Type = SHT_PROGBITS;

std::vector<InputSection *> V = getInputSections(this);
InputSection *First = V.empty() ? nullptr : V[0];

Expand Down

0 comments on commit 0317e46

Please sign in to comment.