From d5ab9713d2d4037fd56b0adddd26c8d4dc11cf09 Mon Sep 17 00:00:00 2001 From: Jan Kiszka Date: Tue, 2 Aug 2011 16:10:21 +0200 Subject: Avoid allocating TCG resources in non-TCG mode Do not allocate TCG-only resources like the translation buffer when running over KVM or XEN. Saves a "few" bytes in the qemu address space and is also conceptually cleaner. Signed-off-by: Jan Kiszka Signed-off-by: Anthony Liguori --- target-s390x/helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'target-s390x') diff --git a/target-s390x/helper.c b/target-s390x/helper.c index 1ce7079af7..443bb1d8d6 100644 --- a/target-s390x/helper.c +++ b/target-s390x/helper.c @@ -81,7 +81,7 @@ CPUS390XState *cpu_s390x_init(const char *cpu_model) env = qemu_mallocz(sizeof(CPUS390XState)); cpu_exec_init(env); - if (!inited) { + if (tcg_enabled() && !inited) { inited = 1; s390x_translate_init(); } -- cgit v1.2.1