From nobody Wed Nov 27 14:27:57 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1698279736; cv=none; d=zohomail.com; s=zohoarc; b=NdUF+2pdR4xaUf9DC/kIp465k5r7DGin1SgZXe1XE2z37SMZExTR+FsyYK6E9a1RcDDN5voPMUzDbpwt77iuE7J7JdHawbBQKI/27btwQymGX8ewhVJ6viZSfJFPHc/LUiQSmZ4yLG3BZvhXN3WFXLveflMjWjcAUaFY1e99SZM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1698279736; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=RPgAucB/EvVI7/45p+5WkYALvfhQJlj29a4kXp2aWhI=; b=Xpo7OR0aQG+P7GSdwjdmlg/UYDNUF40BHX0/5Arp6IcW1YagKIwEUWPYSLl9YHubTwvfDD4ns4K84Tx4xFEEJeW6goFveXO4E+y6h65XwsOju3uyt+bMNuTNXn3R1plWKVOovekA9lj16E56l2a/AvBPaa9F00ODs67ugDvCx0Q= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1698279736518995.5058027105381; Wed, 25 Oct 2023 17:22:16 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qvo34-0007OR-33; Wed, 25 Oct 2023 20:16:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qvo2q-00075n-TQ for qemu-devel@nongnu.org; Wed, 25 Oct 2023 20:16:16 -0400 Received: from mail-pl1-x62b.google.com ([2607:f8b0:4864:20::62b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qvo2l-0004tI-6Z for qemu-devel@nongnu.org; Wed, 25 Oct 2023 20:16:16 -0400 Received: by mail-pl1-x62b.google.com with SMTP id d9443c01a7336-1c9d407bb15so2427855ad.0 for ; Wed, 25 Oct 2023 17:16:10 -0700 (PDT) Received: from stoup.. ([71.212.149.95]) by smtp.gmail.com with ESMTPSA id ij23-20020a170902ab5700b001c582de968dsm10038433plb.72.2023.10.25.17.16.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Oct 2023 17:16:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698279369; x=1698884169; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=RPgAucB/EvVI7/45p+5WkYALvfhQJlj29a4kXp2aWhI=; b=bfalixj1Kqe1rg2Z0W60miOifocDxef5rcvBHgV4WeFce0m3MLUhYOF134MMskFPNt He4mAWK1TBNJQjmXD3Gtv6aPWl2fiq9Xxuc7XiiahcIBS/hNHrFCYM2xp5tMZjMJmjSD Mn8DQ9/lJKEnWSj1vl1itFclt8VsRtAge33cx21SN7MnrUuoa+tNtt/S47wNsv4y/Q2e w3+Kwaf46y0rGkBugUGtz9cGs9R9E2ChYESidElimVZvjOUgGrMjTMBbswlzhab9wqCE eq8JknOD+I5wcoS6O8DcwGJMzjHOJnhIoLoQUOB/lqDIGB38/IbZeSoXFo4KQOY/3klh J2Dw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698279369; x=1698884169; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RPgAucB/EvVI7/45p+5WkYALvfhQJlj29a4kXp2aWhI=; b=Ief/cuz/2SknYY5w28jRkVN+f2aDIzx136/xo6fF8s27c9wwhv+Mx4BJOeVbHQWFW9 zUi0utaEjAAql9DKJAT35Hi+yP/wd5BHMXVtbDhYKvCx5XV6emdi/EsnXM29zGAMmszc voi7VWeAlWrVzgAZWOUWLKLVc61A/FdXrpZuBSLIiahX0mLI96L0JzQrswpXuNntsl2b ImIIvdlav8DK/71N3n8yJSCg+qn0NCyKFsi23fKTxsVyO6bfwQHHr2l81tCdLaSi8b4a qs9O8jTP6yoUAkGEyq0rq+hikihQZzCEl07QYih5R6qB2oMB12iOHDkhOl2TX3a+iZ6m tNpA== X-Gm-Message-State: AOJu0Yyp5qV0UnSRxMboHhalwuSJS+r6QMRxg6pKBudPBJkCVILKA8Yy SZsjOZogDw6MgNmHAyc9Q04m1QFllcHhy/cP47w= X-Google-Smtp-Source: AGHT+IHk0sjH3c1lq6LtiY96grt1EgHCtArUYGsjl6Cxrg5n6WXlzPyTPJ7RJLn8wSya2yf0bFV5/Q== X-Received: by 2002:a17:902:edc2:b0:1c6:2d13:5b77 with SMTP id q2-20020a170902edc200b001c62d135b77mr16093034plk.39.1698279369365; Wed, 25 Oct 2023 17:16:09 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Mark Cave-Ayland , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 16/94] target/sparc: Merge gen_cond with only caller Date: Wed, 25 Oct 2023 17:14:10 -0700 Message-Id: <20231026001542.1141412-32-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231026001542.1141412-1-richard.henderson@linaro.org> References: <20231026001542.1141412-1-richard.henderson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2607:f8b0:4864:20::62b; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x62b.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.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1698279738218100009 Tested-by: Mark Cave-Ayland Acked-by: Mark Cave-Ayland Reviewed-by: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Richard Henderson --- target/sparc/translate.c | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/target/sparc/translate.c b/target/sparc/translate.c index 69e85b1842..2664db302d 100644 --- a/target/sparc/translate.c +++ b/target/sparc/translate.c @@ -1309,20 +1309,6 @@ static void gen_fcompare(DisasCompare *cmp, unsigned= int cc, unsigned int cond) } } =20 -static void gen_cond(TCGv r_dst, unsigned int cc, unsigned int cond, - DisasContext *dc) -{ - DisasCompare cmp; - gen_compare(&cmp, cc, cond, dc); - - /* The interface is to return a boolean in r_dst. */ - if (cmp.is_bool) { - tcg_gen_mov_tl(r_dst, cmp.c1); - } else { - tcg_gen_setcond_tl(cmp.cond, r_dst, cmp.c1, cmp.c2); - } -} - static void gen_fcond(TCGv r_dst, unsigned int cc, unsigned int cond) { DisasCompare cmp; @@ -2980,6 +2966,7 @@ static bool advance_jump_cond(DisasContext *dc, bool = annul, target_ulong dest) static bool do_bpcc(DisasContext *dc, arg_bcc *a) { target_long target =3D address_mask_i(dc, dc->pc + a->i * 4); + DisasCompare cmp; =20 switch (a->cond) { case 0x0: @@ -2988,7 +2975,13 @@ static bool do_bpcc(DisasContext *dc, arg_bcc *a) return advance_jump_uncond_always(dc, a->a, target); default: flush_cond(dc); - gen_cond(cpu_cond, a->cc, a->cond, dc); + + gen_compare(&cmp, a->cc, a->cond, dc); + if (cmp.is_bool) { + tcg_gen_mov_tl(cpu_cond, cmp.c1); + } else { + tcg_gen_setcond_tl(cmp.cond, cpu_cond, cmp.c1, cmp.c2); + } return advance_jump_cond(dc, a->a, target); } } --=20 2.34.1