SkiaBenchNumbers

Test libjpeg-turbo performance in Android

To test libjpeg-turbo performance you can use skia_bench tool provided with skia.

The command line to test jpeg decoding is:

skia_bench -repeat 10 -Ddecode-filename yourimage.jpg

The bench results are in Android log ($logcat -d) and look like this:

running bench [640 480] decode_XXXX_yourimage.jpg

8888: cmsecs = yyyy

565: cmsecs = yyyy

skia_bench log

By default skia_bench results output go in Android log.

If you want to change this, and for example, piut them into a file you have to configure Android log systeme with logcat command. The example below clean the log, redirect it to "/sdcard/skia_bench.log" and setup a filter in skia tag.

To have more detail about logcat: Android wiki page

logcat -c
logcat -f /sdcard/skia_bench.log skia:D *:S &
skia_bench -repeat 10 -Ddecode-filename /sdcard/yourimage.jpg

Results

Panda Linaro Android 4.0.3 ICS

skia_bench vanilla :

libjpeg
D/skia    ( 7865): running bench [640 480] decode_4444_LinaroBackground-1920x1080.jpg
D/skia    ( 7865):   8888: cmsecs = 2200.57
D/skia    ( 7865):    565: cmsecs = 2207.14
D/skia    ( 7865):
D/skia    ( 7865): running bench [640 480] decode_565_LinaroBackground-1920x1080.jpg
D/skia    ( 7865):   8888: cmsecs = 1880.90
D/skia    ( 7865):    565: cmsecs = 1889.09
D/skia    ( 7865):
D/skia    ( 7865): running bench [640 480] decode_8888_LinaroBackground-1920x1080.jpg
D/skia    ( 7865):   8888: cmsecs = 1936.54
D/skia    ( 7865):    565: cmsecs = 1925.06

skia-bench with libjpeg-turbo but without any 565 or 8888 optimizations.

libjpeg-turbo
D/skia    (  201): running bench [640 480] decode_4444_LinaroBackground-1920x1080.jpg
D/skia    (  201):   8888: cmsecs = 2274.25
D/skia    (  201):    565: cmsecs = 2288.28
D/skia    (  201): running bench [640 480] decode_565_LinaroBackground-1920x1080.jpg
D/skia    (  201):   8888: cmsecs = 2006.49
D/skia    (  201):    565: cmsecs = 2010.12
D/skia    (  201): running bench [640 480] decode_8888_LinaroBackground-1920x1080.jpg
D/skia    (  201):   8888: cmsecs = 2021.33
D/skia    (  201):    565: cmsecs = 2017.81

libjpeg-turbo -current prototype with 565 and 8888 optimizations

D/skia    ( 4587): running bench [640 480] decode_4444_LinaroBackground-1920x1080.jpg
D/skia    ( 4587):   8888: cmsecs = 1244.52
D/skia    ( 4587):    565: cmsecs = 1232.39
D/skia    ( 4587):
D/skia    ( 4587): running bench [640 480] decode_565_LinaroBackground-1920x1080.jpg
D/skia    ( 4587):   8888: cmsecs = 975.11
D/skia    ( 4587):    565: cmsecs = 960.59
D/skia    ( 4587):
D/skia    ( 4587): running bench [640 480] decode_8888_LinaroBackground-1920x1080.jpg
D/skia    ( 4587):   8888: cmsecs = 1121.99
D/skia    ( 4587):    565: cmsecs = 1147.37

TomGall/SkiaBenchNumbers (last edited 2012-06-19 13:54:59 by tom-gall)