Samsung Galaxy S4 Benchmarks?
I just bought two new Samsung Galaxy S4's and was initially pretty happy with the ability for full device encryption. Since it requires a 6 character alphanumeric password which also must become your unlock-pin, I'm less excited, since "unlocking your phone while driving" effectively becomes "texting while driving" and I don't wanna die.
My main question was how encrypting the device would impact utilization. I tried and failed to find benchmarks for this, so I decided to do my own. The only directory that I can write into, without rooting, seems to be /sdcard/, there is no sdcard in the device, so this is on-board memory. After running my tests, I question whether this folder actually gets encrypted.
For my testing, I used a set of scripts I've used in the past to test read/write speed on laptops while we were migrating from unencrypted drives to a mix of hardware and software encryption. They're very simple, basically read from /dev/zero to whatever size you want your file to be, then repeat by how many files you'd like to generate, the 1GB file maker looks like this:
#! /bin/bash
for inner in 0 1 2 3
do
dd if=/dev/zero of=./myfile$inner.dat bs=$(( 1024 * 1024 )) count=1000 &> /dev/null
done
(The reason for $inner is that my original scripts recurse into directories, so I have, say, $outer, which creates let's say 10 directories, then $inner, which creates however many more, and then inside that go the files named myfile$outer-$inner.dat. I did lots of testing for the laptop migration...)
The GS4's /bin/sh doesn't like braces, so no "for inner in {1..4}", and doesn't have /usr/bin/seq, so "for inner `seq 1 10000` is out too. You have to specify the range as I did above, that meant an all-inclusive list from 1-10000 for my first test. The tests were run using the time command to spit out the results after the run, like this:
time sh ./10kbfilemaker.sh
Regardless of my skepticism about whether this path is actually encrypted, I did actually waste a couple of hours here, so I might as well post the results:
GS4 - base | GS4 - crypto | Macbook | |
10,000 x 10kb files - Write | 3:31.57 | 3:26.59s | 41s |
10,000 x 10kb files - Read | 17.14s | 12.75s | 9.709s |
10 x 100MB files - Write | 36.10s | 12.75s | 17.806 |
10 x 100MB files - Read | 2:46.67s | 2:35.13 | 1:24.577 |
4 x 1GB files - Write | 2:21.02s | 2:39.26 | 1:13.599s |
4 x 1GB files - Read | 10:48.11s | 10:33.55 | 5:52.808 |
As skeptical as I am about whether /scdard/ gets encrypted when there's no card in the phone, it really doesn't matter, since there's no damn way I want an alphanumeric password to unlock my phone. I could easily do an 8 character numeric only, that's fine, but when you bring a full keyboard layout into it, I just don't want to drive and unlock. So screw that.
Maybe if I root my phone or find another place within / that will permit me to write, I'll run the test again and see if there's any difference.
- xrayspx's blog
- Log in to post comments
- 6641 reads