From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50711) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bHbKY-0000Ab-Gp for qemu-devel@nongnu.org; Mon, 27 Jun 2016 14:32:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bHbKU-0000uB-3V for qemu-devel@nongnu.org; Mon, 27 Jun 2016 14:32:21 -0400 Received: from mail-wm0-x243.google.com ([2a00:1450:400c:c09::243]:35042) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bHbKT-0000u7-T7 for qemu-devel@nongnu.org; Mon, 27 Jun 2016 14:32:18 -0400 Received: by mail-wm0-x243.google.com with SMTP id a66so26986313wme.2 for ; Mon, 27 Jun 2016 11:32:17 -0700 (PDT) Sender: Paolo Bonzini References: <1466192793-2559-1-git-send-email-rth@twiddle.net> From: Paolo Bonzini Message-ID: Date: Mon, 27 Jun 2016 20:32:05 +0200 MIME-Version: 1.0 In-Reply-To: <1466192793-2559-1-git-send-email-rth@twiddle.net> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] [PATCH] target-alpha: Avoid gcc 6.1 werror for linux-user List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Richard Henderson , qemu-devel@nongnu.org, Peter Maydell On 17/06/2016 21:46, Richard Henderson wrote: > Using gcc 6.1 for alpha-linux-user target we see the following build error: > > .../target-alpha/translate.c: In function ‘in_superpage’: > .../target-alpha/translate.c:454:52: error: self-comparison always evaluates to true [-Werror=tautological-compare] > && addr >> TARGET_VIRT_ADDR_SPACE_BITS == addr >> 63); > > Reported-by: Pranith Kumar > Signed-off-by: Richard Henderson > --- > target-alpha/translate.c | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > > diff --git a/target-alpha/translate.c b/target-alpha/translate.c > index f9b2426..051b4b7 100644 > --- a/target-alpha/translate.c > +++ b/target-alpha/translate.c > @@ -448,10 +448,13 @@ static ExitStatus gen_store_conditional(DisasContext *ctx, int ra, int rb, > > static bool in_superpage(DisasContext *ctx, int64_t addr) > { > +#ifndef CONFIG_USER_ONLY > return ((ctx->tb->flags & TB_FLAGS_USER_MODE) == 0 > - && addr < 0 > - && ((addr >> 41) & 3) == 2 > - && addr >> TARGET_VIRT_ADDR_SPACE_BITS == addr >> 63); > + && addr >> TARGET_VIRT_ADDR_SPACE_BITS == -1 > + && ((addr >> 41) & 3) == 2); > +#else > + return false; > +#endif > } > > static bool use_goto_tb(DisasContext *ctx, uint64_t dest) > Peter, can you apply this as a build-breakage fix? (Fedora 24 is now out and has this bug). Paolo