From patchwork Wed Nov 16 19:51:43 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 695807 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3tJwQf44Tnz9t10 for ; Thu, 17 Nov 2016 07:12:10 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="gqxOnPyy"; dkim-atps=neutral Received: from localhost ([::1]:54589 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c76Yx-000165-H0 for incoming@patchwork.ozlabs.org; Wed, 16 Nov 2016 15:12:07 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52739) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c76Ff-0000mx-LJ for qemu-devel@nongnu.org; Wed, 16 Nov 2016 14:52:12 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c76Fe-00077q-MV for qemu-devel@nongnu.org; Wed, 16 Nov 2016 14:52:11 -0500 Received: from mail-wm0-x241.google.com ([2a00:1450:400c:c09::241]:35248) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1c76Fe-00077d-Fl for qemu-devel@nongnu.org; Wed, 16 Nov 2016 14:52:10 -0500 Received: by mail-wm0-x241.google.com with SMTP id a20so14579878wme.2 for ; Wed, 16 Nov 2016 11:52:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=e5Hjj1AHdWiVy+V1JxFPDE0RyIlrV7OSKFkEz83lwoQ=; b=gqxOnPyyOesmBnhbID7+TNvidOyMVS3JyNfv2g3kv1RWzdkT39ctRZF1iWXVctE3NN diYPRmSzELAJAKohQfEw2NMs8kLOqzuWux0ekpHKUQJunkrkQYUvBDUvCdhPkM7V81B7 zsEptD2BhOpBKLytIJWlsohd0IK/fyKtENccSahvhJD5czsYBIuZJvx0jQagYh//l0we fKrlWo9gx5jGjD4up97JZweyl74jsIOd4jL9/JeKcXS6YzkaitVsDw9U5ZuqNmXI8M9f uuNlkDr52Au1xViYnUQnD+WDN33jFLLLGsZ8NMZud2t7CVu+z7PSxoLxJxbyFkiXc7RZ 1BIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=e5Hjj1AHdWiVy+V1JxFPDE0RyIlrV7OSKFkEz83lwoQ=; b=TrvgygSEq8xRjmtruI+HpbYi9iRjmyuJTKs1HDDds/LLMYckg8elzF2GvGKTw+ORop Xdkh86EhUEr6gkdiXTHJ+SXcgEH0e23jWpCN6AdwcFOb2qRWP1UdT3K6Vkl82RlgleX2 vPaSiJ+pUn61CnCH49PFwABW00MXINx2qSBdlE5kOF6VnEgcGNisjM0v016mB9f48R1H oRqQNKUODw1Rf+Uekc1jpMstgaLLAXX5ZkxxfONa1Ovd+orTJANMQOz40Ty2VM6MYVDC a5byXDBM+vuftT2Xcy3jEMlH9osJ8eQUz+Qa32UzRCtKGD2VZi0aPJ7Lg+ModRBUCgHo aPuA== X-Gm-Message-State: ABUngvc4GBrlk7OBC0YG5RXPTFVBpXWktZLpEzjACkjrA5bcotHLIJOFLKuv4o2r3uoR5A== X-Received: by 10.28.65.196 with SMTP id o187mr11697761wma.115.1479325929425; Wed, 16 Nov 2016 11:52:09 -0800 (PST) Received: from bigtime.twiddle.net ([87.111.149.139]) by smtp.gmail.com with ESMTPSA id l67sm11747825wmf.20.2016.11.16.11.52.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 16 Nov 2016 11:52:08 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Date: Wed, 16 Nov 2016 20:51:43 +0100 Message-Id: <1479325910-9060-8-git-send-email-rth@twiddle.net> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1479325910-9060-1-git-send-email-rth@twiddle.net> References: <1479325910-9060-1-git-send-email-rth@twiddle.net> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::241 Subject: [Qemu-devel] [RFC 07/14] tcg: Change temp_allocate_frame arg to TCGTemp X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, aurelien@aurel32.net Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Richard Henderson --- tcg/tcg.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/tcg/tcg.c b/tcg/tcg.c index 4bcdb1e..c9e0da5 100644 --- a/tcg/tcg.c +++ b/tcg/tcg.c @@ -1865,10 +1865,8 @@ static void check_regs(TCGContext *s) } #endif -static void temp_allocate_frame(TCGContext *s, int temp) +static void temp_allocate_frame(TCGContext *s, TCGTemp *ts) { - TCGTemp *ts; - ts = &s->temps[temp]; #if !(defined(__sparc__) && TCG_TARGET_REG_BITS == 64) /* Sparc64 stack is accessed with offset of 2047 */ s->current_frame_offset = (s->current_frame_offset + @@ -1921,7 +1919,7 @@ static void temp_sync(TCGContext *s, TCGTemp *ts, } if (!ts->mem_coherent) { if (!ts->mem_allocated) { - temp_allocate_frame(s, temp_idx(ts)); + temp_allocate_frame(s, ts); } switch (ts->val_type) { case TEMP_VAL_CONST: @@ -2152,7 +2150,7 @@ static void tcg_reg_alloc_mov(TCGContext *s, const TCGOpDef *def, liveness analysis disabled). */ tcg_debug_assert(NEED_SYNC_ARG(0)); if (!ots->mem_allocated) { - temp_allocate_frame(s, args[0]); + temp_allocate_frame(s, ots); } tcg_out_st(s, otype, ts->reg, ots->mem_base->reg, ots->mem_offset); if (IS_DEAD_ARG(1)) {