Capture a Streamline profile

Performance Advisor runs on a Streamline capture file. You need to take a capture with Streamline first, before you can generate a report with Performance Advisor. In your Arm Mobile Studio installation directory, there is a Python script, that connects Streamline to your device and directs you to take a capture. The script will temporarily install a daemon application on your device, called gatord. This application is provided in your Arm Mobile Studio installation directory.

  1. In a terminal window, navigate to the following folder in your Arm Mobile Studio installation directory, where the Python script is located:
    cd <installation_directory>/performance_advisor/lwi/helpers/
  2. The syntax to run the script is:
    python3 --daemon <path_to_gatord> [--lwi-gles-layer-lib-path | --lwi-vk-layer-lib-path <path_to_Android10_layer_lib>]
    Use the --daemon option to specify the path to the gatord binary that you want to install on your device to collect data. This file is provided in your installation directory in two versions:

    For 32-bit applications, use <install_directory>/streamline/bin/arm/gatord. For 64-bit applications, use <install_directory>/streamline/bin/arm64/gatord.
    For Android 10, use --lwi-gles-layer-lib-path or --lwi-vk-layer-lib-path to specify the path to the OpenGL ES or Vulkan layer library file for Android 10 devices. These files are provided in your installation directory. Libraries for both 32-bit and 64-bit applications are stored in different folders; armeabi-v7a for 32-bit applications, and arm64-v8a for 64-bit applications.

    The Open GL ES layer library file is located in: <install_directory>/ performance_advisor/lwi/target/android/arm/unrooted/{arm64-v8a|armeabi-v7a}/

    The Vulkan layer library file is located in: <install_directory>/ performance_advisor/lwi/target/android/arm/rooted//{arm64-v8a|armeabi-v7a}/

    For example, to run the script for a 64-bit OpenGL ES application on an Android 10 device:
    python3 --daemon ../../../streamline/bin/arm64/gatord --lwi-gles-layer-lib-path ../target/android/arm/unrooted/arm64-v8a/ 
  3. The script returns a numbered list of the Android package names for the debuggable applications that are installed on your device. Enter the number of the package you want to profile.

    The script identifies the GPU in the device, installs the daemon application, and waits for you to complete the capture in Streamline. Leave the terminal window open, as you will need to come back to it later to terminate the script.

  4. Launch Streamline:
    1. On Windows, from the Start menu, navigate to Arm MS 2020.2 and select Arm MS Streamline 2020.2.
    2. On macOS, go to the <install_directory>/streamline folder, and double-click the file.
    3. On Linux, navigate to the <install_directory>/streamline directory in a terminal, and run the Streamline file:
      cd <install_directory>/streamline 
  5. Use the Start tab in Streamline to select your device. Select Or, choose an existing target, then select your device from the list.
    Connect to your device in Streamline
  6. Open the Counter configuration dialog by selecting Configure Counters.
    Streamline's configure counters button
  7. Choose Add counters from a template Add counters from a template button and select an appropriate counter template for the GPU in your device.
    The number of counters in the template that your target device supports is shown next to each template. For example, here, 34 of the 38 available counters in the Mali Midgard template are supported in the connected device.
  8. Save your selection.
  9. Optionally, select Advanced Settings, to set additional capture options, including the sample rate and the capture duration.
    Streamline's advanced settings button
    Refer to Capture options in the Arm Streamline User Guide for more details..
  10. Select Start Capture.
    Streamline start capture button
  11. Specify the name and location of the capture file that Streamline will create when the capture is complete. Streamline then switches to Live view and waits for you to start the application on the device.
  12. Start the application on the device and perform your test scenario.
  13. Unless you specified a capture duration, click Stop capture to end the capture . Streamline stores the capture file in the location you specified.
  14. IMPORTANT: Switch back to the terminal running the script and press any key to terminate it. The script kills all processes that it started and remove the daemon application from the device.

Now that you have a Streamline capture, run Performance Advisor on it, to generate a performance report

Previous Next