diff options
author | Yabin Cui <yabinc@google.com> | 2018-07-23 15:32:47 -0700 |
---|---|---|
committer | Yabin Cui <yabinc@google.com> | 2018-07-23 17:50:59 -0700 |
commit | a6a04203418f6023b714a5cec6c9f75d1452e841 (patch) | |
tree | 6e690ef66db3cfd0059b2fc06bb40915ec5e449e /simpleperf/cmd_record.cpp | |
parent | 52b5c79cac2c8f6ef51ed9187d8ef3d937ef13bf (diff) | |
download | extras-a6a04203418f6023b714a5cec6c9f75d1452e841.tar.gz |
simpleperf: use libunwindstack directly for unwinding.
Using BacktraceMap needs to rebuild all maps when some map is
changed. For example, in a system wide recording, about 7% cpu time
in unwinding is used for allocating and freeing map space. By switching
to unwindstack::Maps and update maps when some map is changed, It can
reduce about 10% cpu time in unwinding.
Also set max unwinding frames to 512.
Also remove deprecated unwinding error code.
Bug: 110923759
Test: run simpleperf_unit_test.
Change-Id: I9bd8c54e5087c33de2929768a83e749240ddb203
Diffstat (limited to 'simpleperf/cmd_record.cpp')
-rw-r--r-- | simpleperf/cmd_record.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/simpleperf/cmd_record.cpp b/simpleperf/cmd_record.cpp index 3ae111cf..7b928e5f 100644 --- a/simpleperf/cmd_record.cpp +++ b/simpleperf/cmd_record.cpp @@ -17,6 +17,7 @@ #include <inttypes.h> #include <libgen.h> #include <signal.h> +#include <sys/mman.h> #include <sys/prctl.h> #include <sys/utsname.h> #include <time.h> |