simpleperf: Save vDSO for cs-etm.

Traces recorded with cs-etm contain only the changes in control
flow (mostly jumps taken/not taken), with full addresses only included
when necessary (e.g., indirect jumps). To decode the actual control
flow, the binaries need to be available so that the jumps can be
followed in them. If any of the binaries is missing, the decoding will
fail and will only resume at the next full address. This means that
even if it's only the vDSO that is missing, it can make other parts of
the trace undecodable.

Therefore, save the vDSO when tracing with auxtrace. For this:
1. Save the build id of the vdso in the perf.data file, so that it's
   not rejected, when decoding, for having a build id.
2. Save the vDSO as vdso.so next to the perf.data file. Add this file
   to the build ids also, so binary_cache_builder.py will pull it
   down.
3. When decoding on the device and a perf.data file has [vdso] in the
   build ids feature, look for another file with the same build id,
   and if found, use that for the vDSO.

Test: simpleperf record -e cs-etm:u -- true && \
    simpleperf dump --dump-etm element | grep NACC
Test: as above, but with the dump done on host machine
Test: simpleperf_unit_test --gtest_filter=record_cmd.etm_uses_vdso

Change-Id: I67ee86633b3494f404e1fc43fb3fd9d2cfde1ea1
4 files changed