android: crazy_linker: Add GNU hash table support.
The static linker currently generates two symbol hash tables by default in each ELF binary (executables or shared libraries). One uses the old, slow and large SysV format, and the other the much smaller and much faster GNU format. This CL adds support for the GNU format to the crazy linker library (which turns out to require very little code). This will allow the removal of the SysV table whenever the chromium linker is being used (i.e. for ChromePublic.apk and ChromeModernPublic.apk and their derivatives). This will also be handy when we split libchrome.so into several native libraries in the future (e.g. to support android app feature modules like VR), which will require exporting a lot more symbols. Note that MonochromePublic.apk, which only runs on Android N+ already uses GNU tables exclusively (for the record, support for this format was added in Android M / API level 23). + Add unit-tests. And scripts to generate the test data from a known list of symbols. + Add a small script to regenerate all auto-generated sources at once. BUG=851391 R=pasko@chromium.org, rmcilroy@chromium.org, agrieve@chromium.org, cjgrant@chromium.org Change-Id: I42b1aac46445b5b4d4b3b4f69eaa69ea47e7ab3c Reviewed-on: https://chromium-review.googlesource.com/1216122 Commit-Queue: David Turner <digit@chromium.org> Reviewed-by:agrieve <agrieve@chromium.org> Reviewed-by:
Egor Pasko <pasko@chromium.org> Cr-Commit-Position: refs/heads/master@{#590291}
Showing
Please register or sign in to comment