[ELF] Delete dead SHT_NOBITS->SHT_PROGBITS code after r358981

After D60131/r358981, we no longer create SHT_NOBITS sections that may
contain ByteCommand (BYTE, SHORT, LONG, QUAD).

llvm-svn: 362108
This commit is contained in:
Fangrui Song 2019-05-30 15:52:11 +00:00
parent 7316670ef0
commit 0317e46a63
1 changed files with 0 additions and 5 deletions

View File

@ -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];