[ELF] - Do not remove empty output sections that are explicitly assigned to phdr...
authorGeorge Rimar <grimar@accesssoftek.com>
Fri, 23 Feb 2018 10:53:04 +0000 (10:53 +0000)
committerGeorge Rimar <grimar@accesssoftek.com>
Fri, 23 Feb 2018 10:53:04 +0000 (10:53 +0000)
commitdb1a06244758537fe831a680ce2b1aedcafafe23
tree313f0a055a4e4781acd75396c3dc13f13e22b79e
parentc7711ba2efea9108a5046272ebc2434aaaa8a23e
[ELF] - Do not remove empty output sections that are explicitly assigned to phdr in script.

This continues direction started in D43069.

We can keep sections that are explicitly assigned to segment in script.
It helps to simplify code.

Differential revision: https://reviews.llvm.org/D43571

llvm-svn: 325887
lld/ELF/LinkerScript.cpp
lld/ELF/LinkerScript.h
lld/ELF/Writer.cpp
lld/test/ELF/linkerscript/implicit-program-header.s
lld/test/ELF/linkerscript/orphan-phdrs.s