summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-03-08Merge "simpleperf: Fix cached map in OfflineUnwinder."android-o-mr1-iot-preview-7o-mr1-iot-preview-7Yabin Cui
2018-03-08Merge "simpleperf: fix an error using std::string."Yabin Cui
2018-03-07simpleperf: fix an error using std::string.Yabin Cui
Bug: none Test: run simpleperf_unit_test. Change-Id: I7d1332f36780303bb3f14adedb5b049aefbb523c
2018-03-07simpleperf: Fix cached map in OfflineUnwinder.Yabin Cui
In system wide profiling, sometimes a sample record goes before all mmap records of a process. Then thread.maps->version = 0 and cached_map.map isn't created. This is caught by simpleperf_unit_test. Bug: none Test: run simpleperf_unit_test. Change-Id: I99254396d0fb22531f735ff3193b8d3b1f9641dd
2018-03-06Merge "simpleperf: fix calculating cpu frequency."Yabin Cui
2018-03-06simpleperf: fix calculating cpu frequency.Yabin Cui
When calculating cpu frequency and other frequencies, use time running on cpu instead of total passed time. This is to be consistent with linux-tools-perf. This is reported in https://github.com/android-ndk/ndk/issues/644. Bug: none Test: run simpleperf_unit_test. Change-Id: Ic385939c189fb86c6b3c648d2c0a4e9636c13c93
2018-02-26Merge "simpleperf: flush output before quick_exit."android-p-preview-1Yabin Cui
2018-02-26simpleperf: flush output before quick_exit.Yabin Cui
Bug: http://b/73875722 Test: run simpleperf manually. Change-Id: I010c8612b18cd4034199440cb178d9d9cc8f0ff4
2018-02-23Merge "simpleperf: use quick_exit."Yabin Cui
2018-02-23Merge "Create maps for libunwind only if they changed."David Srbecky
2018-02-23simpleperf: use quick_exit.Yabin Cui
Bug: none Test: run simpleperf_unit_test. Test: run simpleperf manually. Change-Id: I5e7229c8d5bfc4d47a6b7e403e627137c7f36b55
2018-02-22Create maps for libunwind only if they changed.Christopher Ferris
Increases speed (unwinds per second) by 50%. Bug: None Test: manual - took a profile Test: run simpleperf_unit_test. Change-Id: I254f70a011c1b3d31bbd4e9e4bb9e85fbf2ffbdf
2018-02-22Merge "Fix the build failure for iot targets in master-iot-dev"Treehugger Robot
2018-02-22Fix the build failure for iot targets in master-iot-devNan Zhang
Fix: system/extras/brillo_config/Android.mk:83: error: $(file ...) is not supported in rules. Test: m -j32 Bug: b/73753971 Change-Id: I96099be887f404042c28d3fa1c9f4a2e12ce1222
2018-02-22Merge "Use HAS_BUILD_NUMBER to check engineering build"Treehugger Robot
2018-02-21Merge "Skips symbolization."Christopher Ferris
2018-02-21Use HAS_BUILD_NUMBER to check engineering buildNan Zhang
And use BUILD_NUMBER_FROM_FILE instead of BUILD_NUMBER to reduce build reruns. Test: m -j32 Bug: b/70351683 Change-Id: Ic2a6e2095712828c8314fdd5fca7669f2fb88bc3
2018-02-20Skips symbolization.Christopher Ferris
Bug: 73558129 Test: Passes unit tests. Change-Id: I7cbe618f622b540abf486777f0d40a18f890dbef
2018-02-15Merge "Use BUILD_DATETIME_FROM_FILE instead of BUILD_DATETIME in brillo_config"Treehugger Robot
2018-02-15Merge "simpleperf: fix cmd_debug_unwind tests."Yabin Cui
2018-02-14Merge "simpleperf: fix --interval option in system wide stating."Yabin Cui
2018-02-14simpleperf: fix cmd_debug_unwind tests.Yabin Cui
Without flushing stdout, the tests may fail when running `adb shell simpleperf_unit_test`. Bug: none Test: run `adb shell simpleperf_unit_test`. Change-Id: I8bcf739e7672e8affc71df0a3f11264c0bd7f745
2018-02-14Use BUILD_DATETIME_FROM_FILE instead of BUILD_DATETIME in brillo_configNan Zhang
Soong_UI will handle build timestamp and export date file to Make. Test: m -j32 Bug: b/70351683 Change-Id: I09ac0117c899afadf28e562d83e95f3132a47e20
2018-02-14simpleperf: fix --interval option in system wide stating.Yabin Cui
Bug: none Test: run simpleperf_unit_test. Change-Id: Ida90ecd465e5c63f0f813cde63d70acfeb1281da
2018-02-14Merge "Declare explicitly thumb mode."Chih-hung Hsieh
2018-02-14Merge "simpleperf: Use cross-arch unwinding."Yabin Cui
2018-02-14Declare explicitly thumb mode.Chih-Hung Hsieh
* bandwidth.h contains thumb mode only instructions. Test: normal build. Change-Id: Ib40dfda63f668949370405e7ec53f5f9828200e6
2018-02-14Merge "Fix PDK build"Logan Chien
2018-02-13simpleperf: Use cross-arch unwinding.Yabin Cui
Enables cross-arch unwinding since the new unwinder supports cross-arch unwinding. Also change tests accordingly. Bug: http://b/73127000 Test: run simpleperf_unit_test. Change-Id: I3ca3f7a81b40e9f7ea2b39b9fdc951f9e7a6acc7
2018-02-13Fix PDK buildLogan Chien
This commit disables "perfporfd" in PDK builds because "perfporfd" depends on "libservices" (from "frameworks/base") which is not in PDK builds as well. Test: Build a target (described in http://b/72961456) with `platform.zip` built from master FSK source tree. Bug: 72961456 Change-Id: Ia4913435642cd09a321afb9f583331ca24a8e4be
2018-02-08Merge "simpleperf: improve debug-unwind cmd."Yabin Cui
2018-02-08simpleperf: improve debug-unwind cmd.Yabin Cui
In debug-unwind cmd: 1. Add --symfs option. 2. Add meta_info section when there isn't one. 3. Add file section when there isn't one. Rename unwinding_result_reporter.py to debug_unwind_reporter.py, and fix a small error in it. Bug: http://b/72556486 Test: run simpleperf_unit_test. Test: run debug_unwind_reporter.py manually. Change-Id: Ibc66b7bfdc91a17f6f1c2c0e84f4769d2bcaa1e7
2018-02-07Merge "Simpleperf: Support record --"Treehugger Robot
2018-02-06Simpleperf: Support record --Andreas Gampe
Support optional "--" to be compatible with linux-perf. Test: mmma system/extras/simpleperf Test: simpleperf_unit_test Change-Id: I4c2627625bb97514d86c8972ef5a0a31bf518b76
2018-02-06Merge "simpleperf: add debug-unwind cmd."Yabin Cui
2018-02-05simpleperf: add debug-unwind cmd.Yabin Cui
Currently, we use --log debug option in record cmd to debug offline unwinding. However, it has below disadvantages: 1. It adds extra complexity in record cmd. 2. It doesn't keep reg/stack data of samples. 3. It isn't convenient to reproduce samples in problem. Because each time recording gets different samples. 4. It isn't very suitable for performance test of unwinding, for the same reason as item 3. So instead, this CL adds debug-unwind cmd focusing on debugging and testing offline unwinding. It solves problems mentioned above. Also change unwinding_result_reporter.py to make it work with perf.data generated by debug-unwind cmd. Bug: http://b/72556486 Test: run simpleperf_unit_test. Test: run unwinding_result_reporter.py manually. Change-Id: I11cdf1eba993f48d61ef9891ad1be54d29679fdb
2018-02-01Merge "simpleperf: Switch to use post-unwind by default in record cmd."Yabin Cui
2018-01-31simpleperf: Switch to use post-unwind by default in record cmd.Yabin Cui
When recording google.sample.tunnel app for 30s: It took 3s to unwind samples and write unwound samples to file. It took 0.3s to write samples containing stack/reg data to file. The result shows recording with post unwinding consumes much less time than unwinding samples immediately. This means we can record with higher freq and get smaller lose rate when using post unwinding. So make below changes: 1. Make post unwinding by default. 2. Replace --post-unwind with --no-post-unwind option. 3. Make --trace-offcpu and callchain joiner work with post unwinding. 4. Remove special operations in --log debug mode. Those will be supported in a new command. Bug: http://b/72556486 Test: run simpleperf_unit_test. Test: run python test.py. Change-Id: I9a5a5defda9d040985e674c43db19ee68e7aa305
2018-01-31Merge "inferno: support --one-flamegraph option."Yabin Cui
2018-01-30Merge "simpleperf: fix mac build."Yabin Cui
2018-01-30simpleperf: fix mac build.Yabin Cui
Bug: none Test: none Change-Id: Ia4e6dd0e44e19379d79a08a8555ad413ba879bf2
2018-01-30inferno: support --one-flamegraph option.Yabin Cui
Also split options into groups. Bug: http://b/72495881 Test: manually. Change-Id: Iec322fc1f1afb74ee5ee0fb19145d16926064332
2018-01-30Merge "Change to new libbacktrace offline functions."Christopher Ferris
2018-01-29Change to new libbacktrace offline functions.Christopher Ferris
Changes: - Removes references to libunwind. - Add enabling of global Elf cache. - Add new ApkInspector function to get the offset from an apk by name. - When a map name contains a '!' convert back to a name and offset. - Initialize global elf cache in OfflineUnwinder constructor. Bug: 65682279 Test: All unit tests pass. Change-Id: I303b4beab8270ed2097cd17d91253c321cdc97f1
2018-01-29Merge changes I1bdeffc6,I3e13db97Treehugger Robot
* changes: Perfprofd: Clean up test logging helper Perfprofd: Backport elf symbolizer config to ConfigReader
2018-01-29Perfprofd: Clean up test logging helperAndreas Gampe
Clean up, in preparation for a potential move to libbase. Test: mmma system/extras/perfprofd Test: perfprofd_test Change-Id: I1bdeffc6b69bd8c2513e1b2fce103bbae1c53dad
2018-01-28Perfprofd: Backport elf symbolizer config to ConfigReaderAndreas Gampe
Add an entry to ConfigReader to initialize usage of the ELF symbolizer. Use this to turn off on-device symbolization for live testing, as warnings about missing DSOs will pollute the logs and make the tests fail. Test: mmma system/extras/perfprofd Test: perfprofd_test Change-Id: I3e13db9779e5d2edfb14e2fbe2b3d186ef7af0bd
2018-01-27Merge "Perfprofd: Add process name to sampling"Treehugger Robot
2018-01-26Merge "inferno: show time duration for perf.data recorded with --trace-offcpu."Yabin Cui
2018-01-25inferno: show time duration for perf.data recorded with --trace-offcpu.Yabin Cui
Bug: http://b/72323886 Bug: http://b/72330172 Test: manually. Change-Id: I91ece3081e0a7dcbe068154b36b35a694519af8e