Creating Custom Performance Counters - ARM DS-5 Manual

Hide thumbs Also See for DS-5:
Table of Contents

Advertisement

11.2

Creating custom performance counters

11.2.1
The gator_events_mmaped.c example file
ARM DUI 0482K
ID120712
In addition to the hardware-specific and Linux performance counters that you can configure
using the Counter Configuration dialog box, the gator daemon and driver provide hooks that
enable you to customize the counters collected during a capture.
Streamline derives its default set of counters from the performance monitoring unit, linux hooks,
and memory-mapped peripherals. You can add your own counters to this list if there is a
hardware metric that you want to track which Streamline does not provide by default.
In the
gator-driver.tar.gz
file called
gator_events_mmaped.c
file and do not appear in the list of available counters in the Counter Configuration
events.xml
dialog box. This file was provided as an example of how to add custom counters.
Note
You can locate all of the files provided by DS-5 by selecting Help → ARM Extras... from the
main menu.
To familiarize yourself with the process of adding your own counters, incorporate the simulated
examples from
gator_events_mmaped.c
To do so, follow these steps:
1.
Open the
gator_events_mmaped.c
2.
Copy the xml from the comments section of
3.
Open
. This file is only available after you have built the gator daemon. If you
events.xml
built your gator daemon for a Linux target, it is located in the
directory. If you built it for Android, it is located in the
4.
Add the copied xml from the comments section of
just after the closing tag of the Linux category.
5.
Remove any * comment markers from the copied xml.
6.
Save
.
events.xml
7.
Copy
to your target. You must place it in the same directory as
events.xml
8.
Enter
on the command line of your target to restart
./gatord &
9.
Open the Counter Configuration dialog in Streamline. Note that a new category,
mmaped, appears with the Sine, Triangle, and PWM simulated counters.
10.
Add Sine to list of counters.
11.
Run a capture session.
If successful, the waveform generated by the simulated Sine counter appears in the charts
section of the Timeline view.
Copyright © 2010-2012 ARM. All rights reserved.
Non-Confidential
archive distributed with your copy of Streamline is a gator source
. The events contained in this file are not included in the
into
.
gator
sample file in the editor of your choice.
gator_events_mmaped.c
Advanced Customizations
.
build_location/daemon-src
directory.
build_location/jni
to events.xml,
gator_events_mmaped.c
gatord
.
gatord
.
11-4

Advertisement

Table of Contents
loading

Table of Contents