From patchwork Fri Dec 14 03:18:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 153709 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp1596227ljp; Thu, 13 Dec 2018 19:22:39 -0800 (PST) X-Google-Smtp-Source: AFSGD/U2sfYFjgdw3/bPD9W6GrJzYwjda/+FGm/IZA+Zkie5DqCwcHYq5127ORJkuOdupbeex6Yn X-Received: by 2002:ac8:1712:: with SMTP id w18mr1263073qtj.76.1544757759857; Thu, 13 Dec 2018 19:22:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544757759; cv=none; d=google.com; s=arc-20160816; b=pL9IxMZVBqXHFM9EVFwOkT9pynkRrKAnifQktTzUuvur7eMHcFlr4vAOF4cXXh968n OTVJqyPfJcl6OwycJ3S4d6w0TkYEPBudiFVgs5KOfFLqiPYzCtBMh3fs9OdchUFwCewe x806OxS5VyOvW9+FvZFXIlQPeqqj7a74KYXQPVEOgXVNuWkcRXLakrKKAPx/Qpb4MlVK J2HHgNLCgx9MS/2AhL3vA8RbyK39oT6kKKGzcwY/MKgRXcuDu2TdfuVah9deyVoflPY0 r/C2xUfC1lehxU7APIRGMkPMAJdsAL5uoWGes7JmPwVuoGzFzmlAt9Ei73f4I0SyPrOS XHNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:to:from:dkim-signature; bh=NhEZSAJG05xqXtLacoC2PBUagTVyKddaBYmrH62y/sY=; b=ilEkE9a0+DDB2xnPXwYEetDbYRHt3qHOhr/nbaihmQW2ljLGH+hVF6MoiesFAXAI+1 HksCcb3q0EADpY8vIEfVvPaBI57fmYJhvS+DukgXKzNAvyjOKZ3Wh6eSH7Ru86VH7WXC u1F2jGwNI4MlbXc69feIH0PQSNRbgdExtIzW+CO08aDt9cYAjhzQ1z0vzRDoSgdgzt6s fgqnvWws+vvvvBC9f1LbMaH1avuGFxx+OWNPwbFD/pQe+VCjn4c4Db+xl9ElSWndbWfY 7S44r4yvi3y4dXPgCFYVOatLxNFsM+ArhAjgcQyMjd6l3fFF54cZzXDRhWfUuVOFJPzr cccA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Z9eEZHUc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id x3si1337163qtd.345.2018.12.13.19.22.39 for (version=TLS1 cipher=AES128-SHA bits=128/128); Thu, 13 Dec 2018 19:22:39 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=Z9eEZHUc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:59063 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gXe3j-0007BX-Ai for patch@linaro.org; Thu, 13 Dec 2018 22:22:39 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58652) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gXe0i-0005pX-0h for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:19:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gXe0f-0006C5-DM for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:19:31 -0500 Received: from mail-oi1-x234.google.com ([2607:f8b0:4864:20::234]:40816) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gXe0f-0006A9-87 for qemu-devel@nongnu.org; Thu, 13 Dec 2018 22:19:29 -0500 Received: by mail-oi1-x234.google.com with SMTP id t204so3457298oie.7 for ; Thu, 13 Dec 2018 19:19:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=NhEZSAJG05xqXtLacoC2PBUagTVyKddaBYmrH62y/sY=; b=Z9eEZHUce+UhRwgXjNkHen4V3RPBcMGsrK6g+6TmXA3c1p69Yq3q8GaeC1qzQoWDcb OAo6v5GhnKV20zjvGv8B8GMaxBY9xqDA59C81ku+aokA9qnfRUiT3ySTVNdrXV/xlEmn y5fZDR18U0Lm+j9ObFzYr1lbowvzykL3emPPg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=NhEZSAJG05xqXtLacoC2PBUagTVyKddaBYmrH62y/sY=; b=RNTXuTnyNkAy9OCBdllRP+og07lgLmSl7o7/xmhYgi+o667Ecz/wgK+n04MyPSbJ2a YmVIVNoyFI43SM8+weUHX8JPZtLEL/kwDssHVcUEDK6DEASpYFd8GoJLjwYkahWF9t5a iFB79t5wFRz+36sD9mRccB11XM3Mhsb1Qo5JhVAcMZPYILIRkELDTmHKWoueugW7/KBS IZu90RCEOtzmoyJbfRz/PHRfUsKJMe5hfBqKY2/ITI0Vwse4yzTU8GHCLcvS4hnYvEaD lqWep6dipr2U4DsXbWhIHCg//iNR2pIyUBhxgMmE70+nfrzU5iNChtvy2PL+pgGR5Bxs KJdg== X-Gm-Message-State: AA+aEWbWyqQSm0hRYNCnXj+P2TkZ7Rml5P2pBcH3AGfdpTAhz3MTl4Pj SO3sWO4tglOjWbnje31eQnnWRWSrjfDrYA== X-Received: by 2002:aca:b642:: with SMTP id g63mr764121oif.195.1544757568038; Thu, 13 Dec 2018 19:19:28 -0800 (PST) Received: from cloudburst.twiddle.net ([187.217.227.243]) by smtp.gmail.com with ESMTPSA id g138sm2367537oib.26.2018.12.13.19.19.26 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 13 Dec 2018 19:19:27 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Date: Thu, 13 Dec 2018 21:18:52 -0600 Message-Id: <20181214031923.29527-3-richard.henderson@linaro.org> X-Mailer: git-send-email 2.17.2 In-Reply-To: <20181214031923.29527-1-richard.henderson@linaro.org> References: <20181214031923.29527-1-richard.henderson@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4864:20::234 Subject: [Qemu-devel] [PULL 01/32] tcg/i386: Always use %ebp for TCG_AREG0 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 Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" For x86_64, this can remove a REX prefix resulting in smaller code when manipulating globals of type i32, as we move them between backing store via cpu_env, aka TCG_AREG0. Reviewed-by: Alex Bennée Reviewed-by: Emilio G. Cota Signed-off-by: Richard Henderson --- tcg/i386/tcg-target.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) -- 2.17.2 diff --git a/tcg/i386/tcg-target.h b/tcg/i386/tcg-target.h index 9fdf37f23c..7488c3d869 100644 --- a/tcg/i386/tcg-target.h +++ b/tcg/i386/tcg-target.h @@ -84,6 +84,8 @@ typedef enum { TCG_REG_RBP = TCG_REG_EBP, TCG_REG_RSI = TCG_REG_ESI, TCG_REG_RDI = TCG_REG_EDI, + + TCG_AREG0 = TCG_REG_EBP, } TCGReg; /* used for function call generation */ @@ -194,12 +196,6 @@ extern bool have_avx2; #define TCG_TARGET_extract_i64_valid(ofs, len) \ (((ofs) == 8 && (len) == 8) || ((ofs) + (len)) == 32) -#if TCG_TARGET_REG_BITS == 64 -# define TCG_AREG0 TCG_REG_R14 -#else -# define TCG_AREG0 TCG_REG_EBP -#endif - static inline void flush_icache_range(uintptr_t start, uintptr_t stop) { }