From patchwork Tue Aug 22 11:01:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 715740 Delivered-To: patch@linaro.org Received: by 2002:adf:f747:0:b0:317:ecd7:513f with SMTP id z7csp192790wrp; Tue, 22 Aug 2023 04:03:28 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEy/hcNluVqpIGuLpv1jiIgoRQops6QHTtmgqfhNrXb9lbvbE0H9ge9srbWcv05xuEhLyXL X-Received: by 2002:a0c:9cc6:0:b0:647:3387:fe48 with SMTP id j6-20020a0c9cc6000000b006473387fe48mr8277171qvf.48.1692702208030; Tue, 22 Aug 2023 04:03:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692702208; cv=none; d=google.com; s=arc-20160816; b=N8q/e6mh5RkWxDXf+c91qyXqWoqnAjkJW1kitNCXR84fwCFi53rBj1RmNobbRutLxP cL/MmyJ0QkThhXSqdGCFaE6F5ovdX+22Z4cFoq4xy0M9GPeJZhHx2Xhv2OMwboh6z4Bv o8GuAWGWbjbIWyVgn6lX8ejOD5bXF4SWMy/+BpVRmdLYSs3j0+t8O22LEo7hj3nP7qRY hwTNo8px02/DPvu2tCcdGLA9StupigCd6HT8s908mfo8yLOUOQvK/r03jsipwebgwPtF QaloBV6MKFO63f5pEyiBWGBK5QOf7QY2NZCA9CAwfZBcthhT7Zs4FAz9gzhNYhQwwgRP 5zNw== 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:cc:to :from:dkim-signature; bh=Atmx7i5fRW8XnKx5xE4DtcYf6nuKJy8oiwMSi9RhaeI=; fh=nNMMnsLJfx+wwcL6Hpjyue2kO7c5wJkFUZ+p5f7qT8I=; b=PR7zEa7vmeDo8HOgWPkVf0yWbe9Ea2AiZe4rIvuhOicdLLBAZIM3kq90szvat1IDZr FiXv1j4xnhovyv9AqmG+d3neamdX7HJocXQh4BEiGGdAyRdM0LkLuwZZVidDNvud2EUL xAnSfxFe1losjKLK+tx1obGNWzCWzGJV/kwT/EN9QTixC2TYo1kts3/3BywEMZ6rvx7J 3m19DaaXtv7Kqi0BdGjtJUuYMHSXJOVG11RhpHapzIGdlJosVRp8iWahHKjYZbToMQAk MAGtirDb2BjKNvcmnQ8WS3w9ZRUJc4E6ITxaJPKE9avHAx+xFhHwx/g0rg2L7DB57O2w vYAA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DYorDiCC; 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 t12-20020a0ce2cc000000b0064f36264cd3si3736001qvl.270.2023.08.22.04.03.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 22 Aug 2023 04:03: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=DYorDiCC; 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] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qYP9j-0006Se-9m; Tue, 22 Aug 2023 07:02:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qYP9H-0006Hl-8f for qemu-devel@nongnu.org; Tue, 22 Aug 2023 07:02:12 -0400 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qYP99-0003L4-E4 for qemu-devel@nongnu.org; Tue, 22 Aug 2023 07:02:10 -0400 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-3fef56f7223so11877955e9.3 for ; Tue, 22 Aug 2023 04:01:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1692702115; x=1693306915; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Atmx7i5fRW8XnKx5xE4DtcYf6nuKJy8oiwMSi9RhaeI=; b=DYorDiCC6zDmH3rqFYk/9pwrsrWWNUjRA/ght3xwkjFklcnQdpYFWvL+qkFjyrpzOR bK1c5yfkEibRK7NpzfOAI7nh64VO0CYbMTXp6fTu7y+Flpp3/QU3p+LHxGYrKwedSzl7 zJiSiIHsiTVcETt2Yp96OddYsq4Qk/K9Zy2r/loZVCvWOV2ARk87BXNCru4ne7gqBENU CZmxnReZEM+cNSaQjFpYDUvWxFjqs4vvIOzQlUPGeRC5hvaqiijEnphH1Kr9cU16yaYh s5iBTFDwesNDNGKLT+EmYmZ0ymSc8Mic+yi84AlnpV6X5WXPnNiHvKuuO0OcJLGzJnir c3rg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1692702115; x=1693306915; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Atmx7i5fRW8XnKx5xE4DtcYf6nuKJy8oiwMSi9RhaeI=; b=KzavGQYGo+sGAwDXXwpqDu7dNg/reMyPVCXxOjz0YUxmI9UlephBVsvF5qh28yxp3s N9mjCVCpA/XSO8nLA0kP14T1pwPKJkJcBhDorxPzWew6QjUHWA1D6m+WFg8i0G2kvow2 5llknSlFBasWD2Pkn3R7aIESmju0IcexYIsqskiOsIIZBtDoFgp8YtFk8hVpOQTKKfKk wSMsuIexI9ag0X10O1qqp/ZF8FM6bbOq9jRfeQwGVZP1b+Otttrm57TpsqtyhcR0IqSp kD0iRffhx12F7Va3obqZJRU0M042Eopy0Fl9J318IhxUgLDS5od4kkpBYz3GwPphmprK AHsQ== X-Gm-Message-State: AOJu0Yx2qJ21wTCwBsOOtUKX79ZAJM8uaVvB5aZa2mpw8n0cUoFy02MF HT7h7/cWZdw62ENIOfsbcoUtdXdBeWsIx1EZTGU6GQ== X-Received: by 2002:a1c:7303:0:b0:3fb:f0ef:4669 with SMTP id d3-20020a1c7303000000b003fbf0ef4669mr7074980wmb.17.1692702115000; Tue, 22 Aug 2023 04:01:55 -0700 (PDT) Received: from localhost.localdomain ([37.19.214.4]) by smtp.gmail.com with ESMTPSA id v6-20020a7bcb46000000b003fbb25da65bsm15668820wmj.30.2023.08.22.04.01.53 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 22 Aug 2023 04:01:54 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Aurelien Jarno , Xiaojuan Yang , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= , Aleksandar Rikalo , Yoshinori Sato , "Edgar E. Iglesias" , qemu-arm@nongnu.org, Peter Maydell , Jiaxun Yang , Song Gao Subject: [PATCH 3/6] target/microblaze: Use hswap_i32() in SWAPH opcode Date: Tue, 22 Aug 2023 13:01:26 +0200 Message-ID: <20230822110129.41022-4-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230822110129.41022-1-philmd@linaro.org> References: <20230822110129.41022-1-philmd@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32e; envelope-from=philmd@linaro.org; helo=mail-wm1-x32e.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-bounces+patch=linaro.org@nongnu.org Commit 46be8425ff ("tcg: Implement tcg_gen_{h,w}swap_{i32,i64}") introduced the generic hswap_i32(). Use it instead of open-coding it as gen_swaph(). Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson --- target/microblaze/translate.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/target/microblaze/translate.c b/target/microblaze/translate.c index 7e7f837c63..83fd1161f0 100644 --- a/target/microblaze/translate.c +++ b/target/microblaze/translate.c @@ -608,13 +608,8 @@ DO_TYPEA0(sra, false, gen_sra) DO_TYPEA0(src, false, gen_src) DO_TYPEA0(srl, false, gen_srl) -static void gen_swaph(TCGv_i32 out, TCGv_i32 ina) -{ - tcg_gen_rotri_i32(out, ina, 16); -} - DO_TYPEA0(swapb, false, tcg_gen_bswap32_i32) -DO_TYPEA0(swaph, false, gen_swaph) +DO_TYPEA0(swaph, false, tcg_gen_hswap_i32) static bool trans_wdic(DisasContext *dc, arg_wdic *a) {