From: Richard Henderson <rth@twiddle.net>
To: qemu-devel@nongnu.orgqemu-devel@nongnu.org
Cc: blauwirbel@gmail.com
Subject: [Qemu-devel] [PATCH 3/3] Fix --enable-profiler compilation.
Date: Fri, 16 Apr 2010 09:50:44 -0500 [thread overview]
Message-ID: <1271429444-900-3-git-send-email-rth@twiddle.net> (raw)
In-Reply-To: <1271429444-900-2-git-send-email-rth@twiddle.net>
There's a header file inclusion ordering problem between cpu-all.h
and qemu-timer.h, such that cpu_get_real_ticks is not defined when
we attempt to use it in profile_getclock.
Signed-off-by: Richard Henderson <rth@twiddle.net>
---
cpu-all.h | 12 ------------
qemu-timer.h | 11 +++++++++++
tcg/tcg.c | 1 +
3 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/cpu-all.h b/cpu-all.h
index 3004d0f..7b1594c 100644
--- a/cpu-all.h
+++ b/cpu-all.h
@@ -943,18 +943,6 @@ void dump_exec_info(FILE *f,
int cpu_memory_rw_debug(CPUState *env, target_ulong addr,
uint8_t *buf, int len, int is_write);
-/* profiling */
-#ifdef CONFIG_PROFILER
-static inline int64_t profile_getclock(void)
-{
- return cpu_get_real_ticks();
-}
-
-extern int64_t qemu_time, qemu_time_start;
-extern int64_t tlb_flush_time;
-extern int64_t dev_time;
-#endif
-
void cpu_inject_x86_mce(CPUState *cenv, int bank, uint64_t status,
uint64_t mcg_status, uint64_t addr, uint64_t misc);
diff --git a/qemu-timer.h b/qemu-timer.h
index d2e15f4..62da887 100644
--- a/qemu-timer.h
+++ b/qemu-timer.h
@@ -236,4 +236,15 @@ static inline int can_do_io(CPUState *env)
}
#endif
+#ifdef CONFIG_PROFILER
+static inline int64_t profile_getclock(void)
+{
+ return cpu_get_real_ticks();
+}
+
+extern int64_t qemu_time, qemu_time_start;
+extern int64_t tlb_flush_time;
+extern int64_t dev_time;
+#endif
+
#endif
diff --git a/tcg/tcg.c b/tcg/tcg.c
index 3294743..2261482 100644
--- a/tcg/tcg.c
+++ b/tcg/tcg.c
@@ -47,6 +47,7 @@
#include "qemu-common.h"
#include "cache-utils.h"
#include "host-utils.h"
+#include "qemu-timer.h"
/* Note: the long term plan is to reduce the dependancies on the QEMU
CPU definitions. Currently they are used for qemu_ld/st
--
1.6.6.1
next prev parent reply other threads:[~2010-04-16 14:51 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-16 14:50 [Qemu-devel] [PATCH 1/3] target-sparc: Fix TARGET_{PHYS, VIRT}_ADDR_SPACE_BITS Richard Henderson
2010-04-16 14:50 ` [Qemu-devel] [PATCH 2/3] target-sparc: Free instruction temporaries Richard Henderson
2010-04-16 14:50 ` Richard Henderson [this message]
2010-04-17 16:41 ` [Qemu-devel] " Blue Swirl
2010-04-17 17:49 ` Richard Henderson
2010-04-17 18:00 ` Richard Henderson
2010-04-17 18:50 ` Blue Swirl
2010-04-17 18:41 ` Blue Swirl
2010-04-18 15:02 ` Richard Henderson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1271429444-900-3-git-send-email-rth@twiddle.net \
--to=rth@twiddle.net \
--cc=blauwirbel@gmail.com \
--cc=qemu-devel@nongnu.orgqemu-devel \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).