Wednesday, December 3, 2014

Android ART Runtime might not Benefit Apps Running Native Code

A recent experiment on the performance of Android apps Android indicates the ART runtime might not significantly benefit apps already running native code. The benchmark app Speaker Identifier computes MFCCs for voice recognition which are usually computation intensive for mobile devices and implementation in native code is a typical solution. Here are the resource usages derived from implementations in two stream processing toolkits, ESMS and StreamIt on Nexus 7 2013 w/ and w/o ART enabled. As is shown, the CPU utilization (CPU time / real time) w/ ART in contrast with Dalvik even increased slightly, implying the pre-compilation overhead, and 5MB more RSS (max. runtime memory) usage. Though, apps implemented and running mostly in Java should still gain performance improvements, developers working on native performance enhancement remain.

Setup
Nexus 7 2013, Android 4.4
Audio format: 44.1 KHz, MONO
Buffering: 0.04s
ESMS Dalvik
200.18 real, 29.49 user, 0.02 sys, 14.74% CPU
RSS: 26734592, Text: 0, Data: 0, Stack: 0
Page faults 0, reclaims: 135
Swaps: 0, Voluntary: 9848, Involuntary: 3049
ESMS ART
200.21 real, 28.97 user, 1.03 sys, 14.98% CPU
RSS: 31498240, Text: 0, Data: 0, Stack: 0
Page faults 0, reclaims: 118
Swaps: 0, Voluntary: 9844, Involuntary: 2475
StreamIt Dalvik 
200.23 real, 48.74 user, 1.01 sys, 24.85% CPU
RSS: 27365376, Text: 0, Data: 0, Stack: 0
Page faults 0, reclaims: 218
Swaps: 0, Voluntary: 9828, Involuntary: 3612
StreamIt ART
200.20 real, 51.46 user, 0.02 sys, 25.71% CPU
RSS: 32129024, Text: 0, Data: 0, Stack: 0
Page faults 0, reclaims: 200
Swaps: 0, Voluntary: 9828, Involuntary: 3230

No comments:

Post a Comment