[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v11 05/14] accel/tcg: move profiler dev_time to tb_stats
From: |
Fei Wu |
Subject: |
[PATCH v11 05/14] accel/tcg: move profiler dev_time to tb_stats |
Date: |
Fri, 21 Apr 2023 21:24:12 +0800 |
From: Alex Bennée <alex.bennee@linaro.org>
This shouldn't live in the monitor code anyway. While we are at it
make it an uint64_t as we won't be dealing in negative numbers.
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
---
accel/tcg/monitor.c | 2 --
accel/tcg/tb-stats.c | 2 ++
include/qemu/timer.h | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/accel/tcg/monitor.c b/accel/tcg/monitor.c
index 1450e160e9..c9eec426ff 100644
--- a/accel/tcg/monitor.c
+++ b/accel/tcg/monitor.c
@@ -68,8 +68,6 @@ HumanReadableText *qmp_x_query_opcount(Error **errp)
#ifdef CONFIG_PROFILER
-int64_t dev_time;
-
HumanReadableText *qmp_x_query_profile(Error **errp)
{
g_autoptr(GString) buf = g_string_new("");
diff --git a/accel/tcg/tb-stats.c b/accel/tcg/tb-stats.c
index 434b235edb..a2438a1f51 100644
--- a/accel/tcg/tb-stats.c
+++ b/accel/tcg/tb-stats.c
@@ -28,6 +28,8 @@ enum TBStatsStatus {
static enum TBStatsStatus tcg_collect_tb_stats;
static uint32_t default_tbstats_flag;
+uint64_t dev_time;
+
struct jit_profile_info {
uint64_t translations;
uint64_t aborted;
diff --git a/include/qemu/timer.h b/include/qemu/timer.h
index ee071e07d1..d86fc73a17 100644
--- a/include/qemu/timer.h
+++ b/include/qemu/timer.h
@@ -995,7 +995,7 @@ static inline int64_t profile_getclock(void)
return get_clock();
}
-extern int64_t dev_time;
+extern uint64_t dev_time;
#endif
#endif
--
2.25.1
- [PATCH v11 00/14] TCG code quality tracking, Fei Wu, 2023/04/21
- [PATCH v11 01/14] accel/tcg: introduce TBStatistics structure, Fei Wu, 2023/04/21
- [PATCH v11 02/14] accel: collecting TB execution count, Fei Wu, 2023/04/21
- [PATCH v11 03/14] accel: collecting JIT statistics, Fei Wu, 2023/04/21
- [PATCH v11 04/14] accel: replacing part of CONFIG_PROFILER with TBStats, Fei Wu, 2023/04/21
- [PATCH v11 05/14] accel/tcg: move profiler dev_time to tb_stats,
Fei Wu <=
- [PATCH v11 06/14] accel/tcg: convert profiling of restore operations to TBStats, Fei Wu, 2023/04/21
- [PATCH v11 07/14] accel/tcg: convert profiling of code generation to TBStats, Fei Wu, 2023/04/21
- [PATCH v11 08/14] accel: adding TB_JIT_TIME and full replacing CONFIG_PROFILER, Fei Wu, 2023/04/21
- [PATCH v11 09/14] debug: add -d tb_stats to control TBStatistics collection:, Fei Wu, 2023/04/21
- [PATCH v11 10/14] monitor: adding tb_stats hmp command, Fei Wu, 2023/04/21
- [PATCH v11 11/14] tb-stats: reset the tracked TBs on a tb_flush, Fei Wu, 2023/04/21
- [PATCH v11 12/14] Adding info [tb-list|tb] commands to HMP (WIP), Fei Wu, 2023/04/21
- [PATCH v11 13/14] tb-stats: dump hot TBs at the end of the execution, Fei Wu, 2023/04/21
- [PATCH v11 14/14] configure: remove the final bits of --profiler support, Fei Wu, 2023/04/21