Write sections mostly in one pass.
authorRafael Espindola <rafael.espindola@gmail.com>
Thu, 30 Apr 2015 14:21:49 +0000 (14:21 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Thu, 30 Apr 2015 14:21:49 +0000 (14:21 +0000)
commitbda1980917bf75c1c42fe1003076382194dcd8c5
tree19d8c79de90f65c6e28b05bfc7966737f4fa34ef
parent9cab73216151b5422da49ae2829db75a658b2763
Write sections mostly in one pass.

During ELF writing, there is no need to further relax the sections, so we
should not be creating fragments. This patch avoids doing so in all cases
but debug section compression (that is next).

Also, the ELF format is fairly simple to write. We can do a single pass over
the sections to write them out and compute the section header table.

llvm-svn: 236235
llvm/lib/MC/ELFObjectWriter.cpp
llvm/test/MC/ARM/eh-directive-section-comdat.s
llvm/test/MC/ARM/eh-directive-section.s
llvm/test/MC/ARM/eh-link.s
llvm/test/MC/ELF/comdat-dup-group-name.s
llvm/test/MC/ELF/comdat-reloc.s
llvm/test/MC/ELF/comdat.s
llvm/test/MC/ELF/section-sym.s