[libbinder] Enumerate symbols exported from libbinder
Bug: http://b/189438896 Google builds use AutoFDO profiles while partner builds don't. Using AutoFDO profiles changes inlining decisions and in this instance causes more symbols to be exported, compared to the partner builds. This change gets the exported symbols from the .dynsym table from non-profdata libbinder.so [1] and enumerates them in a version script. - One symbol [2], is removed from the arm64 map since it is an STL symbol that is absent from the AutoFDO profiles. - ATM, this is needed only for arm64 and arm32, where AutoFDO profiles are used. It may be a good idea to have linker map files for other arch-es as well. - This is needed for both vendor and platform variants. [1] obtained using the following command: llvm-readelf -s \ out/soong/.intermediates/frameworks/native/libs/binder/libbinder/android_arm_armv8-a_shared/unstripped/libbinder.so \ | sed -n '/.symtab/q;p' | grep -v UND | awk '{print $8}' | sort [2] _ZNSt3__16vectorIlNS_9allocatorIlEEE6insertIPKlEENS_9enable_ifIXaasr21__is_forward_iteratorIT_EE5valuesr16is_constructibleIlNS_15iterator_traitsIS8_E9referenceEEE5valueENS_11__wrap_iterIPlEEE4typeENSC_IS6_EES8_S8_ Test: Build coral with and without vendor/google_data/pgo_profile/libbinder.profdata and verify that the command [1] above yields identical results for platform and vendor libbinder for both aarch64 and arm. (arbitrary merged-in tag to restrict to sc-dev) Change-Id: I37166d4313bd2940787e1a88854a90cf47316bf3 Merged-In: Iba9db702ca6f4a0e590e275bf80e770fb1c7361f
Loading
Please register or sign in to comment