From patchwork Wed Feb 22 23:27:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 655713 Delivered-To: patch@linaro.org Received: by 2002:adf:a3c6:0:0:0:0:0 with SMTP id m6csp36412wrb; Wed, 22 Feb 2023 15:29:34 -0800 (PST) X-Google-Smtp-Source: AK7set9RX/9Wk0AzymXb0hbgyYR4qKXUh13w9JVOgEO+4z7qCVC2oC/krQzyeUQhEFuRAubcdjot X-Received: by 2002:ac8:5785:0:b0:3b9:2b0:5e7e with SMTP id v5-20020ac85785000000b003b902b05e7emr3025194qta.27.1677108574100; Wed, 22 Feb 2023 15:29:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677108574; cv=none; d=google.com; s=arc-20160816; b=ccaR3oquskjdbx12l4rOOVLYOT/YxSscZxt/JKgnVKc8446BpIftbFRWE9wI6nIES3 SjCU7rweepQ15vB6yoiaGH/rKX3o/ZXbiouk4zKX8CpKijD6hQs2/m/o9eeaM4rQx3wn mESVzQKabXcfSWNxsk2cHHJTOxBP1omSa7c+VicDRL276p7I8wgCuP0HH8+pvhZp/MZt n69th4pQda6hpw1Bj5sEMGKXh/LJV1tjD9vOOuFIYEzZWLTUcOFNfXgAIl27Hk+ndzBY QZfzskh9ZEqvkcG3HE8ZBUbnZpC7SwanQOgcfGNlmGw0YudYo1SPJISbyoISOf+gkiLK OJAQ== 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:to:from :dkim-signature; bh=IrGhWEKQHD91WCIwq4yDFYg/5pgZZ7O8t0XVlxnnwDY=; b=OJctoeByQz+AaTaI8Tyxt+Zy+fVWc8Pi6tlZgy/eKYZYJ8jHGvNl4eqvb6uP2eJcaO KckvWHe48PTgLKAif7g8Jjk4dDrberddLERnObtOjLCDIOG5ePMIVT5hTTQYe87EmglM 1dzp127NcN6QNCOy2skej4LHbAyv0Qxd5BLZISpGTvPolislmuUW01vAATGe665JURYf QnSmJT1aU/Fh88vnxeWdDCzir5YN+ZLryMGq07U360gwXQFy0XV3gTgk37U3rXWVRLsq oG5rHhFw6ZU8xCOZ1ckSr1TTU+SYK0OABnPXHkJ59H9aFugPaWvcuIo9su3uy4zHXDqO 5vUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=iukJs6Qx; 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 j7-20020ac84047000000b003b844afef2dsi1502802qtl.687.2023.02.22.15.29.33 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 22 Feb 2023 15:29:34 -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=iukJs6Qx; 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 1pUyWV-0000Ud-T3; Wed, 22 Feb 2023 18:27:43 -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 1pUyWU-0000U2-Mt for qemu-devel@nongnu.org; Wed, 22 Feb 2023 18:27:42 -0500 Received: from mail-pj1-x1030.google.com ([2607:f8b0:4864:20::1030]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pUyWT-0005JA-03 for qemu-devel@nongnu.org; Wed, 22 Feb 2023 18:27:42 -0500 Received: by mail-pj1-x1030.google.com with SMTP id x34so7425197pjj.0 for ; Wed, 22 Feb 2023 15:27:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=IrGhWEKQHD91WCIwq4yDFYg/5pgZZ7O8t0XVlxnnwDY=; b=iukJs6QxQ/4DwfwbMsCcTKW3YrcibzHv8DnNeX5G8UlPGaGNykExO+wijmocTv/3d8 XanJ5LHCUo/RYzHL0y/SOZsn1C0TGDyNGw7tF7lfPP9TRs49fPz19ws+jIsNrqjG9dD0 ie71GgWTt70Hq2iVVNg1rHyd/DrpjKT5iZc6Wv5btj5DxxslwJV31kvTgZvzQ/W+AWKQ 1NVtfRZQ3IPQkVXntcT50VEHr3JijEFUwPruEnG5yEOSarljdlv+G0CzySi9Amcu3mW5 3qG7RJfaYYdcUlz13bfBmNHUAew6wIojeMBue/g6M/tqH5vYdNfYGn0OYYHr233bl72p P1KA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=IrGhWEKQHD91WCIwq4yDFYg/5pgZZ7O8t0XVlxnnwDY=; b=iUfpy480dKOZvWeZJ1Kd/J1A+r8Nvf6eLhNsuES6fDhjSckdj33tCbyTBwItkXVqjr GdboN5+VClsrvtpKQlIELka4w2vXVU3VTBcxnLBs/DnKVkd+4kcd4KoYZeGrbvNTwe0E 2vVa+uw/D4EgHbI0b1rqGa31ryg0jqKbkMyxtLYr433wpVDx/JSVuagIRHCoxzh5/8Zb y/zK2U3yYrb0vL8RulJt4mVhkbYKfR8eXjEDE1K3Nqy3bo/OKGmxmsMznluXwybskx1O LaUQbmqF46ISKT+uEClv9HnWOJ4/77NP/s0uVaUiRKKx0ZoFjZPhow49KQ/KWQgXFY4X jhrA== X-Gm-Message-State: AO0yUKX74+gLRqBWAENOydjDiaIA5o3mapoh1V/HxPYhmpUTC+3+wn5A zyylxvQkGpRFG2bLwi1e7vs0kebe+iUHQHiS7Cc= X-Received: by 2002:a17:90b:3b87:b0:233:fb7d:846c with SMTP id pc7-20020a17090b3b8700b00233fb7d846cmr10719091pjb.9.1677108460182; Wed, 22 Feb 2023 15:27:40 -0800 (PST) Received: from stoup.. (rrcs-173-198-77-218.west.biz.rr.com. [173.198.77.218]) by smtp.gmail.com with ESMTPSA id s16-20020a17090ad49000b00234e6d2de3dsm5008918pju.11.2023.02.22.15.27.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Feb 2023 15:27:39 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH v2 16/28] target/arm: Drop copies in gen_sve_{ldr,str} Date: Wed, 22 Feb 2023 13:27:03 -1000 Message-Id: <20230222232715.15034-17-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230222232715.15034-1-richard.henderson@linaro.org> References: <20230222232715.15034-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1030; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x1030.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+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Since we now get TEMP_TB temporaries by default, we no longer need to make copies across these loops. These were the only uses of new_tmp_a64_local(), so remove that as well. Signed-off-by: Richard Henderson Reviewed-by: Peter Maydell --- target/arm/translate-a64.h | 1 - target/arm/translate-a64.c | 6 ------ target/arm/translate-sve.c | 32 -------------------------------- 3 files changed, 39 deletions(-) diff --git a/target/arm/translate-a64.h b/target/arm/translate-a64.h index ad3762d1ac..ca24c39dbe 100644 --- a/target/arm/translate-a64.h +++ b/target/arm/translate-a64.h @@ -19,7 +19,6 @@ #define TARGET_ARM_TRANSLATE_A64_H TCGv_i64 new_tmp_a64(DisasContext *s); -TCGv_i64 new_tmp_a64_local(DisasContext *s); TCGv_i64 new_tmp_a64_zero(DisasContext *s); TCGv_i64 cpu_reg(DisasContext *s, int reg); TCGv_i64 cpu_reg_sp(DisasContext *s, int reg); diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c index da9f877476..300248a0ad 100644 --- a/target/arm/translate-a64.c +++ b/target/arm/translate-a64.c @@ -436,12 +436,6 @@ TCGv_i64 new_tmp_a64(DisasContext *s) return s->tmp_a64[s->tmp_a64_count++] = tcg_temp_new_i64(); } -TCGv_i64 new_tmp_a64_local(DisasContext *s) -{ - assert(s->tmp_a64_count < TMP_A64_MAX); - return s->tmp_a64[s->tmp_a64_count++] = tcg_temp_local_new_i64(); -} - TCGv_i64 new_tmp_a64_zero(DisasContext *s) { TCGv_i64 t = new_tmp_a64(s); diff --git a/target/arm/translate-sve.c b/target/arm/translate-sve.c index 621a2abb22..02150d93e8 100644 --- a/target/arm/translate-sve.c +++ b/target/arm/translate-sve.c @@ -4344,17 +4344,6 @@ void gen_sve_ldr(DisasContext *s, TCGv_ptr base, int vofs, TCGLabel *loop = gen_new_label(); TCGv_ptr tp, i = tcg_const_local_ptr(0); - /* Copy the clean address into a local temp, live across the loop. */ - t0 = clean_addr; - clean_addr = new_tmp_a64_local(s); - tcg_gen_mov_i64(clean_addr, t0); - - if (base != cpu_env) { - TCGv_ptr b = tcg_temp_local_new_ptr(); - tcg_gen_mov_ptr(b, base); - base = b; - } - gen_set_label(loop); t0 = tcg_temp_new_i64(); @@ -4370,11 +4359,6 @@ void gen_sve_ldr(DisasContext *s, TCGv_ptr base, int vofs, tcg_gen_brcondi_ptr(TCG_COND_LTU, i, len_align, loop); tcg_temp_free_ptr(i); - - if (base != cpu_env) { - tcg_temp_free_ptr(base); - assert(len_remain == 0); - } } /* @@ -4445,17 +4429,6 @@ void gen_sve_str(DisasContext *s, TCGv_ptr base, int vofs, TCGLabel *loop = gen_new_label(); TCGv_ptr tp, i = tcg_const_local_ptr(0); - /* Copy the clean address into a local temp, live across the loop. */ - t0 = clean_addr; - clean_addr = new_tmp_a64_local(s); - tcg_gen_mov_i64(clean_addr, t0); - - if (base != cpu_env) { - TCGv_ptr b = tcg_temp_local_new_ptr(); - tcg_gen_mov_ptr(b, base); - base = b; - } - gen_set_label(loop); t0 = tcg_temp_new_i64(); @@ -4471,11 +4444,6 @@ void gen_sve_str(DisasContext *s, TCGv_ptr base, int vofs, tcg_gen_brcondi_ptr(TCG_COND_LTU, i, len_align, loop); tcg_temp_free_ptr(i); - - if (base != cpu_env) { - tcg_temp_free_ptr(base); - assert(len_remain == 0); - } } /* Predicate register stores can be any multiple of 2. */