Re: [PATCH 2/3] perf tools: parse the pmu event prefix and surfix

2014-08-22 Thread Andi Kleen
> +/* The contents of the pmu_events should be in ascending sorted by symbol*/ > +static struct pmu_event_symbol pmu_events[] = { > + { "abort", false}, > + { "capacity", false}, > + { "commit", false}, > + { "conflict", false}, > + { "el", true}, > + { "start", false}, > +

[PATCH 2/3] perf tools: parse the pmu event prefix and surfix

2014-08-22 Thread kan . liang
From: Kan Liang There are two types of event formats for PMU events. E.g. el-abort OR cpu/el-abort/. However, the lexer mistakenly recognizes the simple style format as two events. The newly introduced function uses bsearch to search the name in known pmu event list. It can tell the lexer that

[PATCH 2/3] perf tools: parse the pmu event prefix and surfix

2014-08-22 Thread kan . liang
From: Kan Liang kan.li...@intel.com There are two types of event formats for PMU events. E.g. el-abort OR cpu/el-abort/. However, the lexer mistakenly recognizes the simple style format as two events. The newly introduced function uses bsearch to search the name in known pmu event list. It can

Re: [PATCH 2/3] perf tools: parse the pmu event prefix and surfix

2014-08-22 Thread Andi Kleen
+/* The contents of the pmu_events should be in ascending sorted by symbol*/ +static struct pmu_event_symbol pmu_events[] = { + { abort, false}, + { capacity, false}, + { commit, false}, + { conflict, false}, + { el, true}, + { start, false}, + { tx, true},