diff options
author | Baruch Siach <baruch@tkos.co.il> | 2014-01-13 05:27:35 -0500 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2014-01-20 14:19:08 -0500 |
commit | 3a46817f674389d5fb2f4dce19fbc73ebd1976bb (patch) | |
tree | 7093c1017538e62dc40f33d602041830411925b2 /tools | |
parent | 8bac41cbfe2efe55e2b93673b84761ed7dd75f69 (diff) |
perf tools: Add support for the xtensa architecture
Tested using kernel tracepoints on a QEMU simulated environment.
Kernel support for perf depends on the patch "xtensa: enable
HAVE_PERF_EVENTS", which is scheduled for v3.14.
Hardware performance counters are not supported under xtensa yet.
Acked-by: Ingo Molnar <mingo@kernel.org>
Acked-by: Max Filippov <jcmvbkbc@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: linux-xtensa@linux-xtensa.org
Link: http://lkml.kernel.org/r/aafcdb22f04e2d3188d2938528939481be56b649.1389608855.git.baruch@tkos.co.il
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/perf/perf.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/perf/perf.h b/tools/perf/perf.h index 3c2f213e979d..7daa806d9050 100644 --- a/tools/perf/perf.h +++ b/tools/perf/perf.h | |||
@@ -132,6 +132,13 @@ | |||
132 | #define CPUINFO_PROC "CPU" | 132 | #define CPUINFO_PROC "CPU" |
133 | #endif | 133 | #endif |
134 | 134 | ||
135 | #ifdef __xtensa__ | ||
136 | #define mb() asm volatile("memw" ::: "memory") | ||
137 | #define wmb() asm volatile("memw" ::: "memory") | ||
138 | #define rmb() asm volatile("" ::: "memory") | ||
139 | #define CPUINFO_PROC "core ID" | ||
140 | #endif | ||
141 | |||
135 | #define barrier() asm volatile ("" ::: "memory") | 142 | #define barrier() asm volatile ("" ::: "memory") |
136 | 143 | ||
137 | #ifndef cpu_relax | 144 | #ifndef cpu_relax |