Signed-off-by: Wenchao Hao <haowenchao22@gmail.com>
This commit is contained in:
Wenchao Hao 2025-09-12 21:46:40 +08:00
parent 242be13641
commit 78985b478a
1 changed files with 8 additions and 8 deletions

16
run.sh
View File

@ -112,6 +112,14 @@ for round in $(seq 1 $cycle); do
for app in `cat applist`; do for app in `cat applist`; do
sleep 3 sleep 3
if [ $clear_background -ne 0 ]; then
./clearapp.sh
fi
if [ $cleancache -ne 0 ]; then
adb shell "echo 3 > /proc/sys/vm/drop_caches"
fi
# 抓内存相关信息 # 抓内存相关信息
adb shell free -h > $dir/system_mem/before_free-$app-$round adb shell free -h > $dir/system_mem/before_free-$app-$round
adb shell cat /proc/meminfo > $dir/system_mem/before_meminfo-$app-$round adb shell cat /proc/meminfo > $dir/system_mem/before_meminfo-$app-$round
@ -247,14 +255,6 @@ for round in $(seq 1 $cycle); do
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
./clearapp.sh
fi
if [ $cleancache -ne 0 ]; then
adb shell "echo 3 > /proc/sys/vm/drop_caches"
fi
rm tmp.txt rm tmp.txt
done done
done done