hi
On 13/07/11 20:05, Arnd Bergmann wrote:
On Wednesday 13 July 2011 19:16:09 Peter Warasin wrote:
fast with wrong erase block and slow with correct(?) one.. ?-)
It's more likely that now your partitition is misaligned, because the start is not a multiple of 1.5MB.
ah yeah, sure, very reasonable indeed :)
$ fdisk -ul /dev/sda
Disk /dev/sda: 15.9 GB, 15931539456 bytes 64 heads, 32 sectors/track, 15193 cylinders, total 31116288 sectors Units = sectors of 1 * 512 = 512 bytes Disk identifier: 0x00000000
Device Boot Start End Blocks Id System /dev/sda1 3072 1022975 509952 83 Linux Partition 1 does not end on cylinder boundary. /dev/sda2 1022976 31116287 15046656 83 Linux
Sorry, my fault. It needs to be --blocksize=3072 or a multiple of that. The reason for this is that O_DIRECT accesses need to be multiples of 512 byte aligned in Linux, and the test reads will be moved to half of --blocksize.
ah, ok. good, it's working now.
$ ./flashbench -a /dev/sda1 --count=100 --blocksize=3072 align 100663296 pre 959µs on 961µs post 974µs diff -5051ns align 50331648 pre 941µs on 935µs post 925µs diff 1.49µs align 25165824 pre 813µs on 834µs post 833µs diff 11.7µs align 12582912 pre 947µs on 979µs post 996µs diff 7.99µs align 6291456 pre 998µs on 1ms post 1.02ms diff -5067ns align 3145728 pre 1ms on 994µs post 1.02ms diff -13866n align 1572864 pre 1ms on 1.07ms post 1ms diff 70.2µs align 786432 pre 1ms on 1ms post 1.01ms diff -6167ns align 393216 pre 1ms on 1ms post 1.02ms diff -8731ns align 196608 pre 1ms on 1ms post 1.02ms diff -6397ns align 98304 pre 1ms on 998µs post 1.01ms diff -9612ns align 49152 pre 998µs on 1ms post 1.02ms diff -9015ns align 24576 pre 1.02ms on 1.02ms post 1ms diff 9.32µs align 12288 pre 999µs on 999µs post 989µs diff 4.77µs align 6144 pre 1ms on 990µs post 1ms diff -13454n
still quite strange values :/
$ ./flashbench /dev/sda1 -O --open-au-nr=1 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 6MiB 3.99M/s 3MiB 3.06M/s 1.5MiB 4.01M/s 768KiB 4.01M/s 384KiB 3.91M/s 192KiB 3.92M/s 96KiB 4.3M/s 48KiB 4.15M/s 24KiB 2.87M/s 12KiB 2.2M/s 6KiB 1.62M/s 3KiB 1.07M/s
$ ./flashbench /dev/sda1 -O --open-au-nr=2 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 6MiB 3.4M/s 3MiB 4.14M/s 1.5MiB 4.02M/s 768KiB 4.01M/s 384KiB 3.92M/s 192KiB 3.81M/s 96KiB 4.31M/s 48KiB 4.16M/s 24KiB 2.54M/s 12KiB 2.19M/s 6KiB 1.64M/s 3KiB 1.03M/s
$ ./flashbench /dev/sda1 -O --open-au-nr=5 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 6MiB 4.28M/s 3MiB 3.11M/s 1.5MiB 4.06M/s 768KiB 4.03M/s 384KiB 3.93M/s 192KiB 3.95M/s 96KiB 4.35M/s 48KiB 4.19M/s 24KiB 2.76M/s 12KiB 2.24M/s 6KiB 1.65M/s 3KiB 1.06M/s
$ ./flashbench /dev/sda1 -O --open-au-nr=6 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 6MiB 4.12M/s 3MiB 3.07M/s 1.5MiB 3.06M/s 768KiB 1.56M/s 384KiB 752K/s 192KiB 378K/s 96KiB 197K/s 48KiB 98.1K/s ^C
-> ok, definitively 5 blocks i guess
$ ./flashbench /dev/sda1 -O --open-au-nr=5 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 --random 6MiB 3.4M/s 3MiB 3.03M/s 1.5MiB 4.07M/s 768KiB 2.11M/s 384KiB 949K/s 192KiB 545K/s 96KiB 293K/s 48KiB 149K/s 24KiB 73.4K/s ^C
$ ./flashbench /dev/sda1 -O --open-au-nr=1 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 --random 6MiB 3.09M/s 3MiB 3.11M/s 1.5MiB 4.15M/s 768KiB 3.17M/s 384KiB 2.05M/s 192KiB 1.94M/s 96KiB 1.48M/s 48KiB 1.9M/s 24KiB 1.06M/s 12KiB 715K/s 6KiB 391K/s 3KiB 212K/s
$ ./flashbench /dev/sda1 -O --open-au-nr=4 --erasesize=$[4*(1024*1024+1024*512)] --blocksize=3072 --random 6MiB 3.46M/s 3MiB 3.15M/s 1.5MiB 4.19M/s 768KiB 2.17M/s 384KiB 978K/s 192KiB 551K/s 96KiB 299K/s 48KiB 156K/s ^C
-> well, looks not that good
I also forgot to mention that the --findfat test case is pointless on a partition. What it does is to write to the first few erase blocks in order to find the FAT optimized regions. If they exist, they are always on the beginning of the card, so never on the beginning of a later partition.
ah, ok. so i will redo them
./flashbench /dev/sda -f --erasesize=$[1024*1024+1024*512] --blocksize=$[1024+512] --random 1.5MiB 2.08M/s 6.07M/s 2.25M/s 6.71M/s 3.87M/s 6.07M/s 768KiB 2.18M/s 2.27M/s 5.04M/s 2.22M/s 2.14M/s 1.28M/s 384KiB 2.3M/s 2.32M/s 2.22M/s 2.27M/s 2.32M/s 2.32M/s 192KiB 1.31M/s 2.34M/s 2.38M/s 1.3M/s 1.3M/s 2.33M/s 96KiB 1.31M/s 2.39M/s 2.38M/s 1.32M/s 1.3M/s 1.33M/s 48KiB 1.29M/s 2.31M/s 2.26M/s 1.3M/s 2.31M/s 1.29M/s 24KiB 1.17M/s 1.16M/s 1.17M/s 1.16M/s 1.17M/s 830K/s 12KiB 714K/s 714K/s 712K/s 708K/s 716K/s 710K/s 6KiB 398K/s 399K/s 399K/s 397K/s 397K/s 348K/s 3KiB 210K/s 212K/s 212K/s 211K/s 214K/s 200K/s 1.5KiB 111K/s 107K/s 112K/s 117K/s 114K/s 109K/s
peter