diff options
author | Richard Henderson <rth@twiddle.net> | 2010-05-06 08:50:41 -0700 |
---|---|---|
committer | Aurelien Jarno <aurelien@aurel32.net> | 2010-05-21 18:41:21 +0200 |
commit | 9002ec794e8154ff774270cf9fac5f850a1c5751 (patch) | |
tree | 2944aa4e144835c7e0da805cdb33252f4ea3749e /linux-user/main.c | |
parent | a5b3b13bedc545b5e571480b9cf47d2d378ad193 (diff) | |
download | qemu-9002ec794e8154ff774270cf9fac5f850a1c5751.tar.gz qemu-9002ec794e8154ff774270cf9fac5f850a1c5751.tar.bz2 qemu-9002ec794e8154ff774270cf9fac5f850a1c5751.zip |
tcg: Initialize the prologue after GUEST_BASE is fixed.
This will allow backends to make intelligent choices about how
to implement GUEST_BASE.
Signed-off-by: Richard Henderson <rth@twiddle.net>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Diffstat (limited to 'linux-user/main.c')
-rw-r--r-- | linux-user/main.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/linux-user/main.c b/linux-user/main.c index 5027a6d994..b240f290f7 100644 --- a/linux-user/main.c +++ b/linux-user/main.c @@ -31,7 +31,7 @@ #include "cache-utils.h" /* For tb_lock */ #include "exec-all.h" - +#include "tcg.h" #include "qemu-timer.h" #include "envlist.h" @@ -2984,6 +2984,13 @@ int main(int argc, char **argv, char **envp) syscall_init(); signal_init(); +#if defined(CONFIG_USE_GUEST_BASE) + /* Now that we've loaded the binary, GUEST_BASE is fixed. Delay + generating the prologue until now so that the prologue can take + the real value of GUEST_BASE into account. */ + tcg_prologue_init(&tcg_ctx); +#endif + #if defined(TARGET_I386) cpu_x86_set_cpl(env, 3); |