From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50766) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1agZSs-0007GY-1x for qemu-devel@nongnu.org; Thu, 17 Mar 2016 11:03:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1agZSn-0002JG-Ug for qemu-devel@nongnu.org; Thu, 17 Mar 2016 11:03:53 -0400 Received: from mail-lf0-x22c.google.com ([2a00:1450:4010:c07::22c]:35241) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1agZSn-0002IJ-N3 for qemu-devel@nongnu.org; Thu, 17 Mar 2016 11:03:49 -0400 Received: by mail-lf0-x22c.google.com with SMTP id v130so17454249lfd.2 for ; Thu, 17 Mar 2016 08:03:49 -0700 (PDT) References: <1458222382-6498-1-git-send-email-sergey.fedorov@linaro.org> <1458222382-6498-2-git-send-email-sergey.fedorov@linaro.org> From: Sergey Fedorov Message-ID: <56EAC752.3070600@gmail.com> Date: Thu, 17 Mar 2016 18:03:46 +0300 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 1/5] tcg: code_bitmap is not used by user-mode emulation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell , sergey.fedorov@linaro.org Cc: Paolo Bonzini , Peter Crosthwaite , QEMU Developers , Richard Henderson On 17/03/16 17:56, Peter Maydell wrote: > On 17 March 2016 at 13:46, wrote: >> From: Paolo Bonzini >> >> Signed-off-by: Paolo Bonzini >> Signed-off-by: Sergey Fedorov >> --- >> translate-all.c | 9 +++++++-- >> 1 file changed, 7 insertions(+), 2 deletions(-) >> >> diff --git a/translate-all.c b/translate-all.c >> index e9f409b762ab..f17ace1ae899 100644 >> --- a/translate-all.c >> +++ b/translate-all.c >> @@ -784,6 +784,9 @@ void tb_free(TranslationBlock *tb) >> >> static inline void invalidate_page_bitmap(PageDesc *p) >> { >> +#ifndef CONFIG_SOFTMMU >> + assert(p->code_bitmap == NULL); >> +#endif >> g_free(p->code_bitmap); >> p->code_bitmap = NULL; >> p->code_write_count = 0; >> @@ -1018,6 +1021,7 @@ void tb_phys_invalidate(TranslationBlock *tb, tb_page_addr_t page_addr) >> tcg_ctx.tb_ctx.tb_phys_invalidate_count++; >> } > You could pretty much take this another step and actually > make the field in the struct be only present ifdef CONFIG_SOFTMMU... Sonds a good idea. Kind regards, Sergey