Get Started with Energy Analysis

ID 767270
Date 3/31/2023
Public

Get Started with Energy Analysis

Energy Analysis with Intel® SoC Watch

Use Intel® SoC Watch to perform energy analysis on a Linux*, Windows*, or Android* system running on Intel® architecture. Study power consumption in the system and identify behaviors that waste energy. Intel SoC Watch generates a summary text report or you can import results into Intel® VTune™ Profiler.

Get the Tools

Intel® SoC Watch is available in VTune Profiler, which you can download with the Intel® oneAPI Base Toolkit.

Workflows

You perform energy analysis by examining a summary report of data collected on the target system. See if the system is using energy-efficient, low power states. If results are not optimal, you may need additional examination of the data on a timeline as well as correlating metrics to determine a cause.

There are two workflows for energy analysis:

Workflow

Description

Benefit

Option 1: Command line collection on target system

  1. Collect data using Intel® SoC Watch (command line application) on a Windows, Android, or Linux OS target system.
  2. View a text (CSV-formatted) summary report.
  • View the report immediately on the target system.
  • Run additional collections based on your observations.
  • You do not need to copy result files to a host unless you need a detailed examination of data over time.

Option 2: GUI-based collection on target system

  1. Collect data using Intel® SoC Watch (command line application) on a Windows, Android, or Linux OS target system.
  2. Generate an export file for Intel® VTune™ Profiler.
  3. Copy the export file to the host system.
  4. Import the results into Intel® VTune™ Profiler.
  • Use zoom and filter features in the Intel® VTune™ Profiler graphical user interface to examine data over time and correlate across metrics.

The next few sections describe the steps involved in Option 1 to perform data collection on a target system using Intel SoC Watch.

Step 1: Install Intel SoC Watch on Target System

The Installation section of the Intel SoC Watch Release Notes (for your preferred target operating system) contains detailed instructions for instruction and configuration (if necessary).

Download Intel® oneAPI Base Toolkit and install Intel® VTune™ Profiler, which contains Intel SoC Watch.

The Installation section of the Intel SoC Watch Release Notes (for your preferred target operating system) contains detailed instructions for instruction and configuration (if necessary).

Find release notes and an OS-specific user guide in the documentation\en\socwatch directory after you install Intel® VTune™ Profiler.

Step 2: Collect Data

  1. Open a command prompt with administrative/root privileges on the target system where Intel SoC Watch was installed.

  2. Enter the command below to capture CPU time in low power states over a 60-second period.

    socwatch -t 60 -f cpu-cstate -m -o results/test

Step 3: View Results

When collection completes, a message appears with the location of the result files. In this example, the summary report is located in the current directory in the results/test.csv file.

  1. Open the test.csv file using a spreadsheet viewer (such as Microsoft Excel*) or a text viewer (such as vi/vim or Microsoft Wordpad*).

    NOTE:

    Some text viewers give better column alignment than others.

  2. Review the tables in the report file. A partial set of tables is shown in the example report below.

Example report:

Example report interpretation: When reading C-State tables, a higher C-State number means lower power consumption. C0 indicates high energy consumption and C7 or C10 is the lowest energy consumption. Looking at the table in the example report, the system spent 93.65% of the collection time in the package-level C2 state while the cores were in C7, their lowest state. An area for further exploration would be what prevented the package from going into its lowest energy state.

Next Steps

After running a basic collection on a target system, consider one of these steps:

  • Learn about additional data that you can collect on the target system. Run the help command: socwatch -h. The Intel SoC Watch User's Guide has a list of all provided metrics. Some metrics may not be supported on your platform.

  • Define a scenario you want to analyze for energy use. For example:

    • System idle scenario, where the system is not in use during the collection time and is expected to drop its energy use to the lowest possible. Use a longer collection period (several minutes) to give the system time to transition to deep sleep or hibernation.

    • Active workload, such as video or audio playback. Start both an activity and collection for a predetermined time or let the collection run until manually stopped. Use the help command to learn about Intel SoC Watch options that allow launching a workload, delaying a collection start, and running for indefinite time.

  • Generate a trace file (*.pwr) to import and view in Intel® VTune™ Profiler. Add the -r vtune option to the command line. For more information, see https://software.intel.com/en-us/energy-analysis-user-guide-intel-energy-analysis.

Additional Resources

Resource

Description

Intel SoC Watch User's Guide: Android and Linux | Windows

The Intel SoC Watch User's Guide is a reference manual with explanations of all command line options and features as well as example reports.

The guide is available in the documentation\en\socwatch directory after you install Intel® VTune™ Profiler. You can also obtain a copy from the the oneAPI documentation library.

Intel SoC Watch Release Notes

The Intel SoC Watch Release Notes contain the most up-to-date information about the product, including a product description, technical support, and known limitations and issues for a particular operating system. This document also contains system requirements for installing the product.

See the documentation\en\socwatch directory after you install Intel® VTune™ Profiler or download from the oneAPI documentation library.

Energy Analysis Help

The energy analysis help provides basic information about running a collection. It also includes information about how to view and analyze the results with Intel® VTune™ Profiler.

Intel SoC Watch command line help

You can access general help for the Intel SoC Watch command line interface by entering this command:

socwatch -h

Legal Information

Intel, the Intel logo, Intel Atom, Intel Core, Intel Xeon Phi, VTune and Xeon are trademarks of Intel Corporation in the U.S. and/or other countries.

*Other names and brands may be claimed as the property of others.

Microsoft, Windows, and the Windows logo are trademarks, or registered trademarks of Microsoft Corporation in the United States and/or other countries.

Copyright © Intel Corporation.

This software and the related documents are Intel copyrighted materials, and your use of them is governed by the express license under which they were provided to you (License). Unless the License provides otherwise, you may not use, modify, copy, publish, distribute, disclose or transmit this software or the related documents without Intel's prior written permission.

This software and the related documents are provided as is, with no express or implied warranties, other than those that are expressly stated in the License.