From patchwork Wed Nov 25 04:06:37 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 332357 Delivered-To: patch@linaro.org Received: by 2002:a92:5e16:0:0:0:0:0 with SMTP id s22csp123066ilb; Tue, 24 Nov 2020 20:10:16 -0800 (PST) X-Google-Smtp-Source: ABdhPJxwJeIjhRXodi873uUlA6zaBxHFEnK6FhqEBKQPYKmkRtH+ix4x17tOHUaCJRTG955SqpXL X-Received: by 2002:a25:df82:: with SMTP id w124mr1762100ybg.347.1606277416374; Tue, 24 Nov 2020 20:10:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606277416; cv=none; d=google.com; s=arc-20160816; b=ke3HNoRRS+y8fTbsIvyEqjFjFwXeeTfeEN7YSMwyWY1nkm3NOaJE4fivDiJDvOxUEx /hV+0H7TkE0zII40L9vt4MFvjkoONfwM1PN98t+DqlCooyD9ahq6giuwYZvoYWNga6ZF Z62AkwCs7zhLXOV7iFGMXorziRIh6j6mW1hwe5AyHbqjrMr34d3HHBAq41+r2FqH+6zE f9JENgpbkQ29U5VCORYmPqBK9q+Ak+sMA10p88KYDtHe/+CI45s218KRqIzsx7xgLmpd AarXt+b8d669Fg/tBSQYsEMBjP0JLkBg95Xnf9uH380a1G5MA/SfLt5Vrr1Ojxk4f56b Ktig== 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=Wu5Kt3iN7e6z3sUpws6R3XP7/Dj8XZZymOVS+ThDJek=; b=ZFOGAJ7S+3sAIPYZ1DlxWxJ0BiU4YBrAnFJF0jXajoPbIJbvATxneQgNfxiQ8Tp7Zt xXED+e0GCuQUQeTW8JV5vweXvJ8nae2QRDQdcte13fVnRdU4jM/HCNjpTpfC5JQseA+Z GQTnMgzJCzs/oq8LYzR71lYn37z9WSonm/gEFLUGrpG6L/mJGHcum8RD1gtEnvaxefBJ tF3FeUSIMjG9OUfZMIwegb+3ndNYGlgvW4LJgiTVWnLbPHUDDWqCds7eNplPgjsgEjNQ QBJmLwleftTfskbEpEZjkJvF6ZzEz6YX2IfE5m4AGaaTwtcKBDNykqNWTVF29zOYYqDx 7ZFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="G/ezqJF/"; 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 e73si1154186ybf.56.2020.11.24.20.10.16 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 24 Nov 2020 20:10:16 -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="G/ezqJF/"; 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]:54244 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1khm8F-0000Sl-SV for patch@linaro.org; Tue, 24 Nov 2020 23:10:15 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:36192) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khm51-0004t9-RV for qemu-devel@nongnu.org; Tue, 24 Nov 2020 23:06:55 -0500 Received: from mail-pf1-x443.google.com ([2607:f8b0:4864:20::443]:41605) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1khm50-00063s-6S for qemu-devel@nongnu.org; Tue, 24 Nov 2020 23:06:55 -0500 Received: by mail-pf1-x443.google.com with SMTP id t8so1084502pfg.8 for ; Tue, 24 Nov 2020 20:06:53 -0800 (PST) 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=Wu5Kt3iN7e6z3sUpws6R3XP7/Dj8XZZymOVS+ThDJek=; b=G/ezqJF/80UzEjCfBVtjm4leY8YH0zUhtNhTnGWR4tGn6HtDRVkFqRtP1njB2uclMl 9F+uyGlUSao3mvwrsvIPQ/PVMW+iqZ/km7c2vSAV28ipiZgDfR/GI3dm97OKEc46xg8Y wFDEyVuRjnq17GRz/BGkai+EGR61jLkDIaObLnnsG/0jclZnl6Eiv5NteasbB5dtxdt8 TctK79qGJ6kuLfG/ell5UE3u6ub0cyPI48H1aVVniL+N5/4tGLm2tcYDyDNj3T+jLw8L BQKCYpUWNuhXAgwDeiNc2ymElUocG9ym+9+8t7QfaaOoAKg1+kPHjanQobWYtkN9nCG2 QazQ== 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=Wu5Kt3iN7e6z3sUpws6R3XP7/Dj8XZZymOVS+ThDJek=; b=c99FMGsYPRfr4iZY1xbHw6ep+UXsLbBUYWadkrM7aEKjFmVc2g5hKKB0UOhI6fLqKN fTl2FW9h64bps9zzn8mCXcRrfvO3o+WnxfidLTBzp3z4uFmBQhCEZz65MpgQFIUe+IPs J5iDEhrYUy6Pooezh3Mx+6WuCER6XEG8AnGbTVNYMjRl/gSC5Po3KEdxrm45ZUjeMerB IYcBbxlqXykm41truT565j4KBSzERtefAAVQpIu0qmTcN3VrV9FCf4oSyRw0NQYFrHjI JKgDy08wt74/rsUkgb7H9QIxgK1+0k8bjgtGXJXT46N1NXJEVBeUkjgXAlyQl8t58o+u oOeQ== X-Gm-Message-State: AOAM531K6vJ9bSXLNz7VpKuxM/cWxtGBoJQ3FiiFhqJYGvSS1VhND1UG 2z9R3a0Q/3Cbaj0Ekj8/ThoYUJar/qpKTw== X-Received: by 2002:a17:90a:e016:: with SMTP id u22mr1821185pjy.195.1606277212724; Tue, 24 Nov 2020 20:06:52 -0800 (PST) Received: from localhost.localdomain ([71.212.141.89]) by smtp.gmail.com with ESMTPSA id f7sm447806pfe.30.2020.11.24.20.06.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Nov 2020 20:06:52 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 06/11] target/arm: Enforce alignment for VLDM/VSTM Date: Tue, 24 Nov 2020 20:06:37 -0800 Message-Id: <20201125040642.2339476-7-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20201125040642.2339476-1-richard.henderson@linaro.org> References: <20201125040642.2339476-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::443; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x443.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: qemu-arm@nongnu.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Signed-off-by: Richard Henderson --- target/arm/translate-vfp.c.inc | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) -- 2.25.1 diff --git a/target/arm/translate-vfp.c.inc b/target/arm/translate-vfp.c.inc index 96948f5a2d..58b31ecc3f 100644 --- a/target/arm/translate-vfp.c.inc +++ b/target/arm/translate-vfp.c.inc @@ -1065,12 +1065,14 @@ static bool trans_VLDM_VSTM_sp(DisasContext *s, arg_VLDM_VSTM_sp *a) for (i = 0; i < n; i++) { if (a->l) { /* load */ - gen_aa32_ld32u(s, tmp, addr, get_mem_index(s)); + gen_aa32_ld_i32(s, tmp, addr, get_mem_index(s), + MO_UL | MO_ALIGN | s->be_data); vfp_store_reg32(tmp, a->vd + i); } else { /* store */ vfp_load_reg32(tmp, a->vd + i); - gen_aa32_st32(s, tmp, addr, get_mem_index(s)); + gen_aa32_st_i32(s, tmp, addr, get_mem_index(s), + MO_UL | MO_ALIGN | s->be_data); } tcg_gen_addi_i32(addr, addr, offset); } @@ -1148,12 +1150,14 @@ static bool trans_VLDM_VSTM_dp(DisasContext *s, arg_VLDM_VSTM_dp *a) for (i = 0; i < n; i++) { if (a->l) { /* load */ - gen_aa32_ld64(s, tmp, addr, get_mem_index(s)); + gen_aa32_ld_i64(s, tmp, addr, get_mem_index(s), + MO_Q | MO_ALIGN_4 | s->be_data); vfp_store_reg64(tmp, a->vd + i); } else { /* store */ vfp_load_reg64(tmp, a->vd + i); - gen_aa32_st64(s, tmp, addr, get_mem_index(s)); + gen_aa32_st_i64(s, tmp, addr, get_mem_index(s), + MO_Q | MO_ALIGN_4 | s->be_data); } tcg_gen_addi_i32(addr, addr, offset); }