[Android]bootchart

1. PC tools

$ sudo apt-get install bootchart  
$ sudo apt-get install pybootchartgui

2.Rebuild Android

//modify system/core/init/bootchart.h
#ifndef BOOTCHART
#define  BOOTCHART  1 //"1"means enable 
#endif


$export INIT_BOOTCHART=true
#Make sure the flag will NOT be overrided
#and then recompile init.
#mmm system/core/
$make bootimage
#Then flash the image and reboot


3.Config the bootchart

# config duration
$ adb shell 'echo 120 > /data/bootchart-start'

#config saved file path
$ adb shell 'mkdir /data/bootchart'

4. reboot

5. parse data

#pull the bootchart log from /data/bootchart
system/core/init/grab-bootchart.sh

#export as a png
$bootchart ./bootchart.tgz 



阅读更多
个人分类: Android C/C++ linux
想对作者说点什么? 我来说一句

没有更多推荐了,返回首页

不良信息举报

[Android]bootchart

最多只允许输入30个字

加入CSDN,享受更精准的内容推荐,与500万程序员共同成长!
关闭
关闭