NOTICE: The Processors Wiki will End-of-Life on January 15, 2021. It is recommended to download any files or other content you may need that are hosted on processors.wiki.ti.com. The site is now set to read only.

Visualizing Common Platform Tracer Data On The Keystone Architecture

From Texas Instruments Wiki
Jump to: navigation, search

Introduction[edit]

System Trace (STM) is a System Analysis Tool provided on the Keystone Architecture for capture and visualization of system level behavior on a Multicore SOC. One part of System Trace is the implementation of Common Platform Tracers (CP Tracers) on various slave interfaces within the system. The CP Tracer is simply a piece of logic that can capture statistics about the behavior of these interfaces and periodically export those statistics out through the System Trace stream.


There are essentially two steps to this process, and this article will detail both. The first process is configuring the device and receiver to generate and capture the trace data. The second process is being able to visualize that data in a graphical form once it has been captured. The resulting graph will look similar to the one contained in the image labeled "Sample CP Tracer Output"


In the graphical output, each color represents a different statistic, such as Bus Bandwidth or Average Latency. The horizontal axis represents a cycle accurate time sequence. It is through this image that we can observe where in our application there may be bottlenecks or contention issues. Using an iterative process, we can make changes the the application and regenerate these images to reduce or eliminate them.

CPTCCS CorePac1L2.png
Sample CP Tracer Output

CP Tracer - Types of Statistics[edit]

The CP Tracers can be used for both profiling and event logging statistics.

  • Profiling
    • Throughput Counter - Bytes of slave acknowledged accesses from the masters
    • Wait Counter - Cycles a master has waited for slave acknowledges
    • Access Counter - Count of unique transaction requests
  • Event Logging
    • New Requests
    • Last Read
    • Last Write

Requirements[edit]

In order to reproduce similar results on your own system, you will need the following. The revisions of tools in the generation of this data are recorded in parenthesis. Older revisions of the tools may work, but the results are not guaranteed.

Software Requirements[edit]

  • Code Composer Studio v5.1 (5.1.1.00031)

Hardware Requirements[edit]

  • Keystone EVM or Development Board
  • Emulation Requirements
    • If the target of the trace data will be an external emulator's large trace buffer, the following are required.
      • External Emulator supporting System trace (such as the Spectrum Digital XDS560v2, Blackhawk XDS560v2 System Trace. If a Keystone EVM is being used, the Blackhawk XDS560v2 Mezzanine Emulator will also suffice.)
      • An appropriate trace header must also be implemented on the target. This would be a 20-pin or 60-pin header with the System Trace EMU pins connected.
    • If the target of the trace data will be the on-chip, system level Embedded Trace Buffer '(ETB)', the following is required.
      • An XDS560 generation of external emulator.
      • Any JTAG emulator connection to the target will work (14-pin, 20-pin or 60-pin)

Instructions[edit]

Application Overview[edit]

This example will attempt to visualize activity on the DDR3 interface. Any application that uses DDR3 can be used to generate the visualization. If you wish to use an application that does not use DDR3, you can select a different slave interface when the Trace job is configured within the breakpoint manager.

