From patchwork Wed Nov 25 04:06:33 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 332356 Delivered-To: patch@linaro.org Received: by 2002:a92:5e16:0:0:0:0:0 with SMTP id s22csp122718ilb; Tue, 24 Nov 2020 20:09:26 -0800 (PST) X-Google-Smtp-Source: ABdhPJxv9zVzIW6s0Hc5SbX2sH3ctQzv8NXOEJ+25Hwf0A9scRLQ68xXDKsxWhjB3kthYv4BiW11 X-Received: by 2002:a25:8401:: with SMTP id u1mr2567726ybk.96.1606277366422; Tue, 24 Nov 2020 20:09:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606277366; cv=none; d=google.com; s=arc-20160816; b=Zbp8dA6v6oBc+GQyjGWH9/98DajgBxmm9+xWm2i9spLrWIdTfRxp8UqdRIb0Ipn/wX rTHmRnpbc2tca+XZEm40VU7GO2z8AJ9/waJKgtVOMK3mnDo4xh64y66Fh+HaSiFqGTpf mA6VOFLt/kH7bFORgvRxFgNi9h8hwLX1nOs4h3bEW+l9qHEkP7e7sgU+OvgsFUxfU1hx 7IovGDsDtqiqFh8+Ubzszs8ATiXfIoZILrfZfsOlZHSqAmJF03vKKbKbiMi9oWXga+Do vLOf22VGQKcHmoTSFq1f/lgPYSkINbcOri9ueh1hpAzqOCfg5RDOwjygzDUWgmC+ZXtw VM0g== 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=dUvIZnJazJaOEZboAW1OJSDBnVf8XIUz/RaJk/SSM4M=; b=ulS9Ac1v/hM1sxYK0BRLlECIdZVClls4yXXkxzfwnaSJ9MjcP8DVL+7mrv0Ua+DUqx YOr0s3RDyzX7sq7Si6zAUbFwxSAhm8BtDUC8OQ/4oBSTXDeJEF3OFevKvjtjWiaxz4Az 5L8mfB/xLQNN18Dj5J4LgG9t54FD6ZQfu31sur12laAi3JWuE6iKpCTxApyVa73moF5A e8LIW0S4ULdj6sIeXlbHAdRd0ybtzTQJYiZCRY/thfGIu6WTrEe8udxciZ+CFtaLbQuj JCBeGL2imWaNpCUSsM4PxRq/Mwe2KyXRM+tsrgieCyFd8rBL3BjWNpswZvmG4lOEB36P 1YsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gKo6nG+2; 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 v14si1037144ybl.215.2020.11.24.20.09.26 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 24 Nov 2020 20:09:26 -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=gKo6nG+2; 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]:52584 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1khm7R-0008EQ-S2 for patch@linaro.org; Tue, 24 Nov 2020 23:09:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:36082) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1khm4w-0004gN-Sc for qemu-devel@nongnu.org; Tue, 24 Nov 2020 23:06:50 -0500 Received: from mail-pl1-x641.google.com ([2607:f8b0:4864:20::641]:34484) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1khm4v-00061p-Dg for qemu-devel@nongnu.org; Tue, 24 Nov 2020 23:06:50 -0500 Received: by mail-pl1-x641.google.com with SMTP id l11so464441plt.1 for ; Tue, 24 Nov 2020 20:06:49 -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=dUvIZnJazJaOEZboAW1OJSDBnVf8XIUz/RaJk/SSM4M=; b=gKo6nG+2jXZE3ogTrnzyGe3McgptHnSF8F6CBBoMM2Q1cJxRZP3ua3mgjowIt5vE0k 6/P+GHygWDH8cuUMEizCIhUO+NAGIEdLWg5j9m3fZE+8DXpLtvMpTRnqTOOvZj5F/5du kY6L/SlyQUevSvHLir/mAQSfl8ImPXj+jQ9EYnBVWKgyX5HDxj9MQp2hUoZ7ILfFNS1C vg2y0LoVj5dEC9I/fp3r0wh6Ts48kwG0FOu4ocODVVPAqYVXiLdcndY5i5Nf6uUgZ6zu z6o2nnk17tpk61aCnII1ZMBu11tYs9VM9ePmcRs2xRYPM+grCB1wB/dhLDmEP3b2HZ02 hFTQ== 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=dUvIZnJazJaOEZboAW1OJSDBnVf8XIUz/RaJk/SSM4M=; b=at7lNpP/hhE73C8cwWNxLSZD7JLd9gpCHMU16dh6zSXnlB9K8LHMlOGOd+TKa8+QIe PiMdeLu2m2D9Q6yEKhc3ujMS+jV4iWX5djOaylChBrN68ThTHZ5HRnVWOkEEHJvte1NV V2Fkct2agvLEI/XPG5ISu39qJdRueKTDNwrZzUqbEQBwufU51p12fIgcrzKA3izIwxQ6 GQvTdJ+ThzY7VYfpjDeRNxfI9qdCduYQYWWbZKGQv5+F579HiqKsJfKAUOnwVsMLgi0O U8YKMU+CLAN1B6ag0ME6mOL8cJW3UONDb5jLajSg3xDxDygtDrDBAZws9X9aEYvdtP2l WpqQ== X-Gm-Message-State: AOAM530APYbN0wEoGGhUV1y96SqSEZohWV/mR/HxoVjYaxD384DrCe1l WCqFxhautEFPwHVc2lKy6zi/DYkI7UN2dg== X-Received: by 2002:a17:902:9a8e:b029:d8:d989:4f80 with SMTP id w14-20020a1709029a8eb02900d8d9894f80mr1514185plp.32.1606277207801; Tue, 24 Nov 2020 20:06:47 -0800 (PST) Received: from localhost.localdomain ([71.212.141.89]) by smtp.gmail.com with ESMTPSA id f7sm447806pfe.30.2020.11.24.20.06.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Nov 2020 20:06:47 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PATCH 02/11] target/arm: Enforce alignment for LDA/LDAH/STL/STLH Date: Tue, 24 Nov 2020 20:06:33 -0800 Message-Id: <20201125040642.2339476-3-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::641; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x641.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: 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.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.25.1 Reviewed-by: Philippe Mathieu-Daudé diff --git a/target/arm/translate.c b/target/arm/translate.c index 17883d00f4..73b3d8cbbf 100644 --- a/target/arm/translate.c +++ b/target/arm/translate.c @@ -6876,7 +6876,7 @@ static bool op_stl(DisasContext *s, arg_STL *a, MemOp mop) static bool trans_STL(DisasContext *s, arg_STL *a) { - return op_stl(s, a, MO_UL); + return op_stl(s, a, MO_UL | MO_ALIGN); } static bool trans_STLB(DisasContext *s, arg_STL *a) @@ -6886,7 +6886,7 @@ static bool trans_STLB(DisasContext *s, arg_STL *a) static bool trans_STLH(DisasContext *s, arg_STL *a) { - return op_stl(s, a, MO_UW); + return op_stl(s, a, MO_UW | MO_ALIGN); } static bool op_ldrex(DisasContext *s, arg_LDREX *a, MemOp mop, bool acq) @@ -7033,7 +7033,7 @@ static bool op_lda(DisasContext *s, arg_LDA *a, MemOp mop) static bool trans_LDA(DisasContext *s, arg_LDA *a) { - return op_lda(s, a, MO_UL); + return op_lda(s, a, MO_UL | MO_ALIGN); } static bool trans_LDAB(DisasContext *s, arg_LDA *a) @@ -7043,7 +7043,7 @@ static bool trans_LDAB(DisasContext *s, arg_LDA *a) static bool trans_LDAH(DisasContext *s, arg_LDA *a) { - return op_lda(s, a, MO_UW); + return op_lda(s, a, MO_UW | MO_ALIGN); } /*