Refactor symbol caching.

The O(1) hashmap lookup still showed up in profiles.
(because it is in the hot O(log n) binary search loop)

Refactor the caching to use O(log n) map for the cache,
but pull it outside the binary search loop.

This speeds up the symbol lookup by 2x in perfetto.
Same speed up for BM_symbol_find_single_many_times.

Bug: 169745438
Test: libunwindstack_test
Change-Id: Icbe16bd77b8fa72269f2c71c67740b663efee507
3 files changed
tree: f57b75b9543aa2ad9185507bdf90edb19c727066
  1. libbacktrace/
  2. libunwindstack/
  3. OWNERS
  4. PREUPLOAD.cfg