[Flashbench] Results for Sandisk class 4 "SDHC card"
arnd at arndb.de
Fri Apr 8 14:56:12 UTC 2011
On Friday 08 April 2011, Sascha Silbe wrote:
> A more extensive set of tests (50 samples each for 1-16 open AUs, only
> EBS sized blocks) post-processed and plotted to show mean and standard
> deviation painted a different picture. For 1-3 open AUs there's "high"
> speed with high deviation; for 4-7 open AUs mean speed is a bit less
> with almost no deviation. There's a clear cut after 10 AUs (change in
> mean value greater than standard variation).
What you found is clearly interesting, but I fear you are going down
a much different route from what I'm normally looking at. Writing
a full erase block normally always gives the exact same performance,
because the card is not forced to do garbage collection.
It looks like the card actually does garbage collection, which could
hint that the erase block size is actually 3 MB (or possibly 4.5 MB,
though I have never seen such a strange value).
It's also possible that most erase blocks are 1.5 MB, but that every
64 MB it starts out with a 64 MB aligned block, which would coincide
with the 11th erase block in your test.
You can try doing a run with
flashbench --open-au --open-au-nr=3 --erasesize=1572864 --blocksize=393216
--offset=67108864 --random /dev/mmcblk0
to see if that is fast or slow. 67108864 is 64 MB, so it is not aligned
to multiples of 1.5 MB, while 67109376 is the next multiple that we
flashbench would normally try.
In either case, you really need the numbers for the smaller block sizes,
those will be much more interesting.
> Not sure why there's so much deviation for 1-3 open AUs; maybe doing a
> completely erase + fill cycle would give better numbers.
The deviation in these cases is probably based on what the previous
test run did: It takes longer to write one erase block when there is
need to garbage-collect another one.
> However I'd
> prefer to avoid that, because a) it would wear the card significantly
> (I don't expect it to survive more than 1k cycles)
Doing a high-level erase would only mark the erase blocks as free,
it does not actually age the drive. In fact, doing an erase after
each test run is a good idea.
> and b) the test
> would take two full days (for 10 samples each at 1-16 open AUs) during
> which I can use neither the card nor the card slot for anything else.
As mentioned before, the cards tend to be completely deterministic
as long with flashbench, as long as the assumptions are correct. If
you get any significant deviation between test runs, that means you
are not hitting the cases that flashbench was designed for.
More information about the Flashbench-results