[PATCH 0/2] Android: traces in writable location by default

Alexander Monakov amonakov at ispras.ru
Mon Jul 1 23:38:07 PDT 2013


Hello,

This is a couple of small fixups that hopefully makes life of future users of
Apitrace on Android easier.

On Android, we are almost always interested in the actual process title rather
than path to the VM kick-off executable (/system/bin/app_process), so the
first patch switches os::getProcessName to accomodate for that.  The second
patch uses that to easily place traces into a sane location.

As a followup work, it makes sense to explicitely separate the notions of
'path to the executable' and 'current process title' in the internal API.
Right now those are smashed together in os::getProcessName, while different
uses are actually more interested in one or the other.  Comments?

I'm also interested in getting rid of using 'debug.apitrace.procname' property
on Android.  It is no longer required since 'wrap.$procname' is documented.
For pre-4.0 Android, I wonder if substituting /system/bin/app_process with a
shell script that sets LD_PRELOAD would work.  If so, it would make a lot of
sense to introduce an environment variable that allows to limit tracing to a
specific process title (thus, similar to the effect of
debug.apitrace.procname, but platform-agnostic).

Alexander


More information about the apitrace mailing list