From patchwork Thu Sep 22 16:34:59 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Peter Maydell X-Patchwork-Id: 608225 Delivered-To: patch@linaro.org Received: by 2002:a17:522:c983:b0:460:3032:e3c4 with SMTP id kr3csp450023pvb; Thu, 22 Sep 2022 09:45:28 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5uJQImVrp3NsYEOQVCy866JQueTlyi20KznKo+J07CQnXltOsecD00UGLPBlUg+eAwvAoZ X-Received: by 2002:ac8:5c14:0:b0:35c:c6c0:a9b8 with SMTP id i20-20020ac85c14000000b0035cc6c0a9b8mr3529437qti.601.1663865128427; Thu, 22 Sep 2022 09:45:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663865128; cv=none; d=google.com; s=arc-20160816; b=q7eJTTEZkuUqDgAji1H6sgVoMMxi3USB3WVrk/n51baUCWJ/4AA0bbd+isw2bq2p75 VDNzP4GZo4xE+j4O7LQlSXs+JCFeM5MkWg+NadeM8sszHG73s8Oj0eMsdbyKRdkbmyUS Fxn93fqDJeDQ9xLzPTraNxXTCm0f3yL4k5dhIZ/K8ggfSh677but3ba6kj23tPSIkP8I DahPE7L7OospzEaVcjDOCSiJsYoXNz+6oI1azqty6cfvxVnASrmv8vGinbXAGwkUiMjb 2XusuEtxA1tWU+kaV+YnzbrpFu2rrxNb4hFily459ZFLH8erYjY0mxe13F0bgFzk4OQj 0kDA== 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=SJ1E1DN8UXVJBqdhqjrjiz3vYmJMmUFOalTcFegGjrQ=; b=kfB50Y9wI3qaID0g+c5vYqmEQL9WQ98j2OSA7ybb1eqRmRJnyJnMHog6iyr2GjcWay 9s3vGyok6iK5bMa0Z9C3RKZibP/YdJ2C8p7+e6qU+UFXHKQM6ao6qUaxF7d6m5MgOYLd Cbj7DwPG8TSpTiglvLyfrLlSPL8oz1rae+vERZAio2SWBJzrqcMZ06/wfzwXypDTnqz/ eF/V8Ts1CArw/P9uVXzheGlrxyA8QnouQC32DdXGwOBfIsoSZHQ/Ga35EOStTvy0Fjoc Nq/mka/fHOkd+vfbbVCx6WC4g5gb5wcV78dOeuedjo/sKJCj4/TADbOtA3QRvNyIO1Kh 7gVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=axmsrd1d; 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 h4-20020a05620a400400b006cea264311asi3836416qko.693.2022.09.22.09.45.28 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 22 Sep 2022 09:45:28 -0700 (PDT) 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=axmsrd1d; 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]:47094 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1obPKI-0002xp-87 for patch@linaro.org; Thu, 22 Sep 2022 12:45:27 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48330) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1obPAs-00029p-QX for qemu-devel@nongnu.org; Thu, 22 Sep 2022 12:35:47 -0400 Received: from mail-wr1-x431.google.com ([2a00:1450:4864:20::431]:39869) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1obPAq-0005Nu-NB for qemu-devel@nongnu.org; Thu, 22 Sep 2022 12:35:42 -0400 Received: by mail-wr1-x431.google.com with SMTP id cc5so16439607wrb.6 for ; Thu, 22 Sep 2022 09:35:40 -0700 (PDT) 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; bh=SJ1E1DN8UXVJBqdhqjrjiz3vYmJMmUFOalTcFegGjrQ=; b=axmsrd1dZZ8nN7yQ40caBOXFi7R+ZrgCi0oTF1SBQ9xmRxtJJxtmGNYQAgq7kxlTeN IMXPCLCr8FSxn46g9BI1iKOTNQm4x/a4YoJ5rD7Tvhwd/WZQ1g5Iz6WKOO3MZaeh6Lxh ZV0AFv64ADo0gmppyoYokL7rVB3a9l5GO/2fFzqam8B7QjD79ruwPaQKruXaVIBG+gsm 8Wzyw6VWtpvYZ2rglJzdsCIRyqPkl+GgyRjB9W3n/jPvUMJ1IeMcwe6MlcIz47o8t3Fe fyZi8029Z3nczwwNUak7t+4KjWdpb/lASJF6glI91jMpbZfkcbAzcd6eWwvzocodnHu/ pweQ== 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; bh=SJ1E1DN8UXVJBqdhqjrjiz3vYmJMmUFOalTcFegGjrQ=; b=5Em8D9GwOu/sLVKKPzjDgX2kbnzDFMSWjibMowoQsarS1cYAqi5ahA6K2PppEmCVLg Gi8BCpqLzGLc+bgeXh3mlCGJJNjSpxVzBeFDlVTEEdKU2sm/BYh9TDgaqIfhXUZHyp1i zxObjf1a90NmFKs2Y+6dFBRj7a//YzgfgTIExu1cm1Xkni+6ALJXKX+PZk7gIrHUgpGK kN6M36ndFhN3tKVHIG2SWdpYxMci8ERW3vbK8HsivUv0ueGnYPGU6+zxQtWMZzrVSFw0 NQMekzAFb+9KE+bNV9pjaU7kZSYzZdEmLYTst2nQF7Pbf10RDGZkmAZ2k9vf8wBKeL+G PrVA== X-Gm-Message-State: ACrzQf07DAcmWdmJa6AVbbKaV+EGWHzCEOIoJQq3rrLHf8yn2aLrObi8 bR3MYJ1/UZvMJ1IXtoTRudLZBkCmpOse9w== X-Received: by 2002:adf:a50e:0:b0:22a:ede1:57e with SMTP id i14-20020adfa50e000000b0022aede1057emr2541427wrb.63.1663864539317; Thu, 22 Sep 2022 09:35:39 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [2001:8b0:1d0::2]) by smtp.gmail.com with ESMTPSA id iw1-20020a05600c54c100b003b3401f1e24sm6452599wmb.28.2022.09.22.09.35.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Sep 2022 09:35:39 -0700 (PDT) From: Peter Maydell To: qemu-devel@nongnu.org Subject: [PULL 02/39] target/arm: Fix alignment for VLD4.32 Date: Thu, 22 Sep 2022 17:34:59 +0100 Message-Id: <20220922163536.1096175-3-peter.maydell@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220922163536.1096175-1-peter.maydell@linaro.org> References: <20220922163536.1096175-1-peter.maydell@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::431; envelope-from=peter.maydell@linaro.org; helo=mail-wr1-x431.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" From: Clément Chigot When requested, the alignment for VLD4.32 is 8 and not 16. See ARM documentation about VLD4 encoding: ebytes = 1 << UInt(size); if size == '10' then alignment = if a == '0' then 1 else 8; else alignment = if a == '0' then 1 else 4*ebytes; Signed-off-by: Clément Chigot Reviewed-by: Richard Henderson Message-id: 20220914105058.2787404-1-chigot@adacore.com Signed-off-by: Peter Maydell --- target/arm/translate-neon.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/target/arm/translate-neon.c b/target/arm/translate-neon.c index 321c17e2c7e..4016339d46f 100644 --- a/target/arm/translate-neon.c +++ b/target/arm/translate-neon.c @@ -584,7 +584,11 @@ static bool trans_VLD_all_lanes(DisasContext *s, arg_VLD_all_lanes *a) case 3: return false; case 4: - align = pow2_align(size + 2); + if (size == 2) { + align = pow2_align(3); + } else { + align = pow2_align(size + 2); + } break; default: g_assert_not_reached();