]> granicus.if.org Git - llvm/commit
[llvm-objcopy] - Calculate the string table section sizes correctly.
authorGeorge Rimar <grimar@accesssoftek.com>
Mon, 18 Mar 2019 14:27:41 +0000 (14:27 +0000)
committerGeorge Rimar <grimar@accesssoftek.com>
Mon, 18 Mar 2019 14:27:41 +0000 (14:27 +0000)
commitab0a1d7699a58f9ebd13cdd944673bca6fd8985d
treed7b7efd670328b2f74eff1f532a22926669eca8e
parent1772f0a5a32b1de62c28020c904c8f3a1fd8f172
[llvm-objcopy] - Calculate the string table section sizes correctly.

This fixes the https://bugs.llvm.org/show_bug.cgi?id=40980.

Previously if string optimization occurred as a result of
StringTableBuilder's finalize() method, the size wasn't updated.

This hopefully also makes the interaction between sections during finalization
processes a bit more clear.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@356371 91177308-0d34-0410-b5e6-96231b3b80d8
test/tools/llvm-objcopy/ELF/basic-archive-copy.test
test/tools/llvm-objcopy/ELF/cross-arch-sections-symbols.test
test/tools/llvm-objcopy/ELF/shstrtab-optimize.test [new file with mode: 0644]
test/tools/llvm-objcopy/ELF/strtab-optimize.test [new file with mode: 0644]
tools/llvm-objcopy/ELF/Object.cpp
tools/llvm-objcopy/ELF/Object.h