From nobody Wed Nov 19 22:25:39 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; 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=fail(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1618600948; cv=none; d=zohomail.com; s=zohoarc; b=SW8Gr7BGLDuUaBQwqNb2K87Y2h5t6vj0B0Pgpch5RPVAmi8JUrlxWDqcd3a0EKrX3lUxkYIVokDaKtaINzh6kkg5jC9bUZRvGR3tImBHbJsfE8UwZcokqIFH7Q0gY4/sqiQR8rK9elIgx1sgmEFYJRJtvQXpjyDr7JkfuJ6VDww= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1618600948; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=zsvdYXq6ehB6Yi/U879OLLmvPBBL5YJ5lhH9C+FI0w0=; b=KM8d14hXJ4WMVXIoezsiQvQWtDxWy4HT7NEMyKFcOqmwgX8AuZx6Sck3c3vNBxxdkZqBh6KRaC/KhRxsjlip3m3Ys+MXIMuu514+eCB7PXniqnaYUOulImspQHuRCg+r/0RSR9L0TGAHg2dH+g/lluvuUB/6F96k9V/B6VJLYOA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; 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=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1618600948020326.4225693746158; Fri, 16 Apr 2021 12:22:28 -0700 (PDT) Received: from localhost ([::1]:47220 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lXU2r-0008UH-Sd for importer@patchew.org; Fri, 16 Apr 2021 15:22:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50714) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lXTiD-00046x-K6 for qemu-devel@nongnu.org; Fri, 16 Apr 2021 15:01:05 -0400 Received: from mail-pg1-x532.google.com ([2607:f8b0:4864:20::532]:37501) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lXThf-0004VK-21 for qemu-devel@nongnu.org; Fri, 16 Apr 2021 15:01:05 -0400 Received: by mail-pg1-x532.google.com with SMTP id p2so4355076pgh.4 for ; Fri, 16 Apr 2021 12:00:30 -0700 (PDT) Received: from localhost.localdomain ([71.212.131.83]) by smtp.gmail.com with ESMTPSA id d7sm1988337pfv.197.2021.04.16.12.00.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 16 Apr 2021 12:00:28 -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=zsvdYXq6ehB6Yi/U879OLLmvPBBL5YJ5lhH9C+FI0w0=; b=HCKE/RTuzwdMoopodiWGlcV8Lg6/4kqC1kjNOZUBCv8qF8BO9rrGeSx4+F12t2epvN UiogMdj92B8uWMzXd9fOhPtnGLHZ4LWjrU2FL2D/C2LZGGmwhSlVn6gFNsdV85CydOfc 5LQMmRCrT3g5+REKRVrn5xi2B1bKRMTcoT047+6uGrZAHlP/fcyVT30Qjlj0Cvj6Bssa Zrk76TWWNUXZRZdySZkaGs8KnMJXqlbD4TKq1I/ICdiwQCrAo+ZbZj+QESsHuMBbqOZh sCHQRt3gSaAs5SsJ6sSaUOx096/abAfOA60ON2fVqbb59QSe3x4T9iX6H7zRhpHsR21p yzIQ== 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=zsvdYXq6ehB6Yi/U879OLLmvPBBL5YJ5lhH9C+FI0w0=; b=SkWuF3GrBXx4HUWv4CmdWGyrpBpy1x+hUVJDK4dpijkdWdoL1R/NsCrhKB9NGWITCK 7NKejx74Q8CKzkszObwrB4atb8f7dClylMOO0Cc6goNprw5sAjkjIrbBMPS2J8JyCU// VhEdI/Eb6Kp/d5iyvoMU+A8yLP1Kh2d3pztQKWTMswYfIJG6RXBaH8gMB830EZ+Oi0wF fiT1SVYb5lPvXU4skW0SCVJEl7X2X5A+FACZvWQw2pFfa/HwEhidkaCYP47tP+VpRgTP 9iuQC44D6GIgkHNiT2tHi9cohzZ2qRhH+bS/+X+sGbMNfWWz/bWr06ECpyzyhjv7zAqQ 9hGA== X-Gm-Message-State: AOAM532BBTjcMVhYXTmlIuotpJj1TQyn9E51VbgRsW7ZysB/d9UcjYWv M+O3n4mT/OCDFtjCZAedXhRf1fvD/w1R+A== X-Google-Smtp-Source: ABdhPJyQxrXYfmqyw1BF7L6JhIRpSe0ej4pyOzzAq42boyTQJNrtr2akjzRfuGIr1nFYifD9oqM6Og== X-Received: by 2002:a63:5004:: with SMTP id e4mr466189pgb.61.1618599629297; Fri, 16 Apr 2021 12:00:29 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH v4 29/30] target/arm: Enforce alignment for aa64 vector LDn/STn (single) Date: Fri, 16 Apr 2021 11:59:58 -0700 Message-Id: <20210416185959.1520974-30-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210416185959.1520974-1-richard.henderson@linaro.org> References: <20210416185959.1520974-1-richard.henderson@linaro.org> MIME-Version: 1.0 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::532; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x532.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=unavailable 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 , qemu-arm@nongnu.org Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" Reviewed-by: Peter Maydell Signed-off-by: Richard Henderson --- target/arm/translate-a64.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c index 2a82dbbd6d..95897e63af 100644 --- a/target/arm/translate-a64.c +++ b/target/arm/translate-a64.c @@ -3815,6 +3815,7 @@ static void disas_ldst_single_struct(DisasContext *s,= uint32_t insn) int index =3D is_q << 3 | S << 2 | size; int xs, total; TCGv_i64 clean_addr, tcg_rn, tcg_ebytes; + MemOp mop; =20 if (extract32(insn, 31, 1)) { unallocated_encoding(s); @@ -3876,6 +3877,7 @@ static void disas_ldst_single_struct(DisasContext *s,= uint32_t insn) =20 clean_addr =3D gen_mte_checkN(s, tcg_rn, !is_load, is_postidx || rn != =3D 31, total); + mop =3D finalize_memop(s, scale); =20 tcg_ebytes =3D tcg_const_i64(1 << scale); for (xs =3D 0; xs < selem; xs++) { @@ -3883,8 +3885,7 @@ static void disas_ldst_single_struct(DisasContext *s,= uint32_t insn) /* Load and replicate to all elements */ TCGv_i64 tcg_tmp =3D tcg_temp_new_i64(); =20 - tcg_gen_qemu_ld_i64(tcg_tmp, clean_addr, - get_mem_index(s), s->be_data + scale); + tcg_gen_qemu_ld_i64(tcg_tmp, clean_addr, get_mem_index(s), mop= ); tcg_gen_gvec_dup_i64(scale, vec_full_reg_offset(s, rt), (is_q + 1) * 8, vec_full_reg_size(s), tcg_tmp); @@ -3892,9 +3893,9 @@ static void disas_ldst_single_struct(DisasContext *s,= uint32_t insn) } else { /* Load/store one element per register */ if (is_load) { - do_vec_ld(s, rt, index, clean_addr, scale | s->be_data); + do_vec_ld(s, rt, index, clean_addr, mop); } else { - do_vec_st(s, rt, index, clean_addr, scale | s->be_data); + do_vec_st(s, rt, index, clean_addr, mop); } } tcg_gen_add_i64(clean_addr, clean_addr, tcg_ebytes); --=20 2.25.1