Steps[edit]

  • Configure your Trace System for System Trace capture from within Code Composer Studio. For details on how to achieve this, see Configuring System Trace In Code Composer Studio
  • Load the application you are running into the appropriate cores.
  • Configure the System Trace job
    • The Job is configured from within the Breakpoint Manager. Open the breakpoint manager if it is not already visible (In the Debug Perspective, View->Breakpoints)
    • Ensure that the CSSTM Node is selected in the Debug Window and then,in the breakpoint drop down box, choose "Trace" as shown in the image titled "New CPT Trace Job".
    • A new entry will be visible in the breakpoint window (likely named "Trace"). Right click it, and select Breakpoint Properties. A dialog should open that looks similar to the one in the image labeled "Breakpoint Properties". Expand the tree to see options at the various levels.
    • Configure the properties as detailed in the CP Tracer Job Properties section below. Any values that aren't specified can be left at the defaults.
  • Hardware Configuration
    • Type - Trace
      • STM Trace Type - CP_Tracer
        • Transaction Monitor - DDR3 (choose this based on the interface you are intending to gather statistics from. We are looking at DDR3 bandwidth)
        • Function - Transaction Statistics
          • Statistics Type
            • Bandwidth Type - Total Bandwidth Profile
            • Average Access Size - true
            • Average Access Rate - true
            • Percentage Wait Time - true
            • Average Latency - true
            • Transaction Master
              • GEM - true (all others false)
            • Address Range Filter - false
            • EMU Trigger Filter - false
            • Sample Window - 65535
            • Display Settings
              • Clock Rate (MHz) - 1000 (set this to your target clock speed)
              • Suppress Zeros - true
  • Miscellaneous
    • Group -Default Group
    • Name - DDR3 Total Bandwidth Profile
  • Click the OK Button in the Breakpoint Properties window
  • Enable the Breakpoint by checking it in the breakpoint list.
  • Capture the Data
    • Open the Trace Data View (Tools->Trace Analyzer->Open Trace Connection in New View-><Your Emulator Name>/CSSTM_0). A grid view should open.
    • Run the application on all cores. At this point, the data will be captured to the trace buffer until either the buffer gets filled, or all of the targets halt. The user can initiate a halt to do this, or if the sample application ends it will halt automatically at the exit point.
    • Once the application is halted, or the buffer is filled, the data will automatically be displayed in the trace window after a few seconds.
  • Convert captured data into a visualized form with System Analyzer
    • With the grid trace window selected, choose Tools->Trace Analyzer->Analysis->STM Analysis->STM Analysis Graph. A new, graphical window will open that will show the data in graphical form.
CCS5.1 New CPT Job.png
New CPT Trace Job
CCS5.1 CPT BreakpointProperties.png
Breakpoint Properties

Results[edit]

The resulting image will show 6 pieces of information. Each is encoded in a different color. The pieces of data are:

  • Bus Bandiwth (MBytes/second)
  • Average Access Size (Bytes/cycle)
  • Bus Utilization (Millions of Transactions/second)
  • Bus Contention %
  • Average Latency (Transactions/cycle)
  • Bus Throughput %


From within the graphical view, you can zoom in and out to see more fine details of the image. This may be necessary in some cases, because the view will automatically scale to the largest value. It also may be necessary to zoom out on the horizontal scale to see all of the data that was gathered.

Relevant Links[edit]

E2e.jpg {{
  1. switchcategory:MultiCore=
  • For technical support on MultiCore devices, please post your questions in the C6000 MultiCore Forum
  • For questions related to the BIOS MultiCore SDK (MCSDK), please use the BIOS Forum

Please post only comments related to the article Visualizing Common Platform Tracer Data On The Keystone Architecture here.

Keystone=
  • For technical support on MultiCore devices, please post your questions in the C6000 MultiCore Forum
  • For questions related to the BIOS MultiCore SDK (MCSDK), please use the BIOS Forum

Please post only comments related to the article Visualizing Common Platform Tracer Data On The Keystone Architecture here.

C2000=For technical support on the C2000 please post your questions on The C2000 Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. DaVinci=For technical support on DaVincoplease post your questions on The DaVinci Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. MSP430=For technical support on MSP430 please post your questions on The MSP430 Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. OMAP35x=For technical support on OMAP please post your questions on The OMAP Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. OMAPL1=For technical support on OMAP please post your questions on The OMAP Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. MAVRK=For technical support on MAVRK please post your questions on The MAVRK Toolbox Forum. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here. For technical support please post your questions at http://e2e.ti.com. Please post only comments about the article Visualizing Common Platform Tracer Data On The Keystone Architecture here.

}}

Hyperlink blue.png Links

Amplifiers & Linear
Audio
Broadband RF/IF & Digital Radio
Clocks & Timers
Data Converters

DLP & MEMS
High-Reliability
Interface
Logic
Power Management

Processors

Switches & Multiplexers
Temperature Sensors & Control ICs
Wireless Connectivity