summaryrefslogtreecommitdiffstats
path: root/src/testlib/qbenchmarkperfevents_p.h
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2012-04-09 14:11:47 -0300
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-03-06 21:50:28 +0100
commitc63420a117fe67107466d806890e901d091cb1d5 (patch)
tree63c706a5d6b50f9efcb0db95c1ec80f99432b7d8 /src/testlib/qbenchmarkperfevents_p.h
parent9d72259f943a3b31fa4e32aeb1c5a2de3d8ca611 (diff)
Implement the Linux Perf Counter backend for benchlib
Currently, we only support one event type: counting CPU cycles with hardware counters. There are no fallbacks if this hardware counter is not available, and there is currently no way to specify other counters. Benchlib only supports reporting one event per benchmark, even though the event counter interface allows specifying more than one. Still, the hardware usually has limitations on how many events it can monitor at a time, and we'd prefer to have the counter running at 100% of the time, so this will not change. Change-Id: I79858a3ad1e696dc4b7b72c420e5a04b67cd55de Reviewed-by: Jason McDonald <macadder1@gmail.com>
Diffstat (limited to 'src/testlib/qbenchmarkperfevents_p.h')
-rw-r--r--src/testlib/qbenchmarkperfevents_p.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/testlib/qbenchmarkperfevents_p.h b/src/testlib/qbenchmarkperfevents_p.h
index 19e68aebc3..74966e1699 100644
--- a/src/testlib/qbenchmarkperfevents_p.h
+++ b/src/testlib/qbenchmarkperfevents_p.h
@@ -75,6 +75,9 @@ public:
static bool isAvailable();
private:
+ int fd;
+
+ qint64 readValue();
};
QT_END_NAMESPACE