From patchwork Fri May 5 08:39:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Lyon X-Patchwork-Id: 90347 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp243318vqo; Fri, 5 May 2023 01:41:48 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4reNd9ZmfdSGo4uluAsWoZbJ7sMgfbSMdQU8X6QGZsd4iFnlR9cHhmlE7od6tZPfkFqpat X-Received: by 2002:a17:907:6da9:b0:94f:6c6c:e14c with SMTP id sb41-20020a1709076da900b0094f6c6ce14cmr555302ejc.57.1683276108095; Fri, 05 May 2023 01:41:48 -0700 (PDT) Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id vw7-20020a170907058700b00965d4a0053dsi825623ejb.480.2023.05.05.01.41.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 May 2023 01:41:48 -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=pass header.i=@gcc.gnu.org header.s=default header.b=FtrScJ3d; arc=fail (signature failed); 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"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id ECAD73855591 for ; Fri, 5 May 2023 08:40:56 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org ECAD73855591 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1683276057; bh=mNjRKfmqLguQvN1c95c00zYxcC8YKlI4JP/HHJKSMvY=; h=To:CC:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=FtrScJ3d3sHuq20js2w1zK2d+1vhYaOEtEceI9P7QDc6pKrc2O4TFgOpl0Wks3mi/ wS6I4Sf4v2OMpxmRUUMm6ZaAHn5ogHIMjrMBr4wRFiK5Evv4YPRuEHMNtQU0vFZlF9 ohPq6H5XjwalU8F6qO6wXNGxm0fEi1T2QDysD4NM= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on2073.outbound.protection.outlook.com [40.107.15.73]) by sourceware.org (Postfix) with ESMTPS id E5D3A3858D33 for ; Fri, 5 May 2023 08:40:01 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org E5D3A3858D33 Received: from AS8P251CA0024.EURP251.PROD.OUTLOOK.COM (2603:10a6:20b:2f2::27) by DB8PR08MB5530.eurprd08.prod.outlook.com (2603:10a6:10:11f::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6340.23; Fri, 5 May 2023 08:39:58 +0000 Received: from AM7EUR03FT047.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:2f2:cafe::d3) by AS8P251CA0024.outlook.office365.com (2603:10a6:20b:2f2::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.27 via Frontend Transport; Fri, 5 May 2023 08:39:58 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; pr=C Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM7EUR03FT047.mail.protection.outlook.com (100.127.140.69) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6387.12 via Frontend Transport; Fri, 5 May 2023 08:39:58 +0000 Received: ("Tessian outbound 3a01b65b5aad:v136"); Fri, 05 May 2023 08:39:58 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 3186f785b8d3f41c X-CR-MTA-TID: 64aa7808 Received: from 96ed2a98a151.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id F0D5F536-9F36-469C-8D65-6462F773DA2C.1; Fri, 05 May 2023 08:39:51 +0000 Received: from EUR05-DB8-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 96ed2a98a151.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 05 May 2023 08:39:51 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oeKmjsJ8lbJxbotwAcN7S6PTgSV24QM0CEEWpCBLuvd34bRmenHq11ptabjdkkdADCGsBkkofGQjfJ4VSt+uKq8a+/S48xCCVw0GQv6g1kLFHWFEskASLjgLAHhbdnyjSlNpdIuGBG117byGVYxiguUsjqwROql1QM77YCplKeT1OUmEC8z+u/XotNVBSG07TwZXZIjLOKH9eFVh5e+OlCkyTmFyziKYt5G4o0MLjWMhsA6oWY9OZ5SsEwBP78m3DCADD6ob075qWbLZo8v3KkGqHR4mvaj713hlRFDe7POA3QAUflhKJTQqrz3TlGt4GuUqsWfdGcsxeK+BT434Mw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=mNjRKfmqLguQvN1c95c00zYxcC8YKlI4JP/HHJKSMvY=; b=QJccpqCUFg7vqp+rq6VhXofMeZhFL5XKW7wPOBoC/As3qoIZ+wRLq9IG3U0d2rUgP1qdhT8OOSTxipgLk8ONrs4SCaT0JM/apzmyaBMztXUsiLTrru3WxMMRl7q6orrppRqZcmZsbmoOIa4Dkn6Y958fARL7+KVd6Ts1H/ZKBZxNoelF+9qSvoHZNV7PcCZ09uE0J9etzpJEVbADZYMio7lH3qPsbmrxqsfeLvpCKSABkfwf6aJgMp+X8oQlZbgpyevscLTQxIZgRGsCsRSwRN2VEwok3Z0WSRLThI2WLbG2gI5QONkN4UBTWFaLO60wJkT58XDVyjQMCDSTZmYtKQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=gcc.gnu.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none Received: from DU2PR04CA0294.eurprd04.prod.outlook.com (2603:10a6:10:28c::29) by AS4PR08MB7831.eurprd08.prod.outlook.com (2603:10a6:20b:51b::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.26; Fri, 5 May 2023 08:39:49 +0000 Received: from DBAEUR03FT021.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:28c:cafe::36) by DU2PR04CA0294.outlook.office365.com (2603:10a6:10:28c::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6363.27 via Frontend Transport; Fri, 5 May 2023 08:39:49 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (40.67.248.234) by DBAEUR03FT021.mail.protection.outlook.com (100.127.142.184) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6363.20 via Frontend Transport; Fri, 5 May 2023 08:39:49 +0000 Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX04.Arm.com (10.251.24.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Fri, 5 May 2023 08:39:48 +0000 Received: from e129018.arm.com (10.57.22.112) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.23 via Frontend Transport; Fri, 5 May 2023 08:39:48 +0000 To: , , , CC: Christophe Lyon Subject: [PATCH 06/23] arm: [MVE intrinsics] factorize vabdq Date: Fri, 5 May 2023 10:39:13 +0200 Message-ID: <20230505083930.101210-6-christophe.lyon@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230505083930.101210-1-christophe.lyon@arm.com> References: <20230505083930.101210-1-christophe.lyon@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DBAEUR03FT021:EE_|AS4PR08MB7831:EE_|AM7EUR03FT047:EE_|DB8PR08MB5530:EE_ X-MS-Office365-Filtering-Correlation-Id: 4a7d63f8-4034-4f6f-3e27-08db4d444f6c x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: qEzZ+SpFVQqTflBWPMtaoSK+bupARGj66iJHkFhJmHk9ZArv48Op78NNp7gjsfU7j9jeG/jSeXN43zJxs96a1QSWlqJMVvmj2YqruZgEKU4wnb8dceUHQk6zqSL8MGPI1YLOvjCYGqLxGPAhelnsxK477n2V6cJJQbE1vu1o0odP25Sh8Qkaq4gYN/P1PUiNO54WuZxwq8gof/z3fCvLcXmgxGr5jlei5b4kQFRtnpFcMYqwzeD0eL3JDeJ2j/ejPnHeVc1phb079uIAqOEl3ouE+KdfJqxkS07RmzV1aC6+dgoGc7IIYx5fJfxVMwGuj+gjEhPP6Y8FiaTqo+gg038dqHGZwDR8TXJK3Y5WK7lLTVZrWr3vtyyeIQuwDSa3hNBalw1EcYngSO5+np9qM6WBEFBNXsN+dP2QCbB2Q5O1ks1BsSIh0IA7Uka1ck8zkHHMScrxbD2gEQ/wGizBo0Dt3ZektY1M1uznSH0nPpvDjOQKEA0uSULi+D8Y/d2mY+a474Cp5SR7hwYGW75uMEZqws+mUWJBEmabgfJdibav7EbE1b+rQOP5GboQzMLKhw3TeiCnlA5Cbt8s0qtJOMGt0XqZ2110sHkVG/G6Z+vXY7ZqeKtFGBgE/HqSH+9KuXkVCSS6Dr9fwA8Gh5ZCpscUcot+IP0qTEbgC3G0EQesvKZvZ7ILXNzUiKFvut0bVeCHgihGctETeC9ST3IVNjmMWvHTC3xqdQSq3ZglRFYB78X4yZJyR+cuzRge57h18kByNLU8J9PqF/Aips2ebA== X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(346002)(39860400002)(376002)(136003)(396003)(451199021)(36840700001)(40470700004)(46966006)(8676002)(8936002)(5660300002)(44832011)(47076005)(83380400001)(26005)(82310400005)(2616005)(1076003)(426003)(81166007)(86362001)(356005)(82740400003)(336012)(36860700001)(34020700004)(186003)(70586007)(316002)(6636002)(4326008)(36756003)(41300700001)(70206006)(40460700003)(6666004)(7696005)(40480700001)(110136005)(478600001)(2906002)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS4PR08MB7831 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM7EUR03FT047.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 9eafd751-5b34-4bfc-6f79-08db4d44498f X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ztH8MSS9nO2VazX9WQVCSCiHjh73AQuUkmWf7TFtZXJvoyOVnnySiLkScNcUb5mZmOZvy8Uw4CTOxaJFLIYJIzHbrou4dtYReFx1SeX3qzL3vP1AJdkELUTFSY9JzSf982MZS8A7zPmzaHYeMO80/O5B6BAYMK9sTO9e1j05n9NxyTJfgC/G7872PMWj4vmtPC4Z7c7tXuENfbMUdnEk1/5KAvn7G2xB8aQLr/y36sNAZWdLpM2Sr1OE5XM2VsjIll+P+yE6PU+kkRsbQv0A8RwsVJzqf4AqG2o7MCrb4iSZoDej3/Xb4fMUxFnJvcC9FpUM4YsNva14aGE1knqTj03y/HaSmoRdkXaAsNiPXpOPX2TVXtEc4cmQ1A5T0UNXIa0ry8evcg4l+rJFrbBLV6xuGbecM2McRBI/9fimTmZNsS15y9hEfCMYyOHuFloKf1Cq9ggg5rWV9E8ScHJOlYKyE2A2aII3A3aY7Anom8PDxiXl2SIuE3vQXn/K3JYYpK3ozl30Zj6lLWonwBxC+IFruVD764erMhI4lwpxM30pvVoA0Yvf8/dA0ucm+I2pl+hhXieTwDzz21BBt6gLgTe48GdrulLqb8TqEfDraM4Ogwl0ehYPgnu7rwJKsN5LIN+Z2MQ9W7GBc60miUbfsSMgCezXmq6rLyPsMXLBvfcbYWf9z/UA5NG9AVLhkw4vCoLa8V4pLdD0qler0C8FKhVRD0U9Mf+YyUP3T1UwIWs= X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(13230028)(4636009)(376002)(346002)(136003)(39860400002)(396003)(451199021)(46966006)(40470700004)(36840700001)(336012)(8936002)(426003)(8676002)(44832011)(82740400003)(110136005)(4326008)(5660300002)(47076005)(70586007)(70206006)(6636002)(86362001)(478600001)(316002)(34020700004)(2616005)(36860700001)(2906002)(82310400005)(81166007)(7696005)(41300700001)(83380400001)(6666004)(36756003)(40460700003)(186003)(26005)(1076003)(40480700001); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 May 2023 08:39:58.5697 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 4a7d63f8-4034-4f6f-3e27-08db4d444f6c X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM7EUR03FT047.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR08MB5530 X-Spam-Status: No, score=-12.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FORGED_SPF_HELO, GIT_PATCH_0, KAM_DMARC_NONE, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE, UNPARSEABLE_RELAY 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.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Christophe Lyon via Gcc-patches From: Christophe Lyon Reply-To: Christophe Lyon Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765042928099646884?= X-GMAIL-MSGID: =?utf-8?q?1765042928099646884?= 2022-09-08 Christophe Lyon gcc/ * config/arm/iterators.md (MVE_FP_M_BINARY): Add vabdq. (MVE_FP_VABDQ_ONLY): New. (mve_insn): Add vabd. * config/arm/mve.md (mve_vabdq_f): Move into ... (@mve_q_f): ... this. (mve_vabdq_m_f): Remove. --- gcc/config/arm/iterators.md | 9 +++++++-- gcc/config/arm/mve.md | 25 +++++-------------------- 2 files changed, 12 insertions(+), 22 deletions(-) diff --git a/gcc/config/arm/iterators.md b/gcc/config/arm/iterators.md index c53b42a86e9..3133642ea82 100644 --- a/gcc/config/arm/iterators.md +++ b/gcc/config/arm/iterators.md @@ -466,6 +466,7 @@ (define_int_iterator MVE_RSHIFT_N [ ]) (define_int_iterator MVE_FP_M_BINARY [ + VABDQ_M_F VADDQ_M_F VMULQ_M_F VSUBQ_M_F @@ -490,6 +491,10 @@ (define_int_iterator MVE_FP_N_BINARY [ VSUBQ_N_F ]) +(define_int_iterator MVE_FP_VABDQ_ONLY [ + VABDQ_F + ]) + (define_int_iterator MVE_FP_CREATE_ONLY [ VCREATEQ_F ]) @@ -501,8 +506,8 @@ (define_code_attr mve_addsubmul [ ]) (define_int_attr mve_insn [ - (VABDQ_M_S "vabd") (VABDQ_M_U "vabd") - (VABDQ_S "vabd") (VABDQ_U "vabd") + (VABDQ_M_S "vabd") (VABDQ_M_U "vabd") (VABDQ_M_F "vabd") + (VABDQ_S "vabd") (VABDQ_U "vabd") (VABDQ_F "vabd") (VADDQ_M_N_S "vadd") (VADDQ_M_N_U "vadd") (VADDQ_M_N_F "vadd") (VADDQ_M_S "vadd") (VADDQ_M_U "vadd") (VADDQ_M_F "vadd") (VADDQ_N_S "vadd") (VADDQ_N_U "vadd") (VADDQ_N_F "vadd") diff --git a/gcc/config/arm/mve.md b/gcc/config/arm/mve.md index fb1076aef73..c8cb4e430ac 100644 --- a/gcc/config/arm/mve.md +++ b/gcc/config/arm/mve.md @@ -1451,17 +1451,17 @@ (define_insn "mve_vrshrq_n_" ]) ;; -;; [vabdq_f]) +;; [vabdq_f] ;; -(define_insn "mve_vabdq_f" +(define_insn "@mve_q_f" [ (set (match_operand:MVE_0 0 "s_register_operand" "=w") (unspec:MVE_0 [(match_operand:MVE_0 1 "s_register_operand" "w") (match_operand:MVE_0 2 "s_register_operand" "w")] - VABDQ_F)) + MVE_FP_VABDQ_ONLY)) ] "TARGET_HAVE_MVE && TARGET_HAVE_MVE_FLOAT" - "vabd.f%# %q0, %q1, %q2" + ".f%#\t%q0, %q1, %q2" [(set_attr "type" "mve_move") ]) @@ -5483,24 +5483,9 @@ (define_insn "mve_vrmlsldavhaxq_p_sv4si" "vpst\;vrmlsldavhaxt.s32\t%Q0, %R0, %q2, %q3" [(set_attr "type" "mve_move") (set_attr "length""8")]) -;; -;; [vabdq_m_f]) -;; -(define_insn "mve_vabdq_m_f" - [ - (set (match_operand:MVE_0 0 "s_register_operand" "=w") - (unspec:MVE_0 [(match_operand:MVE_0 1 "s_register_operand" "0") - (match_operand:MVE_0 2 "s_register_operand" "w") - (match_operand:MVE_0 3 "s_register_operand" "w") - (match_operand: 4 "vpr_register_operand" "Up")] - VABDQ_M_F)) - ] - "TARGET_HAVE_MVE && TARGET_HAVE_MVE_FLOAT" - "vpst\;vabdt.f%# %q0, %q2, %q3" - [(set_attr "type" "mve_move") - (set_attr "length""8")]) ;; +;; [vabdq_m_f] ;; [vaddq_m_f] ;; [vsubq_m_f] ;; [vmulq_m_f]