MiniTracing for ART
Make a directory and refer it as
$AOSP_HOMEfor later usage.
$ make AOSP_6.0.1_r77
Download AOSP, check out tag
android-6.0.1_r77. You can follow instructions at https://source.android.com/source/downloading
$ repo init -u https://android.googlesource.com/platform/manifest -b android-6.0.1_r77
$ cd $AOSP_HOME && mv art ../art-origin
Download MiniTracing for ART. Note the default branch is
$ git clone https://bitbucket.org/txgu/mini-tracing-art6 $AOSP_HOME/art
You can follow instructions at https://source.android.com/source/building
Source build env
$ source $AOSP_HOME/build/envsetup.sh
$ launch aosp_arm-eng
$ make libart libart-compiler -j 8
Known Tool chain bug: https://bbs.archlinux.org/viewtopic.php?id=209698
Flash the factory image 6.0.1-M4B30Z to you Nexus 5. You can download the image at https://developers.google.com/android/images#hammerhead.
Connect your phone to your computer. Your phone must be rooted first.
You probably need to read
Basically, you need first configure which app to be traced and than request the coverage harvest. I have provided a command to enable and disable tracing, and harvest data.