User Guide

Contents

Set Up Android* System

When using the
VTune
Profiler
to collect data remotely on a target Android device, make sure to:
Optionally, do the following:
  • To view functions within Android-supplied system libraries, device drivers, or the kernel, get access from the host development system to the exact version of these binaries with symbols not stripped.
  • To view sources within Android-supplied system libraries, device drivers, or the kernel, get access from the host development system to the sources for these components.

Configure an Android Device for Analysis

To configure your Android device, do the following:
  1. Allow Debug connections to enable adb access:
    1. Select
      Settings
      >
      About <
      device
      >
      .
    2. Tap
      Build number
      seven times to enable the
      Developer Options
      tab.
    3. Select the
      Settings
      >
      Developer Options
      and enable the
      USB debugging
      option.
    Path to the
    Developer Options
    may vary depending on the manufacture of your device and system version.
  2. Enable
    Unknown Sources
    to install the
    VTune
    Profiler
    Android package without Google* Play. To do this, select
    Settings
    >
    Security
    and enable the
    Unknown Sources
    option.

Gain ADB Access to an Android Device

VTune
Profiler
collector for Android requires connectivity to the Android device via adb. Typically Android devices are connected to the host via USB. If it is difficult or impossible to get adb access to a device over USB, you may get adb over Ethernet or WiFi. To connect ADB over Ethernet or WiFi, first connect to Ethernet or connect to a WiFi access point and then do the following:
  1. Find the IP Address of the target. The IP address is available in Android for Ethernet via
    Settings>Wireless&Networks>Ethernet>IP Address
    or for Wi-Fi via
    Settings>Wireless&Networks>Wi-Fi><
    Connected Access Point
    >>IP Address
    .
  2. Make sure adb is enabled on the target device. If not enabled, go to Terminal App (of your choice) on the device and type:
    > su > setprop service.adb.tcp.port 5555 > stop adbd > start adbd
  3. Connect adb on the host to the remote device. In the Command Prompt or the Terminal on the host, type:
    > adb connect <IPAddres>:5555

Gain a Root Mode ADB Access to the Android Device

For performance analysis on Android platforms, you typically need a root mode adb access to your device to:
  • Install and load drivers needed for hardware event-based sampling.
  • Enable the Android device to support Java* analysis.
  • Run hardware event-based sampling analysis.
There are several analysis types on Android systems that do NOT require root privileges such as Hotspots Analysis (
user-mode sampling
mode) and Perf*-based driverless sampling event-based collection.
Depending on the build, you gain root mode adb access differently:
  • User/Production builds
    : Gaining root mode adb access to a user build of the Android OS is difficult and different for various devices. Contact your manufacturer for how to do this.
  • Engineering builds
    : Root-mode adb access is the default for engineering builds. Engineering builds of the Android OS are by their nature not "optimized". Using the
    VTune
    Profiler
    against an engineering build is likely to result in
    VTune
    Profiler
    identifying code to optimize which is already optimized in user and userdebug builds.
  • Userdebug builds
    : Userdebug builds of the Android OS offer a compromise between good results and easy-to-run tools. By default, userdebug builds run adb in user mode.
    VTune
    Profiler
    tools require root mode access to the device, which you can gain via typing
    adb root
    on the host. These instructions are based on userdebug builds.

Use the Pre-installed Drivers on the Target Android System

For hardware event-based sampling analysis, the
VTune
Profiler
needs sampling drivers to be installed. On some versions of Android systems, including most of the Intel supplied reference builds for SDVs, the following drivers are pre-installed in
/lib/modules
or
/system/lib/modules
:
  • Hardware event-based analysis collectors:
    • socperf2_
      x
      .ko
    • pax.ko
    • sep3_
      x
      .ko
    • sep4_
      x
      .ko
    • vtsspp.ko
Typically having pre-installed drivers is more convenient. You can check for pre-installed drivers by typing:
adb shell ls
[/lib/modules|/system/lib/modules]
If the drivers are not available or the version does not match requirements, consider building and installing the drivers.

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804