进入 adb下,执行如下命令:
root@android:/ # dd if=/dev/zero of=data/ll.bin bs=1024576 count=256 //测试写的速度
root@android:/ # echo 3 > /proc/sys/vm/drop_caches
root@android:/ # dd of=/dev/null if=/data/ll.bin bs=1024576 //测试读的速度
测试结果如下:
root@android:/ # dd if=/dev/zero of=data/ll.bin bs=1024576 count=256
dd if=/dev/zero of=data/ll.bin bs=1024576 count=256
256+0 records in
256+0 records out
262291456 bytes transferred in 7.606 secs (34484808 bytes/sec)
root@android:/ # echo 3 > /proc/sys/vm/drop_caches
echo 3 > /proc/sys/vm/drop_caches
root@android:/ # dd of=/dev/null if=/data/ll.bin bs=1024576
dd of=/dev/null if=/data/ll.bin bs=1024576
256+0 records in
256+0 records out
262291456 bytes transferred in 12.473 secs (21028738 bytes/sec)