Turn messages that are printed on every run of relocation_packer down to
VLOG(1) to clean up ninja build output.
Bug: 24409581
Change-Id: I040aed6a7b4261eefa6f7278fa451180115b0716
On unpacking, reinstate any p_align values that packing reduced to
page size. Ensures a round-trip pack and unpack is bit-equivalent
to the original input.
https://android-review.googlesource.com/#/c/148492/
Extend unit tests to include ia32, x64, and mips32.
Recreate test data for arm32 and arm64. Generate new test data for
ia32, x64, and mips32.
Bug: http://b/20687795
Bug: http://b/18051137
Change-Id: Ifbca8e206ef447297ba4f19272b813702be27a35
DT_MIPS_RLD_MAP2 stores the difference between dynamic
entry address and the address of the _r_debug (used by GDB)
since the dynamic section and target address are on the
different sides of the hole it needs to be adjusted accordingly
Bug: http://b/20658994
Bug: http://b/18051137
Change-Id: I4c5e379e8a4c68f029467df6dc660f81a7013a09
Having p_align > page_size leads to the situation when striping
packed executables results in unnecessary p_vaddr adjustments.
And it also may result (with probability 1 - 1/sizeof(uintptr_t)) in
misaligned segments following .dynstr
Bug: http://b/20629834
Bug: http://b/18051137
Change-Id: I1c5da4911e4409d63cb09f6b6b0a16ef54f6501b
According to runs on /system/lib there using
unsigned leb128 does not save us any additional
space. In order to keep packing as simple as
possible switch to using signed leb128 for
everything.
Bug: http://b/18051137
Change-Id: I1a47cb9eb2175895b3c3f7c13b4c6b1060de86c0
Statically link libc++ to relocation_packer in
order to make it work from prebuilts
Bug: http://b/18051137
Change-Id: I933ed6a0e48780a26b261069eb6a293432824fe7
This is recent addition to bionic linker. The symbol
versioning was not supported before therefore this bug
went unnoticed.
Also normal exit when there is not enought relocations
to pack. This is to enable integration of relocation_packer
to android build system.
Bug: http://b/20139821
Bug: http://b/18051137
Change-Id: Iaf36ae11c8e4b15cf785b6dd1712a3bdcf47cc45
Some of the commentary in relocation packer code is relevant
only to the packing strategy employed by chromium, and no
longer applies here. This change fixes or deletes it.
Code comment change only; no functional effect.
Change-Id: Id229ee1d802bba608be15b79bc75bf90df557dab
Signed-off-by: Simon Baldwin <simonb@google.com>
Removes:
- src/run_length_encoder.h
artifact of the original packing tool, not used here
- test_data/generate_elf_file_unittest_relocs.sh
- test_data/generate_elf_file_unittest_relocs.py
test data generation for chromium/gyp, not usable here
- README.TXT
because it is now almost entirely outdated
Change-Id: Ic4cd372647d9a365dc52833a6cc1cf66f0c95ec9
1. One binary for all architectures
2. Generalize (and slightly improve) compression
2.1 works on all relocation types (rela?.dyn section only so far)
2.2 Uses same format to encode ElfW(Rel) as well as ElfW(Rela) tables
Bug: 18051137
Change-Id: I66c95d9076954ca115816fc577d0f5ef274e5e72