update
Signed-off-by: Wenchao Hao <haowenchao22@gmail.com>
This commit is contained in:
parent
8030647b8e
commit
eaa21b20af
26
run.sh
26
run.sh
|
|
@ -68,9 +68,31 @@ mkdir $dir/meminfo
|
||||||
mkdir $dir/simpleperf
|
mkdir $dir/simpleperf
|
||||||
mkdir $dir/thpmaps
|
mkdir $dir/thpmaps
|
||||||
|
|
||||||
echo "round app start_type start_time rss pss pagefaults minorfaults majorfaults itlbmiss dtlbmiss cpustall inc_ratio order4_ratio order4_cont inc_total" > $dir/result
|
echo "round app start_type start_time rss pss pagefaults minorfaults majorfaults itlbmiss dtlbmiss cpustall inc_ratio order4_ratio order4_cont inc_total nr_direct_reclaim" > $dir/result
|
||||||
|
|
||||||
for round in $(seq 1 $cycle); do
|
for round in $(seq 1 $cycle); do
|
||||||
|
# 重启并等待重启完成
|
||||||
|
echo "rebooting"
|
||||||
|
adb reboot
|
||||||
|
sleep 30
|
||||||
|
|
||||||
|
# 重启后等待adb
|
||||||
|
# 如果10min还未成功则判断失败
|
||||||
|
for w in $(seq 1 600); do
|
||||||
|
if [ $(adb devices | grep $ANDROID_SERIAL -c) -eq 0 ]; then
|
||||||
|
echo waiting device $w
|
||||||
|
sleep 1
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
adb root
|
||||||
|
break
|
||||||
|
done
|
||||||
|
|
||||||
|
# adb连接后睡眠60s
|
||||||
|
sleep 60
|
||||||
|
|
||||||
|
# 解锁手机
|
||||||
|
~/.scripts/android/unlock.sh
|
||||||
# 等待降温
|
# 等待降温
|
||||||
for f in $(seq 1 900); do
|
for f in $(seq 1 900); do
|
||||||
temp=$(adb shell dumpsys battery | grep temperature | awk '{print $2}')
|
temp=$(adb shell dumpsys battery | grep temperature | awk '{print $2}')
|
||||||
|
|
@ -218,7 +240,7 @@ for round in $(seq 1 $cycle); do
|
||||||
nr_direct_reclaim=$(cat $dir/system_mem/before_vmstat-$app-$round | grep pgscan_direct_throttle | awk '{print $2}')
|
nr_direct_reclaim=$(cat $dir/system_mem/before_vmstat-$app-$round | grep pgscan_direct_throttle | awk '{print $2}')
|
||||||
nr_inc_direct_reclaim=$((nr_direct_reclaim-nr_init_direct_reclaim))
|
nr_inc_direct_reclaim=$((nr_direct_reclaim-nr_init_direct_reclaim))
|
||||||
|
|
||||||
echo $round $app $start_type $start_time $rss $pss $pagefaults $minorfaults $majorfaults $itlbmiss $dtlbmiss $cpustall $inc_ratio $inc_total $order4_ratio $order4_cont $nr_inc_direct_reclaim>> $dir/result
|
echo $round $app $start_type $start_time $rss $pss $pagefaults $minorfaults $majorfaults $itlbmiss $dtlbmiss $cpustall $inc_ratio $inc_total $order4_ratio $order4_cont $nr_inc_direct_reclaim >> $dir/result
|
||||||
|
|
||||||
if [ $clear_background -ne 0 ]; then
|
if [ $clear_background -ne 0 ]; then
|
||||||
python3 clear_apps.py
|
python3 clear_apps.py
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue