From patchwork Sat Jul 10 15:31:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 472355 Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp1369889jao; Sat, 10 Jul 2021 08:46:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyo6nwwTFCnOm9t+Ai54ayiM9SHGd0gkUVGDOuZa52KT6oHutKyCSh1L49YlW5gmayG5a05 X-Received: by 2002:a6b:c90f:: with SMTP id z15mr24039604iof.183.1625931998996; Sat, 10 Jul 2021 08:46:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625931998; cv=none; d=google.com; s=arc-20160816; b=k3ugc9q8dYOEfOTD+NvR70GGZbl0kfc+PT7Y3fFhIBWvfcGZHHT3ZHmZtIP1r46/K8 EfdRAowvWqvwOpywcB5T6hpEkJhZ+NaG5ghVDU7iE4VsYO9V5F0D+Mv+YnJrvhiSz99F tEqKm6z7lAQZ4X4xGXIiU3ipahuclBinpRs6QBd8iMh4bzt9d5Fru6EQsIJYCoA9ExmE Pd0XpxBr7s1laBgumLO86TIh/A15/EvgWRFOQOfJnTRh2VXCwoAdvtouYoW5CoFUFTvr omcKvaMDKt02qdM8vMFw+G9acJAUCf98Rs1BchUP5qlwi91TgfpB3xbjorw4U1Ero+ao OhVQ== 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:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=QtV1oQWQj2aiAo4khTYZosWNvQunNKSfTN6eXGpTJBs=; b=R2ByLYLWYSvuiqb+J92RieP3qP9P3RUPb7NPTV9412bYZ5NkbnecQWYQSlGr2dcmlo VWQLj/l+wJDyyvjf3LtTJ2hCMjPBT1WwVcR+YF4fcj7KuAoxohH2NbCtyASF5kSRIRp1 W2WfVH8bCoLtfwcsg+plM5qwloy6n/oPQjwEGDJ/bY6jrZIZ74QttjMYXhTz+1ni5/U8 2sAYkEQOOWNafACs08oTS20sZckUGtoOtDaFP36gUofxq2dDgqiDWDUzVxlj72/2bl1H R6eygvteIMOoATnSziyQpe6+2wrKtrLBE0DLCvxIBa3HYEc2SwJ/khgG8QpvXNbgVadA zyMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jWkaKA0s; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id e3si1255260iow.52.2021.07.10.08.46.38 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 10 Jul 2021 08:46:38 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jWkaKA0s; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:38076 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m2FBe-0001sj-Dz for patch@linaro.org; Sat, 10 Jul 2021 11:46:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58788) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m2ExW-0005ex-Tf for qemu-devel@nongnu.org; Sat, 10 Jul 2021 11:32:02 -0400 Received: from mail-pj1-x1032.google.com ([2607:f8b0:4864:20::1032]:46741) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m2ExU-0002Lo-3u for qemu-devel@nongnu.org; Sat, 10 Jul 2021 11:32:02 -0400 Received: by mail-pj1-x1032.google.com with SMTP id b5-20020a17090a9905b029016fc06f6c5bso7781831pjp.5 for ; Sat, 10 Jul 2021 08:31:59 -0700 (PDT) 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=QtV1oQWQj2aiAo4khTYZosWNvQunNKSfTN6eXGpTJBs=; b=jWkaKA0sfixNsD3Tueey6DRh92hFfNjI34WGD0Sv6+M9S8RkqcKs58EMDX5L5lgzXT sQK5tLN/m/0HQF6uJttASsVOKzSkj0Km4lbqfZKt7AUB3n9PwMB4E8AK49BnfvfNYmfo PAjojWg4+FF/fu/iMAaTcCtYfLWGB06lft40z8RdmVNQCkkcNAVPkutRA9OSeYTMw8sh swJZOLtu8TGfMV6zLtALvCEnGvr746DS4aE1wN3S4ni/mPbpt8DsPU+JRDAlMP24Lu8f 6vdeyTC2b30eR8hKoxjpDAjaJjawhF0StfDeXCbjuj/hr5XZmo9dFMkx9WRqBPUUSRuo GDrQ== 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=QtV1oQWQj2aiAo4khTYZosWNvQunNKSfTN6eXGpTJBs=; b=Y/lrrPkU1560hXRXCEiQ+uIGMZBAtTZ1W1ZIUqoCt43ORCZVs83OqhWtLTWwHalTb3 sKS9eSbToYz7TmJh2vXwgLCoMSitRFKYYx1uthDZklsL0zJPyNLRuDMIpZyeKLpYgg0v EZhCAsSbyM2XwkHwXTpslS0MPIcjHZLgZ7aanx9RP/ow9WuSHzWmgAOoUSBENcTjY4Wx qp0NQenKdERPcvsDX1+mqOBDxng6DhrciC1RRYSGvrtntaSHjZ6PBtc77jx7Ek9EqqCv kE5qOBPaOtHId3RrkanXUQlT5Sizd9aYdwtzuKk1zX3Ndl4GM3ySp6y1PdD5hNpJfxXN sVBw== X-Gm-Message-State: AOAM530+tqZZj+tLrzwzHhhdf/rDfdUNHWsnU6zPWabxdOxJUA8XnZ3z Ck663Im4s0SUs0/fqwJh6QDi6bvEoVcR7g== X-Received: by 2002:a17:902:249:b029:12a:fb53:2035 with SMTP id 67-20020a1709020249b029012afb532035mr1151098plc.73.1625931118874; Sat, 10 Jul 2021 08:31:58 -0700 (PDT) Received: from localhost.localdomain ([71.212.149.176]) by smtp.gmail.com with ESMTPSA id u23sm11975374pgk.38.2021.07.10.08.31.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 10 Jul 2021 08:31:58 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 20/41] target/mips: Use translator_use_goto_tb Date: Sat, 10 Jul 2021 08:31:22 -0700 Message-Id: <20210710153143.1320521-21-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210710153143.1320521-1-richard.henderson@linaro.org> References: <20210710153143.1320521-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1032; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x1032.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Maydell Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Just use translator_use_goto_tb directly at the one call site, rather than maintaining a local wrapper. Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/mips/tcg/translate.c | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) -- 2.25.1 diff --git a/target/mips/tcg/translate.c b/target/mips/tcg/translate.c index cb82426f66..5cd3e7d8dd 100644 --- a/target/mips/tcg/translate.c +++ b/target/mips/tcg/translate.c @@ -4947,22 +4947,9 @@ static void gen_trap(DisasContext *ctx, uint32_t opc, tcg_temp_free(t1); } -static inline bool use_goto_tb(DisasContext *ctx, target_ulong dest) +static void gen_goto_tb(DisasContext *ctx, int n, target_ulong dest) { - if (unlikely(ctx->base.singlestep_enabled)) { - return false; - } - -#ifndef CONFIG_USER_ONLY - return (ctx->base.tb->pc & TARGET_PAGE_MASK) == (dest & TARGET_PAGE_MASK); -#else - return true; -#endif -} - -static inline void gen_goto_tb(DisasContext *ctx, int n, target_ulong dest) -{ - if (use_goto_tb(ctx, dest)) { + if (translator_use_goto_tb(&ctx->base, dest)) { tcg_gen_goto_tb(n); gen_save_pc(dest); tcg_gen_exit_tb(ctx->base.tb, n);