B2G
B2G copied to clipboard
Port linux |perf| userspace tool to android
In the long term, this is a better profiler to invest in than oprofile. It's not known yet what needs to be done to get it running in the android userspace.
CC @shianyow
With good oprofile support this isn't on the critical path anymore, but might be nice to have.
perf depends on libelf. In original android build, libelf is only for host programs and its config is generated for host linux. libelf host build therefore depends on gettext and libintl.h, which is not available in bionic for certain. To port libelf to arm target, we will have to fork external/elfutils and find some way two different config.h for two different platforms.
I managed to build libelf for target device, but could go any step further. Perf highly depends on glibc extensions, symbols or the like. There is even a check rule for gnu/libc-version.h inside its Makefile. There are still tons of errors after some dirty hack to pass perf config process. Work done for build target libelf is available in gitorious.