From patchwork Wed Oct 13 18:22:28 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 515742 Delivered-To: patch@linaro.org Received: by 2002:ac0:b5cc:0:0:0:0:0 with SMTP id x12csp125311ime; Wed, 13 Oct 2021 11:31:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEPJu1bGfxWVXfthtCP3lAfOTN4jsoeIb8ltMoqrXttp2W8w3QOFTlMJl0gZ+f+XPxag60 X-Received: by 2002:a37:658b:: with SMTP id z133mr795176qkb.101.1634149868396; Wed, 13 Oct 2021 11:31:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634149868; cv=none; d=google.com; s=arc-20160816; b=Oa3tSBbTSbRM4cBg8CQdmRdOz8fb6rmYDFLkIAZn1A0xROxr0ovyXj3k5kwgPW0t7Z y9TqWPIoBtNT1bIognutBhkwm46QlJ95dbrnNSLol1GRq9pteML4SRmERI8FDgLxHC33 s9MieIQa5qI5NFBMPDM/KeHFCWkX51gA7XrFo3nJCoeQZ85a4+IHQ1xBIFCuToYp51fk 7+ukerTt4mX6RfquLeItD2mW0IrFLCLg1cUwrjD6gnug6mPfPPu7eckuQb/CUzjp1dpe GCdNP19MMJa7N3XJlm1K0c3hIOVVh61C7RlA31fLXx57XpBHeSFuBXMjABF9AZ7P+0/u N+pQ== 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=m31KIJw/lcLJxFk5HRMhG0LaXmCEuUD4FjCNknqYFfc=; b=LwzrJwdJhpFW1qQ86F+blHrvvpbGQbhJ4G+bVR/XUDTX4RIoL+AKsqtq5ZU3uJrRKE 7TxBYClTt/q2rMRmnXgl8nSn+L5XMXPsFjXclentHs5ng317ibyW7NKXrLl6mpzXDKcH nRPEUgSaFApUVBbHz02LRW4pd+zQLexYSupvFmIVN4FQD+gSEI75A5PDnVkNI09fj7d8 yGL2Q95USRuIvGuxShqkHYcTbQRNLcChlxn7QQWWOFdoZjHhNSI+tCsAYQBSXnc2k1Wu Ih8QBsQnsCel9abEQzbsYhuqcc8Y00ONPezS6VNTHvD/5WWKnVLKu3k7vJo7uzf2bvlk OsVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oeJQwUSO; 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 y26si289734qtf.87.2021.10.13.11.31.08 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Oct 2021 11:31:08 -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=oeJQwUSO; 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]:60554 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1maj1v-0006mt-LF for patch@linaro.org; Wed, 13 Oct 2021 14:31:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36794) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1maitz-0003pG-I2 for qemu-devel@nongnu.org; Wed, 13 Oct 2021 14:22:55 -0400 Received: from mail-pl1-x62b.google.com ([2607:f8b0:4864:20::62b]:41700) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1maitr-00030x-Vh for qemu-devel@nongnu.org; Wed, 13 Oct 2021 14:22:51 -0400 Received: by mail-pl1-x62b.google.com with SMTP id x8so2402972plv.8 for ; Wed, 13 Oct 2021 11:22:47 -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=m31KIJw/lcLJxFk5HRMhG0LaXmCEuUD4FjCNknqYFfc=; b=oeJQwUSO9UdADn0cpOrNekaNIRjl0tTpSnYpmj6ZLGnaSR7lw8Hme1QX0yzcIJq+tG yrN34k55VlnL3vR+mM+CVUiLJ0ViqSUlg3aZcIaqSnXRNyE3eMCwLQcovSz7ETTIv9a5 Lsh323IPIQTjPHhtB7TSzsb1sj+qoCC5BJ/fa/7FXPD369PRJWTPF7P5GrgVHwrBGNfM 276/ZjKpq+DaoM96dfqKQyME2ggml35k7k1u9uozW1ASFFqBD271V4dYJYToyBcvCb2D NxrLo04WEBw8q2q5V7DRHe6qkjYwJ9wYgihdZnm7nIMnPDJ85r1EfuPXUrNRbzt3sHwu /e3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=m31KIJw/lcLJxFk5HRMhG0LaXmCEuUD4FjCNknqYFfc=; b=68HbBkPMQZNTl5fvQPa6WTEi7eaklt+EnGc4R2nzc974lfNhIUaQqfkNzKo0cSAY+J qyBFh/2saveOaxnc3B0+arGlNC6TRJ1Jwh7IOki46vGp2z+DDYWFVdpOWe+gUQLBS1ci jexeoyqutY0tko3YLgfVU0cfJ6wDscup0IYldoPf1vPoO4iU2BMrT6M6GFFKZxXM85Bw KGtNPUgVsxjp2XV/2tQRK5ZViG91N57u6UrGJaNKbkf+E3Lvj1M7Oqjrf66bdxSquZaT +2cjdjhXpX54nxAIELcLWt7uPy5HH8+vY8NJbyNFAl2ADxY5ubuI12O0oBtbTFwCeKMR jHuA== X-Gm-Message-State: AOAM532kGKH6LqdKWR4S+LBExo/rI1JvSiKkXVFT7D+86v3JnJHNcr3d e4b+rR8/ZfMv2LlnOYTGj+YfyoOyy42MpA== X-Received: by 2002:a17:90a:a41:: with SMTP id o59mr15362292pjo.243.1634149366647; Wed, 13 Oct 2021 11:22:46 -0700 (PDT) Received: from localhost.localdomain ([71.212.134.125]) by smtp.gmail.com with ESMTPSA id z2sm177140pfe.210.2021.10.13.11.22.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Oct 2021 11:22:46 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 04/15] target/ppc: Use MO_128 for 16 byte atomics Date: Wed, 13 Oct 2021 11:22:28 -0700 Message-Id: <20211013182239.991127-5-richard.henderson@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211013182239.991127-1-richard.henderson@linaro.org> References: <20211013182239.991127-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62b; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x62b.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-ppc@nongnu.org, =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" Cc: qemu-ppc@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- target/ppc/translate.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) -- 2.25.1 diff --git a/target/ppc/translate.c b/target/ppc/translate.c index b985e9e55b..9ca78ee156 100644 --- a/target/ppc/translate.c +++ b/target/ppc/translate.c @@ -3462,10 +3462,12 @@ static void gen_std(DisasContext *ctx) if (HAVE_ATOMIC128) { TCGv_i32 oi = tcg_temp_new_i32(); if (ctx->le_mode) { - tcg_gen_movi_i32(oi, make_memop_idx(MO_LEQ, ctx->mem_idx)); + tcg_gen_movi_i32(oi, make_memop_idx(MO_LE | MO_128, + ctx->mem_idx)); gen_helper_stq_le_parallel(cpu_env, EA, lo, hi, oi); } else { - tcg_gen_movi_i32(oi, make_memop_idx(MO_BEQ, ctx->mem_idx)); + tcg_gen_movi_i32(oi, make_memop_idx(MO_BE | MO_128, + ctx->mem_idx)); gen_helper_stq_be_parallel(cpu_env, EA, lo, hi, oi); } tcg_temp_free_i32(oi); @@ -4067,11 +4069,11 @@ static void gen_lqarx(DisasContext *ctx) if (HAVE_ATOMIC128) { TCGv_i32 oi = tcg_temp_new_i32(); if (ctx->le_mode) { - tcg_gen_movi_i32(oi, make_memop_idx(MO_LEQ | MO_ALIGN_16, + tcg_gen_movi_i32(oi, make_memop_idx(MO_LE | MO_128 | MO_ALIGN, ctx->mem_idx)); gen_helper_lq_le_parallel(lo, cpu_env, EA, oi); } else { - tcg_gen_movi_i32(oi, make_memop_idx(MO_BEQ | MO_ALIGN_16, + tcg_gen_movi_i32(oi, make_memop_idx(MO_BE | MO_128 | MO_ALIGN, ctx->mem_idx)); gen_helper_lq_be_parallel(lo, cpu_env, EA, oi); } @@ -4122,7 +4124,7 @@ static void gen_stqcx_(DisasContext *ctx) if (tb_cflags(ctx->base.tb) & CF_PARALLEL) { if (HAVE_CMPXCHG128) { - TCGv_i32 oi = tcg_const_i32(DEF_MEMOP(MO_Q) | MO_ALIGN_16); + TCGv_i32 oi = tcg_const_i32(DEF_MEMOP(MO_128) | MO_ALIGN); if (ctx->le_mode) { gen_helper_stqcx_le_parallel(cpu_crf[0], cpu_env, EA, lo, hi, oi);