Confirmed users
51
edits
Vincentlin78 (talk | contribs) m (→Basic steps) |
|||
| (6 intermediate revisions by 2 users not shown) | |||
| Line 17: | Line 17: | ||
* Chrome or Content process CPU bound | * Chrome or Content process CPU bound | ||
** <font color="red">How to make sure the platform is not chrome process CPU bound?</font> In most cases, CPU bound happens in Content process. | ** <font color="red">How to make sure the platform is not chrome process CPU bound?</font> In most cases, CPU bound happens in Content process. | ||
** Enable COMPOSITOR_PERFORMANCE_WARNING option defined in CompositorParent.h. It will print out warning message if layers' transaction or composition time(Chrome process) is too long(the threshold is 15ms now). | |||
*** Note that the composition time here contains both "composite scheduling" and "layers' composing". And the "layers' composing" is executed by GPU if HWComposer is not enabled. | |||
== | For example: | ||
* | "adb shell logcat" may print out the two messages. | ||
** | if composition time is too long => "Compositor: Composite took 20 ms." | ||
** | if transaction time is too long => "Compositor: Layers update took 22 ms (blocking gecko)." | ||
* memcpy peformance | |||
** System memory to graphic memory copy | |||
** System memory to system memory copy | |||
*CPU Scheduler/ CPU Governor | |||
** | ** Lock CPU cores and frequency(platform-dependent) | ||
For example: | |||
adb shell echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor | |||
http://androidforums.com/xperia-mini-all-things-root/513426-android-cpu-governors-explained.html | |||
use watch -n 0.3 "adb shell cat file_node_of_CPU_frequency" | |||
For example: | |||
watch -n 0.3 "adb shell cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq" | |||
** Use simple script to see CPU loading and frequency | |||
*** adb shell while true; do i=1; done | *** adb shell while true; do i=1; done | ||
* Gecko profiler[https://intranet.mozilla.org/TPEPlatform/PerfTool] to get the callstack of CPU bound | ** Gecko profiler[https://intranet.mozilla.org/TPEPlatform/PerfTool] to get the callstack of CPU bound | ||
* Linux perf | ** Linux perf | ||
=== Content process profiling=== | === Content process profiling=== | ||
| Line 41: | Line 50: | ||
=== Chrome process profiling === | === Chrome process profiling === | ||
{{bug|908033}} - [META] Render profiler suite | |||