summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-08-14Merge "simpleperf: export more info through report_lib_interface."android-o-iot-preview-5o-iot-preview-5Yabin Cui
2017-08-14Merge "simpleperf: format inferno code."Yabin Cui
2017-08-14Merge "simpleperf: fix link of README.md."Yabin Cui
2017-08-14simpleperf: export more info through report_lib_interface.Yabin Cui
Make below changes to better suppport inferno: 1. Save product properties of device in perf.data. 2. Add a python/c api GetFeatureSection. It is used to support reading record cmd and meta info from perf.data. 3. Remove old api GetNextMetaInfo, because meta info can be exported by GetFeatureSection more easily. 4. When reading perf.data in record_file_reader.cpp, remove callchain at and below ip == 0 to avoid caller's effort. Also move to use android-base/properties.h. Bug: http://b/64035530 Test: run simpleperf_unit_test and test.py. Change-Id: Ib6743a09167e2b7cd65a12f17d991bc1ac628588
2017-08-14simpleperf: fix link of README.md.Yabin Cui
Bug: None Test: None Change-Id: If06288b0b5b2b2ec20a7fc4f930c5ca3d0198978
2017-08-14Merge "simpleperf: improve warning msg."Yabin Cui
2017-08-11simpleperf: improve warning msg.Yabin Cui
The warning of missing symbol for each lib is shown twice, once in recording, and once in reporting. This is redundant and maybe misleading. Because when reporting we actually don't know if we have collected enough symbols in perf.data. So move warning of missing symbols to debug info if we have symbols in perf.data. Use customized StderrLogger, because simpleperf doesn't need time,pid,tid information in log. Bug: http://b/29574526 Test: run simpleperf manually and run simpleperf_unit_test. Change-Id: I9baf6d8fdcd63907681f2daa45b8fad6bf7e2516
2017-08-11simpleperf: format inferno code.Yabin Cui
Format python code using autopep8. Change Javascript code to ES6, and format it using eslint. Bug: http://b/64035530 Test: run inferno. Change-Id: I8b3553bf49423275da8eb3ad6fe3d8bb8dcf0a5b
2017-08-10Merge "simpleperf: use app_profiler.py in inferno."Yabin Cui
2017-08-09Merge "simpleperf: fix stat cmd."Treehugger Robot
2017-08-08Merge "simpleperf: add --exit-with-parent option in record cmd."Yabin Cui
2017-08-08simpleperf: fix stat cmd.Yabin Cui
Previous CL wrongly makes kernel dump samples for stat cmd. Bug: http://b/64489160 Test: run simpleperf_unit_test. Change-Id: I4f5c08839e283b2361e47d61310e5161433824bb
2017-08-08simpleperf: add --exit-with-parent option in record cmd.Yabin Cui
This makes it optional whether simpleperf stops recording when the parent dies. Bug: http://b/64391339 Test: run simpleperf_unit_test. Change-Id: I0827a17d6fedbb9763347df76da9dc981fea6312
2017-08-07simpleperf: use app_profiler.py in inferno.Yabin Cui
Also add tests to check if we can run inferno successfully. More tests will be added to check report results of inferno. Bug: http://b/64035530 Test: run test.py. Change-Id: Ie5dd1f5cb47c8c7a2ae68f8614cf81b68e3c7dbf
2017-08-07Merge "simpleperf: allow recording events in different speed."Yabin Cui
2017-08-07Merge "Fix fd ownership issue in PrintNativeInfo/GetNativeInfo."Elliott Hughes
2017-08-07simpleperf: allow recording events in different speed.Yabin Cui
Currently record command interface only allows one sample freq or sample period for all events. This is not convenient when recording both non tracepoint events and tracepoint events. This CL allows setting different sample speed for different events. For example, for "-f 1000 -e cpu-cycles -c 1 sched:sched_switch", "-f 1000" applies to cpu-cycles, and "-c 1" applies to sched:sched_switch. It also fixes a bug about trace-offcpu: if "-f 1000 --trace-offcpu" is used, the sched:sched_switch is be samples with "-f 1000". But we want to sample it with "-c 1". Also change the order of options in the help msg of record cmd to make it more readable. Remove -F option. Because adding it seems not useful. Bug: http://b/37572306 Test: run simpleperf_unit_test. Change-Id: Ifdbd27c8f9fec49aade0e0e6ce624d8114042020
2017-08-07Fix fd ownership issue in PrintNativeInfo/GetNativeInfo.Elliott Hughes
Bug: N/A Test: ran tests Change-Id: I10bdeeb38404583560685bf47c58f6770fc9050b Signed-off-by: Ivan Maidanski <i.maidanski@samsung.com>
2017-08-04Merge "simpleperf: support profiling native programs in app_profiler.py."Yabin Cui
2017-08-04Merge "simpleperf: export meta info in report_sample.proto."Yabin Cui
2017-08-03simpleperf: export meta info in report_sample.proto.Yabin Cui
To support perf.data generated with --trace-offcpu option, update interface in report_sample.proto: 1. Add meta info to show all event types. 2. Add event_type_id in each sample to show which even type it belongs to. Bug: http://b/37572306 Test: run simpleperf_unit_test. Change-Id: I2878979ec2023904df1006ce353dcf233b6a2642
2017-08-03Merge "Fix clang-tidy performance-* warnings in system/extras."Treehugger Robot
2017-08-03simpleperf: support profiling native programs in app_profiler.py.Yabin Cui
This is a preparation of using app_profiler.py in inferno. In app_profiler.py: Add -np option to profile native programs like surfaceflinger. Add -cmd option to profile command lines. Add --arch option to set the app arch, because we don't guess the app arch when profiling command lines. Add corresponding tests in test.py. Also improve the way of detecting whether the device supports trace-offcpu. Bug: http://b/63006886 Test: run test.py. Change-Id: Id899063d9a94beec67b22fd7710cda7a438557fb
2017-08-03Fix clang-tidy performance-* warnings in system/extras.Chih-Hung Hsieh
* Use const reference parameter type to avoid unnecessary copy. * Use more efficient overloaded string methods. Bug: 30407689 Bug: 30411878 Test: build with WITH_TIDY=1 Change-Id: I558d482910c8a53c042d876848e35cdce8b8c15b
2017-08-03Merge "simpleperf: fix supporting ctrl-c when using `adb shell simpleperf xxx`."Treehugger Robot
2017-08-02simpleperf: fix supporting ctrl-c when using `adb shell simpleperf xxx`.Yabin Cui
Also fix a problem that binary_cache_builder.py tries to pull /dev/zero. Bug: None. Test: run test.py TestExamplePureJava.test_app_profiler_with_ctrl_c. Change-Id: Ie99af6795bb1e81ae6e93f8b7a8907d49c048694
2017-08-02Merge "simpleperf: update simpleperf prebuilts to build 4237700."Yabin Cui
2017-08-02simpleperf: update simpleperf prebuilts to build 4237700.Yabin Cui
Taken from branch aosp-master. Test: None. Change-Id: Idcf75340fb9c0d7b8c81f64eeb2cb94a4c432224
2017-08-01Merge "simpleperf: split README.md in doc directory."Yabin Cui
2017-07-31simpleperf: split README.md in doc directory.Yabin Cui
Move README.md to doc directory, split inferno doc into inferno.md, move pictures from scripts/inferno/ to doc/. Improve the content about showing flamegraphs in README.md. Bug: http://b/64123842 Test: No. Change-Id: Ia3ebd0bbbda21fa816b94cd349c901b5c7713564
2017-07-31Merge "simpleperf: add --show-features option in list cmd."Yabin Cui
2017-07-29Merge "Update for v4.12.3 kernel headers."Christopher Ferris
2017-07-28simpleperf: add --show-features option in list cmd.Yabin Cui
It is used to show features supported on the device. Bug: http://b/64147273 Test: run simpleperf_unit_test. Change-Id: Idb7821e74d1a23f8988ef2207696114498713f47
2017-07-29Merge "simpleperf add more script tests."Yabin Cui
2017-07-28simpleperf add more script tests.Yabin Cui
Add tests for Trace offcpu. Add test for jni call. Build testdata when running test.py. Bug: http://b/63006886 Test: run test.py. Change-Id: I5a87b8d2a8f59ead858c1b78a78c7e78847854f4
2017-07-28Update for v4.12.3 kernel headers.Christopher Ferris
Modify the host side linux byteorder.h to set the defines for little endian. The new kernel headers require the defines, or there will be compile errors. Test: Ran all host side unit tests. Change-Id: I05f0ea0695a56525af3cd808f2ae9a8d6b5c49db
2017-07-28Merge "ext4_utils: enable uninit_bg feature for ext4 mke2fs"Treehugger Robot
2017-07-27ext4_utils: enable uninit_bg feature for ext4 mke2fsJin Qian
Some devices have very slow storage media. This feature can speed up filesystem creation time noticeably. Bug: 63809106 Bug: 64101366 Change-Id: Id4886822035808bcb279dbf6f81989fee9cc0ace (cherry picked from commit 794223c633652b714db804729b5f57d3689a1f91)
2017-07-27Merge "simpleperf: fix README.md to show inferno pictures correctly."Yabin Cui
2017-07-27Merge "simpleperf: update simpleperf prebuilts to build 4219235."Yabin Cui
2017-07-26simpleperf: update simpleperf prebuilts to build 4219235.Yabin Cui
Taken from branch aosp-master. Test: none. Change-Id: I64c9a60b4251549a22d44e9444824a439d5f4cc1
2017-07-26simpleperf: fix README.md to show inferno pictures correctly.Yabin Cui
Bug: http://b/63006886 Test: none. Change-Id: If27d2f0d91e2121c3d58c0b5451dee98934f2d40
2017-07-26Merge "Fix a memory leak"Treehugger Robot
2017-07-25Fix a memory leakGeorge Burgess IV
This fixes the following memory leak: system/extras/tests/tcp_nuke_addr/tcp_nuke_addr_test.cpp:146:20: warning: Potential memory leak [clang-analyzer-cplusplus.NewDeleteLeaks] Namely, clang was upset that we didn't free the std::threads we new'ed up. Immediately detach()ing them gets us the same effect. (Context: We're trying to clean up scary-sounding warnings like this in Android. I realize that, in this case, a leak is harmless, but...) Bug: 27101951 Test: mma. Memory leak warning is gone. Ran the test on bullhead for 60s; seemed to work (last line of output is "60s: 246 cps, total 25432") Change-Id: I4b6b5679430968e01ffea5bc10309a4ced04ba4e
2017-07-26Merge "simpleperf: move inferno to scripts directory."Treehugger Robot
2017-07-25Merge "simpleperf: support reporting trace offcpu data in ↵Treehugger Robot
simpleperf_report_lib."
2017-07-25simpleperf: move inferno to scripts directory.Yabin Cui
This is a preparation for integrating inferno with python scripts under scripts/. Bug: http://b/64035530 Test: run inferno.py. Change-Id: I60ee1c30f650307aa58a038448cddb4eef43acb5
2017-07-25Merge "Remove LOCAL_CLANG and clang: true"Treehugger Robot
2017-07-25simpleperf: support reporting trace offcpu data in simpleperf_report_lib.Yabin Cui
Export python interface for reading meta info. Change sample.period to sample time difference when trace_offcpu is true. Add unit tests. Bug: http://b/37572306 Test: run python test.py. Change-Id: Ic144314184d115cc55630d3c69b66a0d8594721a
2017-07-25Merge "simpleperf: use --app option in python scripts and README.md."Yabin Cui