OSDN Git Service

Fix unit tests, and extend for other architectures
authorSimon Baldwin <simonb@google.com>
Fri, 22 May 2015 14:17:29 +0000 (15:17 +0100)
committerSimon Baldwin <simonb@google.com>
Wed, 27 May 2015 12:20:00 +0000 (13:20 +0100)
commit1011e1a402017506c6a03d0457288f4b1267d9ca
tree750578d62c463b28ec632d1018fb0fff717ad4ed
parent4fc106d34b70da868d194e8a0f0a3cddd1f4c22d
Fix unit tests, and extend for other architectures

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
13 files changed:
tools/relocation_packer/Android.mk
tools/relocation_packer/src/elf_file.cc
tools/relocation_packer/src/elf_file_unittest.cc
tools/relocation_packer/test_data/elf_file_unittest_relocs_arm32.so
tools/relocation_packer/test_data/elf_file_unittest_relocs_arm32_packed.so
tools/relocation_packer/test_data/elf_file_unittest_relocs_arm64.so
tools/relocation_packer/test_data/elf_file_unittest_relocs_arm64_packed.so
tools/relocation_packer/test_data/elf_file_unittest_relocs_ia32.so [new file with mode: 0755]
tools/relocation_packer/test_data/elf_file_unittest_relocs_ia32_packed.so [new file with mode: 0755]
tools/relocation_packer/test_data/elf_file_unittest_relocs_mips32.so [new file with mode: 0755]
tools/relocation_packer/test_data/elf_file_unittest_relocs_mips32_packed.so [new file with mode: 0755]
tools/relocation_packer/test_data/elf_file_unittest_relocs_x64.so [new file with mode: 0755]
tools/relocation_packer/test_data/elf_file_unittest_relocs_x64_packed.so [new file with mode: 0755]