Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 154618
b: refs/heads/master
c: c0c22db
h: refs/heads/master
v: v3
  • Loading branch information
Jaswinder Singh Rajput authored and Ingo Molnar committed Jun 22, 2009
1 parent beddd6c commit 0e8deb4
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 520f2c346af463fa00924b236e092da482b344cc
refs/heads/master: c0c22dbfa8ba3c5045eeb9c76d2822ffc44fefc3
36 changes: 18 additions & 18 deletions trunk/tools/perf/util/parse-events.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,7 @@ static struct event_symbol event_symbols[] = {

{ CSW(CPU_CLOCK), "cpu-clock", "" },
{ CSW(TASK_CLOCK), "task-clock", "" },
{ CSW(PAGE_FAULTS), "page-faults", "" },
{ CSW(PAGE_FAULTS), "faults", "" },
{ CSW(PAGE_FAULTS), "page-faults", "faults" },
{ CSW(PAGE_FAULTS_MIN), "minor-faults", "" },
{ CSW(PAGE_FAULTS_MAJ), "major-faults", "" },
{ CSW(CONTEXT_SWITCHES), "context-switches", "cs" },
Expand Down Expand Up @@ -71,24 +70,24 @@ static char *sw_event_names[] = {

#define MAX_ALIASES 8

static char *hw_cache [][MAX_ALIASES] = {
{ "L1-data" , "l1-d", "l1d" },
{ "L1-instruction" , "l1-i", "l1i" },
{ "L2" , "l2" },
{ "Data-TLB" , "dtlb", "d-tlb" },
{ "Instruction-TLB" , "itlb", "i-tlb" },
{ "Branch" , "bpu" , "btb", "bpc" },
static char *hw_cache[][MAX_ALIASES] = {
{ "L1-data", "l1-d", "l1d" },
{ "L1-instruction", "l1-i", "l1i" },
{ "L2", "l2" },
{ "Data-TLB", "dtlb", "d-tlb" },
{ "Instruction-TLB", "itlb", "i-tlb" },
{ "Branch", "bpu" , "btb", "bpc" },
};

static char *hw_cache_op [][MAX_ALIASES] = {
{ "Load" , "read" },
{ "Store" , "write" },
{ "Prefetch" , "speculative-read", "speculative-load" },
static char *hw_cache_op[][MAX_ALIASES] = {
{ "Load", "read" },
{ "Store", "write" },
{ "Prefetch", "speculative-read", "speculative-load" },
};

static char *hw_cache_result [][MAX_ALIASES] = {
{ "Reference" , "ops", "access" },
{ "Miss" },
static char *hw_cache_result[][MAX_ALIASES] = {
{ "Reference", "ops", "access" },
{ "Miss" },
};

char *event_name(int counter)
Expand Down Expand Up @@ -160,7 +159,8 @@ static int parse_aliases(const char *str, char *names[][MAX_ALIASES], int size)
return -1;
}

static int parse_generic_hw_symbols(const char *str, struct perf_counter_attr *attr)
static int
parse_generic_hw_symbols(const char *str, struct perf_counter_attr *attr)
{
int cache_type = -1, cache_op = 0, cache_result = 0;

Expand Down Expand Up @@ -201,7 +201,7 @@ static int check_events(const char *str, unsigned int i)

if (strlen(event_symbols[i].alias))
if (!strncmp(str, event_symbols[i].alias,
strlen(event_symbols[i].alias)))
strlen(event_symbols[i].alias)))
return 1;
return 0;
}
Expand Down

0 comments on commit 0e8deb4

Please sign in to comment.