From patchwork Fri Sep 8 06:16:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Christoph_M=C3=BCllner?= X-Patchwork-Id: 137698 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ab0a:0:b0:3f2:4152:657d with SMTP id m10csp348939vqo; Thu, 7 Sep 2023 23:16:37 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFNta2J7pE2a2AOTtXDexlG76lDnz3IhmD120/Lu9yk7S5oP+VyoxIaEyXCShwn381msTOx X-Received: by 2002:a17:907:78d5:b0:9a1:b85d:c952 with SMTP id kv21-20020a17090778d500b009a1b85dc952mr1761139ejc.12.1694153797191; Thu, 07 Sep 2023 23:16:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694153797; cv=none; d=google.com; s=arc-20160816; b=qMe6z864OMU/R0oLhOXQhWRnDqQW3WmPr7VX1FBh0zM9joBVRuwF80C0ofPjjf9Bm3 brlp9GnQjXCAgY0x/cp7LD1hOswJwydGbbnjli/LzQqskRudux6Jev1g2yN5m5Z7K1D+ yYVMX9m4QhoV39I29uIowCciRihNV8buWbJSF3BOfhHB92P0mCq7h0B1pKBsHJ7vRGQg VLoPYDlzFOAVA94807tMCSNHj+lIwhJYUpHaHyxzI7MF9gMoOYy1irXPbs4vYNVhHjo7 toLkeNlzGOBsHsPi8Cp5isNUtg0Nx0GrFVgJojBUdRszkj8jd9WCFMG/qpBbaC0m1vu4 KDqQ== 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:message-id:date:subject:to:from:dkim-signature :dmarc-filter:delivered-to; bh=V0ofHw5mUFToNyNaQGg23u7ub5ZOtFmAxpqprG6X4lo=; fh=rhzHQJhq9WV4qpo88d7UFjCUBpstN9AhlgFhCyDisF8=; b=eQm716C+SBEbNxd5YOvF6YGQZWaZWwy15biJy3hpe1ARmnsk4M/YukD4KFmk/VoN6R mzgfKPGQD3SZ0puEfKD2o0Une1RpTqNNqdX+cgaQNRN1tQH9/srwsiVC8XjAcIyxrtro EYafAqiyDJRwVePB/eSEXWq3EGo0FCatSR0AqScQbjC6l6TThLkaI8pIEcSii8lDSZPo sXVYCZFWHtqk+O+dE+3L9pDPJXlt+cF1uUQydePXmq27lMEkdp9Lglxa1sraDPQI0dtS rVExLny3ffpgK7E0CuO8AhLjaA++n/OAD+jja9oDdypY8a7qVhAFKC5NGt/Z031es9Dp ao9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@vrull.eu header.s=google header.b=aTFbYqlk; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id qn6-20020a170907210600b0099d9dd717d2si733213ejb.655.2023.09.07.23.16.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Sep 2023 23:16:37 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=fail header.i=@vrull.eu header.s=google header.b=aTFbYqlk; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 4CF223857C43 for ; Fri, 8 Sep 2023 06:16:33 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-ed1-x52a.google.com (mail-ed1-x52a.google.com [IPv6:2a00:1450:4864:20::52a]) by sourceware.org (Postfix) with ESMTPS id 5AB143858D1E for ; Fri, 8 Sep 2023 06:16:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 5AB143858D1E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=vrull.eu Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=vrull.eu Received: by mail-ed1-x52a.google.com with SMTP id 4fb4d7f45d1cf-5298e43bb67so3555141a12.1 for ; Thu, 07 Sep 2023 23:16:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vrull.eu; s=google; t=1694153764; x=1694758564; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=V0ofHw5mUFToNyNaQGg23u7ub5ZOtFmAxpqprG6X4lo=; b=aTFbYqlkWupompl8safLT9uT4oDpb4Htaw55j9T7WQYsD9YZztDn9upQNSISe95NHk z5XyMRDLxgjZ7M6AzQuV66wRD5OwujJ32v9OXtiHO3weOTSGrKeoEOhEOdOGe28p9vSc 9fu0ziFFK806Xs7A12rXq+Uy7dLdoFYMkQgJlJPyt7niW86qgiWfGTU2e4eFyAFBfgI4 oMFvBUanWVjjCDQcaRyS0OlB7viHRnhcMblMgU24O7oCc9x6kHtOxwE2bKkGDtjIq1wD tSeEgrXWGvW7y3XoPyBPa5mi8IxFR4G48UMsuPAHQrbb9AWFL3sdBZmlJ5oR+EtmXDix jzDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694153764; x=1694758564; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=V0ofHw5mUFToNyNaQGg23u7ub5ZOtFmAxpqprG6X4lo=; b=mb6kn3WYfyl2/JfgQE1XSZKXGm2r0LfN0BuTMdYjVFHdXpnZpdfuSUu8pXPjoaFlZJ KsiJe4ba3/Zubb7qXY3lTnrnuruHoCzJjTarqloOkd962O2mFKtIWS4C0s8psYe9+bWX EZ07uG6a3mwenXHnwDXzG9XhFWqy19jvOf3ZXMqYsp3TquOC96bakXXBEYnYhJFE8clM gcpTU4EhidvyxmwXrJG8ejpPpJkCoCXqrIz247MRR9bdVpVsGVJ/AohvpLBQLRcaKDmG wQeA7URA10nF/uxpBD6VuAW6auTI4bgPaKQUFrqWU6i/60FKipWWCfwywG78mLrwHiJu 9DjA== X-Gm-Message-State: AOJu0YxFilbPyaMqb3RyQCI6P8zh/w2iYcZGyX7Z/6tD3u/E6Dj6JOyH V9a4IkVFscbtKQWrHaYbUrClwppYMHr2UZ1uX/Y= X-Received: by 2002:aa7:c90c:0:b0:52a:38c3:1b4b with SMTP id b12-20020aa7c90c000000b0052a38c31b4bmr1743816edt.15.1694153764558; Thu, 07 Sep 2023 23:16:04 -0700 (PDT) Received: from beast.fritz.box (62-178-148-172.cable.dynamic.surfer.at. [62.178.148.172]) by smtp.gmail.com with ESMTPSA id n28-20020a056402515c00b0052a198d8a4dsm586765edd.52.2023.09.07.23.16.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Sep 2023 23:16:04 -0700 (PDT) From: Christoph Muellner To: gcc-patches@gcc.gnu.org, Kito Cheng , Jim Wilson , Palmer Dabbelt , Andrew Waterman , Philipp Tomsich , Jeff Law Subject: [PATCH] riscv: thead: Fix mode attribute for extension patterns Date: Fri, 8 Sep 2023 08:16:00 +0200 Message-ID: <20230908061600.1922301-1-christoph.muellner@vrull.eu> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-Spam-Status: No, score=-12.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, JMQ_SPF_NEUTRAL, KAM_MANYTO, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1776449012017572762 X-GMAIL-MSGID: 1776449012017572762 From: Christoph Müllner The mode attribute of an extension pattern is usually set to the target type. Let's follow this convention consistently for xtheadbb. Signed-off-by: Christoph Müllner gcc/ChangeLog: * config/riscv/thead.md: Use more appropriate mode attributes for extensions. --- gcc/config/riscv/thead.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/config/riscv/thead.md b/gcc/config/riscv/thead.md index 05d1b32bd94..2287b752ea1 100644 --- a/gcc/config/riscv/thead.md +++ b/gcc/config/riscv/thead.md @@ -101,7 +101,7 @@ (define_insn "*zero_extendsidi2_th_extu" th.extu\t%0,%1,31,0 lwu\t%0,%1" [(set_attr "type" "bitmanip,load") - (set_attr "mode" "SI")]) + (set_attr "mode" "DI")]) (define_insn "*zero_extendhi2_th_extu" [(set (match_operand:GPR 0 "register_operand" "=r,r") @@ -111,7 +111,7 @@ (define_insn "*zero_extendhi2_th_extu" th.extu\t%0,%1,15,0 lhu\t%0,%1" [(set_attr "type" "bitmanip,load") - (set_attr "mode" "HI")]) + (set_attr "mode" "")]) (define_insn "*th_clz2" [(set (match_operand:X 0 "register_operand" "=r")