From patchwork Sat Mar 2 05:15:29 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 777472 Delivered-To: patch@linaro.org Received: by 2002:adf:e94d:0:b0:33d:f458:43ce with SMTP id m13csp1694420wrn; Fri, 1 Mar 2024 21:18:05 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCUOFxh4hx+D5BF+pA/8wMfZ7eKeGB8DORt1833tTd6LfwHWhSPnsgGgPHNonXONXZaXJkfrDDnqhMmIcsYOs4hz X-Google-Smtp-Source: AGHT+IH24IC2hXzpROzLp5BUiOfS0Zwr05WoSRUdW2nHOjKdC1Wy+Ktm7+AecPlN8X+0Hiko3dAG X-Received: by 2002:a05:622a:1c1:b0:42e:c3d8:384b with SMTP id t1-20020a05622a01c100b0042ec3d8384bmr3770051qtw.7.1709356684954; Fri, 01 Mar 2024 21:18:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1709356684; cv=none; d=google.com; s=arc-20160816; b=PtK1tN72Pi3JpWLmCAZVvzA+zWMkYd7nVjti3OWkPqhuewjDO27vtaecX+Ib1EjF0G DILuYazsXLt7fgKJqroMIfaR10L5jqjjXmp91KlKjJepjEeOQ42pCtjweJXKs0jsvUIx wuh8q3+bNm3N9Mzo+bro3eCryf/hYx3HDozBUROXmhqueS4sJi1sFy+3zC+IPeqa6Bkl DrEvMuHP/7q9T7isanGSis2hpuFQFL9MA/16dwwLMMqBD9yabEnWGUevNlQt9YBZAyV9 2aGcSZJHBurL2+3LFKNjPvcl207LvbCyTZH04m0aNaWuaGzQcBszT7RyhmmoHtgbZAbV Blpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to: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:cc:to :from:dkim-signature; bh=3UUMLLXsAT9hxWNYnOEqNqemxeKUB6s4UmOAyXwA2RU=; fh=OY/jf0qYEhT53LcIJp8d/e39mN3vEzshkseI36O8N8s=; b=iuxwuHXJq4PBoZan5R074i5oGXDVhQmAucmgvQGpaJgwl7ozQ3bHZrNpuRiV3IaRBD jzinTqc+SzdWx6LG+I4zx4MTmqClSf8SXOESliiIz81NgFosToYyrLu7ODM3weIhIKXn m0qjIu7gu8CHL3astjdEOSM4orZxFEnIceJoDNLGFJIfP+/Gizzpnx2gWMCZ18Mn2Y3S /rfu82FLM5iO49bzNoF3O4sWbJKYPxEpnEQhYVB40FuvXihuTy4dt/B6klyw65AP7yYs wVXvk58TU05RtAkmYyTvX/1BxbXv3vmxmN8YeGnrpYA4qlKC3ReFBJLHVmipphiXYpZw egEg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KvKu9Bjn; 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 y16-20020a05622a121000b0042e770d48dfsi5556206qtx.35.2024.03.01.21.18.04 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 01 Mar 2024 21:18:04 -0800 (PST) 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=KvKu9Bjn; 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] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rgHjV-0002Q6-ME; Sat, 02 Mar 2024 00:16:25 -0500 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 1rgHjU-0002PS-3R for qemu-devel@nongnu.org; Sat, 02 Mar 2024 00:16:24 -0500 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rgHjS-0007VF-CL for qemu-devel@nongnu.org; Sat, 02 Mar 2024 00:16:23 -0500 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6d9f94b9186so2715095b3a.0 for ; Fri, 01 Mar 2024 21:16:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1709356581; x=1709961381; 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=3UUMLLXsAT9hxWNYnOEqNqemxeKUB6s4UmOAyXwA2RU=; b=KvKu9Bjn6be6Zv7DCJKCbG7z6wGHWl0J306qYYK3ZLeJ0m+KnQVXuwvq0ziJ5QCEP5 k6vS6lk0KosdLlZTH9k8zZFmX5zGFZFyjXr9RSoh21pJAyHLjoZqZG6PfuiNF6UuzqI4 NmMi/KfhoPdufhu0SwdRHZ7aPW6iI1xT1s/ZHJwMrhaBdEGPRr3asv6e/eKswQEqZnx7 NoR8U05d6sfBIS7OfjymgRi41nknyxsQnhWy18E+MF3Iye4JE6q6RlfOc3iwqKj3mONW hT2GRwMiRT3QhgOBx05OnJMOo0np4Ep6theBRlwEwP1Uf059gK2NUi108VUMsdBRkF00 XMMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709356581; x=1709961381; 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=3UUMLLXsAT9hxWNYnOEqNqemxeKUB6s4UmOAyXwA2RU=; b=m5xiVZ2NWPfw6bCj+/IBUXVgtCZBy+QhsH7u6f8nZxHnuO3QAUy3S/ttsOQhtOvUFL O82ObQatS18mj0eTE4wHE8O/Brj7c8zNauJJxyXrnZ5J0d4+ivXxUNBG7iF4m0rU6aS1 BKxWDo29GkCmk2HKWf7c1qtOsbT2aUsVflbMsMoG4FIytH6jQuAh3LWTYI4CPMqoKsQS OjdSkSV51y+UI+16Zy8P+T20MSHFj0dEANpIonGekMjJO9ll9DuuAIYhORa60pRkmeYt q7Z1Df3dn/IdF8bxs09doeDlPA4w76VtsO3lDhmw5hR6XPLB8pARotYQysNuuPGr0mUT dblg== X-Gm-Message-State: AOJu0Yy8mStaR9EixwDXwDwBpRfD3Gp1SkMnW3QrgCrXnGvOGhREymOL B2v5S3Iu3/tiIqkbO0eM/qw5KncCmqePboEmm/Mu8iTkgyTbA74nAVP55pyjIUC1pZFADMjzog/ c X-Received: by 2002:a05:6a20:af11:b0:1a0:ff4d:eb2d with SMTP id dr17-20020a056a20af1100b001a0ff4deb2dmr3034169pzb.54.1709356580840; Fri, 01 Mar 2024 21:16:20 -0800 (PST) Received: from stoup.. (098-147-055-211.res.spectrum.com. [98.147.55.211]) by smtp.gmail.com with ESMTPSA id v8-20020a17090a458800b0029af67d4fd0sm4034901pjg.44.2024.03.01.21.16.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 01 Mar 2024 21:16:20 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: mark.cave-ayland@ilande.co.uk, atar4qemu@gmail.com Subject: [PATCH 09/41] target/sparc: Remove gen_dest_fpr_D Date: Fri, 1 Mar 2024 19:15:29 -1000 Message-Id: <20240302051601.53649-10-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240302051601.53649-1-richard.henderson@linaro.org> References: <20240302051601.53649-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x432.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, T_SCC_BODY_TEXT_LINE=-0.01 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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Replace with tcg_temp_new_i64. Signed-off-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé --- target/sparc/translate.c | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/target/sparc/translate.c b/target/sparc/translate.c index 97a5c636d2..ddceb25b08 100644 --- a/target/sparc/translate.c +++ b/target/sparc/translate.c @@ -250,11 +250,6 @@ static void gen_store_fpr_D(DisasContext *dc, unsigned int dst, TCGv_i64 v) gen_update_fprs_dirty(dc, dst); } -static TCGv_i64 gen_dest_fpr_D(DisasContext *dc, unsigned int dst) -{ - return cpu_fpr[dst / 2]; -} - static TCGv_i128 gen_load_fpr_Q(DisasContext *dc, unsigned int src) { TCGv_i128 ret = tcg_temp_new_i128(); @@ -1985,7 +1980,7 @@ static void gen_fmovs(DisasContext *dc, DisasCompare *cmp, int rd, int rs) static void gen_fmovd(DisasContext *dc, DisasCompare *cmp, int rd, int rs) { #ifdef TARGET_SPARC64 - TCGv_i64 dst = gen_dest_fpr_D(dc, rd); + TCGv_i64 dst = tcg_temp_new_i64(); tcg_gen_movcond_i64(cmp->cond, dst, cmp->c1, tcg_constant_tl(cmp->c2), gen_load_fpr_D(dc, rs), gen_load_fpr_D(dc, rd)); @@ -4326,7 +4321,7 @@ static bool do_dd(DisasContext *dc, arg_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src = gen_load_fpr_D(dc, a->rs); func(dst, src); gen_store_fpr_D(dc, a->rd, dst); @@ -4348,7 +4343,7 @@ static bool do_env_dd(DisasContext *dc, arg_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src = gen_load_fpr_D(dc, a->rs); func(dst, tcg_env, src); gen_store_fpr_D(dc, a->rd, dst); @@ -4388,7 +4383,7 @@ static bool do_env_df(DisasContext *dc, arg_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src = gen_load_fpr_F(dc, a->rs); func(dst, tcg_env, src); gen_store_fpr_D(dc, a->rd, dst); @@ -4479,7 +4474,7 @@ static bool do_env_dq(DisasContext *dc, arg_r_r *a, } src = gen_load_fpr_Q(dc, a->rs); - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); func(dst, tcg_env, src); gen_store_fpr_D(dc, a->rd, dst); return advance_pc(dc); @@ -4594,7 +4589,7 @@ static bool do_dff(DisasContext *dc, arg_r_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src1 = gen_load_fpr_F(dc, a->rs1); src2 = gen_load_fpr_F(dc, a->rs2); func(dst, src1, src2); @@ -4618,7 +4613,7 @@ static bool do_dfd(DisasContext *dc, arg_r_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src1 = gen_load_fpr_F(dc, a->rs1); src2 = gen_load_fpr_D(dc, a->rs2); func(dst, src1, src2); @@ -4637,7 +4632,7 @@ static bool do_ddd(DisasContext *dc, arg_r_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src1 = gen_load_fpr_D(dc, a->rs1); src2 = gen_load_fpr_D(dc, a->rs2); func(dst, src1, src2); @@ -4702,7 +4697,7 @@ static bool do_env_ddd(DisasContext *dc, arg_r_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src1 = gen_load_fpr_D(dc, a->rs1); src2 = gen_load_fpr_D(dc, a->rs2); func(dst, tcg_env, src1, src2); @@ -4727,7 +4722,7 @@ static bool trans_FsMULd(DisasContext *dc, arg_r_r_r *a) return raise_unimpfpop(dc); } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src1 = gen_load_fpr_F(dc, a->rs1); src2 = gen_load_fpr_F(dc, a->rs2); gen_helper_fsmuld(dst, tcg_env, src1, src2); @@ -4744,7 +4739,7 @@ static bool do_dddd(DisasContext *dc, arg_r_r_r *a, return true; } - dst = gen_dest_fpr_D(dc, a->rd); + dst = tcg_temp_new_i64(); src0 = gen_load_fpr_D(dc, a->rd); src1 = gen_load_fpr_D(dc, a->rs1); src2 = gen_load_fpr_D(dc, a->rs2);