From patchwork Fri Jan 13 15:40:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Srinath Parvathaneni X-Patchwork-Id: 43387 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4e01:0:0:0:0:0 with SMTP id p1csp337794wrt; Fri, 13 Jan 2023 07:41:33 -0800 (PST) X-Google-Smtp-Source: AMrXdXu6NzHHoDwhlXSYP4PyIAKSJzjDrp+NdcyGQ5b7VvFNcUA62XWhSZ9T7L8vESN93fFYOYgp X-Received: by 2002:a17:907:8b90:b0:84d:207d:c00c with SMTP id tb16-20020a1709078b9000b0084d207dc00cmr26937774ejc.25.1673624493656; Fri, 13 Jan 2023 07:41:33 -0800 (PST) Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id sd4-20020a1709076e0400b007c0c2ec3683si21673793ejc.106.2023.01.13.07.41.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Jan 2023 07:41:33 -0800 (PST) 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=nqGIMRam; 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 4262338493C9 for ; Fri, 13 Jan 2023 15:41:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4262338493C9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1673624490; bh=HhAbGafpVLZ6BTKNKEPJ/2EjstpwDFEGkTh1pQSqC0c=; h=To:CC:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=nqGIMRamo894jBs2t/cGo0s8ugavhpvxmcV1SbTv2TBdWdceQXXSkFpvbQZntGCGJ H4T7qpD6xZ6CCsrcbFYkflAFv9TBnX+s1B+podeU1yfuRAtStN7++TOXgMh+I92fGv FdvQZ2u8e/uVFpUnPapKmCdNMf4UKtdroWUPbrLs= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2059.outbound.protection.outlook.com [40.107.21.59]) by sourceware.org (Postfix) with ESMTPS id 975953858D37 for ; Fri, 13 Jan 2023 15:40:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 975953858D37 Received: from AS9PR04CA0180.eurprd04.prod.outlook.com (2603:10a6:20b:530::12) by AS8PR08MB5912.eurprd08.prod.outlook.com (2603:10a6:20b:29f::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5986.18; Fri, 13 Jan 2023 15:40:32 +0000 Received: from AM7EUR03FT035.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:530:cafe::29) by AS9PR04CA0180.outlook.office365.com (2603:10a6:20b:530::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6002.14 via Frontend Transport; Fri, 13 Jan 2023 15:40:32 +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 AM7EUR03FT035.mail.protection.outlook.com (100.127.141.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6002.13 via Frontend Transport; Fri, 13 Jan 2023 15:40:32 +0000 Received: ("Tessian outbound 333ca28169fa:v132"); Fri, 13 Jan 2023 15:40:32 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 63cd5755d8c074ea X-CR-MTA-TID: 64aa7808 Received: from c81b57c4d0f8.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id E3378A43-BFEF-4382-88DD-E77EB51861A2.1; Fri, 13 Jan 2023 15:40:25 +0000 Received: from EUR03-AM7-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id c81b57c4d0f8.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 13 Jan 2023 15:40:25 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZSm6zxHYuVr/vA0sKTT8A0jxC8oeLdysuKLJfoRXuTFFg+XYqQtkmgBPA0mWS9Y5pRtmZcJWeQC9jTBqFkyRQT8OHzAMckOY8efc3ZopUuepQHv4uCnCnTUh6SZ3av1cDHi0Lg3DeA28pO2tNtpk9LXScZNLu4p+V3fUZ9avrenkMz4GFOYk54YA6GmiblqqBp3Smlg0qRjfQ6XO2/pgP7VDU0l68MsAGUxrVc+rjaBf+ctrULGqqczQtQNaUHTbeqXXmVOcvSpyNBte6bR+ptyRKDeMx+qhcznGBJc845Ru4n67/OroXb6MWkCq9L4GyZQTuTVytDsy0j7DbSgylA== 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=HhAbGafpVLZ6BTKNKEPJ/2EjstpwDFEGkTh1pQSqC0c=; b=Ug2Pe9YLAnKWkuftRNJq4Kk9vLpvybRhFcs2w/V8tMY1Fx0xD4j4B+E261vSt/2H9GZmEha4GnKFoukPMe6LeDVX/vXMq0SCIS+mEnlxOWY6+9LdHmJ1FIfnzxEhG0tZONFSdPpldzX00I6fg6ec6k8O4EJFnPHi0TOjH1huQhZH3HN2NU5EtkVMseM2/QJVI6wlhvoWi3Rr4t8j/YaFvtTEyvzK/Gaic/EbM2UYFO4kPCmmJZxnDrhzbLTDmIi1+TMlsStQGIriHEFwmpX/2kKo6HQhYOUMyvm8vuCKdgivYk3uYACo53yeY6l10e5eCnEMG+x+reQfFXfrnRzD5w== 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 DB6PR07CA0067.eurprd07.prod.outlook.com (2603:10a6:6:2a::29) by DU0PR08MB8883.eurprd08.prod.outlook.com (2603:10a6:10:47e::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5986.19; Fri, 13 Jan 2023 15:40:16 +0000 Received: from DBAEUR03FT027.eop-EUR03.prod.protection.outlook.com (2603:10a6:6:2a:cafe::cc) by DB6PR07CA0067.outlook.office365.com (2603:10a6:6:2a::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6023.6 via Frontend Transport; Fri, 13 Jan 2023 15:40:16 +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 DBAEUR03FT027.mail.protection.outlook.com (100.127.142.237) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6002.13 via Frontend Transport; Fri, 13 Jan 2023 15:40:16 +0000 Received: from AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Fri, 13 Jan 2023 15:40:16 +0000 Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Fri, 13 Jan 2023 15:40:15 +0000 Received: from e120703.arm.com (10.2.81.20) by mail.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.16 via Frontend Transport; Fri, 13 Jan 2023 15:40:15 +0000 MIME-Version: 1.0 To: CC: Subject: [Committed] arm: Add cde feature support for Cortex-M55 CPU. Date: Fri, 13 Jan 2023 15:40:15 +0000 Message-ID: <5c3123b6-11d4-4c9b-90ed-20ca1b81d96a@AZ-NEU-EX04.Arm.com> X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DBAEUR03FT027:EE_|DU0PR08MB8883:EE_|AM7EUR03FT035:EE_|AS8PR08MB5912:EE_ X-MS-Office365-Filtering-Correlation-Id: cbd4f524-e3e7-4957-072d-08daf57c81c0 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: oUbyD8SnPi326w9wO+LOduU1R67khBB7ZhqxsJHDaDXkISQhbHJ0clt9W8jXa1HrVko1g+zyrlM0XR0o7/ryqbsD8j+0IdxRBvvY/WAcF5auasHENI7nm3vTJI9HYNQ9K8E8o30cG7Gs/m/XRkEw7OH0S1dnWH3ab4Y0WMpZXq8rtmrDtiDdQ0ZROlevD9OtCRmmsKInB981lOj7PEdOMUikzA/004GajaxbjTgldihek+gPGfuKlrVqjw+M5XaJIFt+7M5/pUDT4DiKsWmOZyjFjufHA3iLsKkfaUyRvDs7hxTv7y0st76w9U2OUZTfCEbuH0Q4hlkjdf1WQ/vUb4rFOIvb/pY/9lrCKScq0xutfQirj03qXa5LK9NEqwgMHd2GWvrT837ASw2aYVgpSk109XK0sn5W051YGIMIvcqxPP6Dk4Pr+qjpLCH5wJwTTTk8yzIr/wroii6JjD0HTEj+fp4H/lH60LB9eGW/exi1riErEu96JMefv8EZSOUGops3FyHljfj8X/1kHPpABDokylJDFpFdb1v2MfiQAO2t5ZV9hOLGiU1x8q2VebqX+MwdgYoaKmX3qHI1J9mbpM15WZWqV1cBfDXlmdgblHtV4WcSDlrs/VrPX0PyVMUvKVTEQq4vtVKIXS5mzq/KiiT90HzCeZ6QXpnvM66TwSF+rB4hsQUhyEFfj4bfl8jt8hTN67N+zwROGNvuZ1qWD4FQFaOcWtWgZwppY1Dm/vMxO2owbZUk21iAoVkUJ2Pnnfhe1IErYB43HoUe9lm8bQ== 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:(13230022)(4636009)(346002)(39860400002)(376002)(396003)(136003)(451199015)(46966006)(36840700001)(31696002)(86362001)(82310400005)(4326008)(186003)(8676002)(26005)(70206006)(70586007)(426003)(47076005)(41300700001)(40480700001)(316002)(966005)(6916009)(33964004)(478600001)(44832011)(81166007)(2906002)(356005)(82740400003)(5660300002)(36860700001)(235185007)(8936002)(336012)(31686004)(84970400001)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: DU0PR08MB8883 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM7EUR03FT035.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: f558a314-9482-414f-8c2e-08daf57c7809 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: S3s7uIAjd/JFKdrh+185C/RlD4lWEvwMF3cdppL3RFPmvNQHihsWUJ0EKV5Y4szftIs9CiAhWF0Azfu2Sd0AI75T88KMeQCI63/52D2YBTwSxUdz20QVGgLUb1BARFliJf8UcYIxjG8woW78CXGXckYMFiOIAI5GhCJTJS7SLDxNNN1p/Lpp0l1rkDc8dmT8ZKF+Ta00ntgjU9DKytu6Yy4piqqxrTgLGeo4lsuomWUjsdCTfsbQEGZb6PNKoaRbnCPyLJl1Soj/AKmCFxDc+IaZ2ZadFAKP7KcE+Rsbx+WvPiuC5Y/8BURPgwZFhK6rnGj/U9B8EivoDvFbMAMRHpmDcS6XUMhS/A8PaLF1mW42d5NJ2pLiS71D60O4gL+BKE22/COykqXr4wNm8Jcb3Um5k/Ws3EzyFAS/AvAqNY2gjvW5ICNPsq6aWeS42bLeD8+5PaSA7FPAAlvoLO1xsF0Kae9BkEXKixybIrnD5XGdcMagO6pfyEl9deYKy4abe9FwhNBulwWSOtwWrvSO89hJPindlhGUrMXmmZ7+bfKbFv2Ab4gDXAsYrk+tIsaiDsfXnYFiguGZFCnC92vrfoPv7AqAfdV/8hrIeLYsJWW3LkI3Yq1A+wLltCJqCKjp9yVM65hQcCluF++3+27pQUxm4T1bYrgUymKmmhTENV1arnABmzjbTWOC+/VMmGS/jaIMpF1HZe9iDUlHvvHobe9njcJW6bdCOkjMCAWyB5tn0CMsmcLRYtSMLVWHhugRjqyTv4VXeRIoc9zEvXVI7A== 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:(13230022)(4636009)(376002)(346002)(396003)(136003)(39860400002)(451199015)(40470700004)(46966006)(36840700001)(84970400001)(31686004)(44832011)(2906002)(41300700001)(36860700001)(5660300002)(235185007)(8936002)(70586007)(8676002)(70206006)(4326008)(31696002)(316002)(86362001)(40460700003)(82310400005)(336012)(426003)(47076005)(966005)(478600001)(81166007)(40480700001)(33964004)(186003)(26005)(6916009)(82740400003); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jan 2023 15:40:32.6692 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: cbd4f524-e3e7-4957-072d-08daf57c81c0 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: AM7EUR03FT035.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB5912 X-Spam-Status: No, score=-12.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, FORGED_SPF_HELO, GIT_PATCH_0, KAM_DMARC_NONE, KAM_LOTSOFHASH, KAM_SHORT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP, 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: Srinath Parvathaneni via Gcc-patches From: Srinath Parvathaneni Reply-To: Srinath Parvathaneni 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?1746288105983861166?= X-GMAIL-MSGID: =?utf-8?q?1754922477119146867?= Hi, This patch adds cde feature (optional) support for Cortex-M55 CPU, please refer [1] for more details. To use this feature we need to specify +cdecpN (e.g. -mcpu=cortex-m55+cdecp), where N is the coprocessor number 0 to 7. Bootstrapped for arm-none-linux-gnueabihf target, regression tested on arm-none-eabi target and found no regressions. [1] https://developer.arm.com/documentation/101051/0101/?lang=en (version: r1p1). Ok for master? Regards, Srinath. gcc/ChangeLog: 2023-01-13 Srinath Parvathaneni * common/config/arm/arm-common.cc (arm_canon_arch_option_1): Ignore cde options for -mlibarch. * config/arm/arm-cpus.in (begin cpu cortex-m55): Add cde options. * doc/invoke.texi (CDE): Document options for Cortex-M55 CPU. gcc/testsuite/ChangeLog: 2023-01-13 Srinath Parvathaneni * gcc.target/arm/multilib.exp: Add multilib tests for Cortex-M55 CPU. ############### Attachment also inlined for ease of reply ############### diff --git a/gcc/common/config/arm/arm-common.cc b/gcc/common/config/arm/arm-common.cc index c38812f1ea6a690cd19b0dc74d963c4f5ae155ca..9ed6830417bbcc984f67237fe30beb5ebec76c00 100644 --- a/gcc/common/config/arm/arm-common.cc +++ b/gcc/common/config/arm/arm-common.cc @@ -685,8 +685,10 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) auto_sbitmap target_isa (isa_num_bits); auto_sbitmap base_isa (isa_num_bits); auto_sbitmap fpu_isa (isa_num_bits); + auto_sbitmap ignore_multilib_isa (isa_num_bits); bitmap_clear (fpu_isa); + bitmap_clear (ignore_multilib_isa); const arch_option *selected_arch = NULL; @@ -719,15 +721,6 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) arm_initialize_isa (target_isa, selected_arch->common.isa_bits); arm_parse_option_features (target_isa, &selected_arch->common, strchr (arch, '+')); - if (arch_for_multilib) - { - const enum isa_feature removable_bits[] = {ISA_IGNORE_FOR_MULTILIB, - isa_nobit}; - sbitmap isa_bits = sbitmap_alloc (isa_num_bits); - arm_initialize_isa (isa_bits, removable_bits); - bitmap_and_compl (target_isa, target_isa, isa_bits); - } - if (fpu && strcmp (fpu, "auto") != 0) { /* We assume that architectures do not have any FPU bits @@ -806,6 +799,16 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) bitmap_clear_bit (target_isa, isa_bit_vfpv2); } + /* Here we remove feature isa bits from -mlibarch string which are not + necessary for multilib string comparsion. */ + if ((arch || cpu) && arch_for_multilib) + { + const enum isa_feature removable_bits[] = {ISA_IGNORE_FOR_MULTILIB, + isa_nobit}; + arm_initialize_isa (ignore_multilib_isa, removable_bits); + bitmap_and_compl (target_isa, target_isa, ignore_multilib_isa); + } + /* If we don't have a selected architecture by now, something's badly wrong. */ gcc_assert (selected_arch); diff --git a/gcc/config/arm/arm-cpus.in b/gcc/config/arm/arm-cpus.in index e89106c51b41d709b2159073da3273423af537f8..579cf35636632869947f37753bbf0ba79277808c 100644 --- a/gcc/config/arm/arm-cpus.in +++ b/gcc/config/arm/arm-cpus.in @@ -1644,6 +1644,14 @@ begin cpu cortex-m55 option nomve remove mve mve_float option nofp remove ALL_FP mve_float option nodsp remove MVE mve_float + option cdecp0 add cdecp0 + option cdecp1 add cdecp1 + option cdecp2 add cdecp2 + option cdecp3 add cdecp3 + option cdecp4 add cdecp4 + option cdecp5 add cdecp5 + option cdecp6 add cdecp6 + option cdecp7 add cdecp7 isa quirk_no_asmcpu quirk_vlldm costs v7m vendor 41 diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 701c228bd0a824dee52c7d4e23c9f687000cd3d6..0b0bdb63436e5a63b12a06c3c6cd5544cc54c808 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -22168,6 +22168,10 @@ floating-point instructions on @samp{cortex-m55}. Disable the M-Profile Vector Extension (MVE) single precision floating-point instructions on @samp{cortex-m55}. +@item +cdecp0, +cdecp1, ... , +cdecp7 +Enable the Custom Datapath Extension (CDE) on selected coprocessors according +to the numbers given in the options in the range 0 to 7 on @samp{cortex-m55}. + @item +nofp Disables the floating-point instructions on @samp{arm9e}, @samp{arm946e-s}, @samp{arm966e-s}, @samp{arm968e-s}, @samp{arm10e}, diff --git a/gcc/testsuite/gcc.target/arm/multilib.exp b/gcc/testsuite/gcc.target/arm/multilib.exp index f903f028a83f884bdc1521f810f7e70e4130a715..e9c9b9cf885155d9a7e4106161c570df1b57ffab 100644 --- a/gcc/testsuite/gcc.target/arm/multilib.exp +++ b/gcc/testsuite/gcc.target/arm/multilib.exp @@ -854,6 +854,18 @@ if {[multilib_config "rmprofile"] } { {-mcpu=cortex-m55+nomve+nofp -mfpu=auto -mfloat-abi=softfp} "thumb/v8-m.main/nofp" {-mcpu=cortex-m55+nodsp+nofp -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-mcpu=cortex-m55+nodsp+nofp -mfpu=auto -mfloat-abi=softfp} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" {-march=armv8-m.main+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-march=armv8-m.main+fp+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-march=armv8-m.main+fp.dp+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" diff --git a/gcc/common/config/arm/arm-common.cc b/gcc/common/config/arm/arm-common.cc index c38812f1ea6a690cd19b0dc74d963c4f5ae155ca..9ed6830417bbcc984f67237fe30beb5ebec76c00 100644 --- a/gcc/common/config/arm/arm-common.cc +++ b/gcc/common/config/arm/arm-common.cc @@ -685,8 +685,10 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) auto_sbitmap target_isa (isa_num_bits); auto_sbitmap base_isa (isa_num_bits); auto_sbitmap fpu_isa (isa_num_bits); + auto_sbitmap ignore_multilib_isa (isa_num_bits); bitmap_clear (fpu_isa); + bitmap_clear (ignore_multilib_isa); const arch_option *selected_arch = NULL; @@ -719,15 +721,6 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) arm_initialize_isa (target_isa, selected_arch->common.isa_bits); arm_parse_option_features (target_isa, &selected_arch->common, strchr (arch, '+')); - if (arch_for_multilib) - { - const enum isa_feature removable_bits[] = {ISA_IGNORE_FOR_MULTILIB, - isa_nobit}; - sbitmap isa_bits = sbitmap_alloc (isa_num_bits); - arm_initialize_isa (isa_bits, removable_bits); - bitmap_and_compl (target_isa, target_isa, isa_bits); - } - if (fpu && strcmp (fpu, "auto") != 0) { /* We assume that architectures do not have any FPU bits @@ -806,6 +799,16 @@ arm_canon_arch_option_1 (int argc, const char **argv, bool arch_for_multilib) bitmap_clear_bit (target_isa, isa_bit_vfpv2); } + /* Here we remove feature isa bits from -mlibarch string which are not + necessary for multilib string comparsion. */ + if ((arch || cpu) && arch_for_multilib) + { + const enum isa_feature removable_bits[] = {ISA_IGNORE_FOR_MULTILIB, + isa_nobit}; + arm_initialize_isa (ignore_multilib_isa, removable_bits); + bitmap_and_compl (target_isa, target_isa, ignore_multilib_isa); + } + /* If we don't have a selected architecture by now, something's badly wrong. */ gcc_assert (selected_arch); diff --git a/gcc/config/arm/arm-cpus.in b/gcc/config/arm/arm-cpus.in index e89106c51b41d709b2159073da3273423af537f8..579cf35636632869947f37753bbf0ba79277808c 100644 --- a/gcc/config/arm/arm-cpus.in +++ b/gcc/config/arm/arm-cpus.in @@ -1644,6 +1644,14 @@ begin cpu cortex-m55 option nomve remove mve mve_float option nofp remove ALL_FP mve_float option nodsp remove MVE mve_float + option cdecp0 add cdecp0 + option cdecp1 add cdecp1 + option cdecp2 add cdecp2 + option cdecp3 add cdecp3 + option cdecp4 add cdecp4 + option cdecp5 add cdecp5 + option cdecp6 add cdecp6 + option cdecp7 add cdecp7 isa quirk_no_asmcpu quirk_vlldm costs v7m vendor 41 diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 701c228bd0a824dee52c7d4e23c9f687000cd3d6..0b0bdb63436e5a63b12a06c3c6cd5544cc54c808 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -22168,6 +22168,10 @@ floating-point instructions on @samp{cortex-m55}. Disable the M-Profile Vector Extension (MVE) single precision floating-point instructions on @samp{cortex-m55}. +@item +cdecp0, +cdecp1, ... , +cdecp7 +Enable the Custom Datapath Extension (CDE) on selected coprocessors according +to the numbers given in the options in the range 0 to 7 on @samp{cortex-m55}. + @item +nofp Disables the floating-point instructions on @samp{arm9e}, @samp{arm946e-s}, @samp{arm966e-s}, @samp{arm968e-s}, @samp{arm10e}, diff --git a/gcc/testsuite/gcc.target/arm/multilib.exp b/gcc/testsuite/gcc.target/arm/multilib.exp index f903f028a83f884bdc1521f810f7e70e4130a715..e9c9b9cf885155d9a7e4106161c570df1b57ffab 100644 --- a/gcc/testsuite/gcc.target/arm/multilib.exp +++ b/gcc/testsuite/gcc.target/arm/multilib.exp @@ -854,6 +854,18 @@ if {[multilib_config "rmprofile"] } { {-mcpu=cortex-m55+nomve+nofp -mfpu=auto -mfloat-abi=softfp} "thumb/v8-m.main/nofp" {-mcpu=cortex-m55+nodsp+nofp -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-mcpu=cortex-m55+nodsp+nofp -mfpu=auto -mfloat-abi=softfp} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=hard -mfpu=auto} "thumb/v8-m.main+dp/hard" + {-mcpu=cortex-m55 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=softfp -mfpu=auto} "thumb/v8-m.main+dp/softfp" + {-mcpu=cortex-m55 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+cdecp0 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+nomve+cdecp0 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" + {-mcpu=cortex-m55+cdecp0+cdecp1+cdecp2+cdecp3+cdecp4+cdecp5+cdecp6+cdecp7 -mfloat-abi=soft -mfpu=auto} "thumb/v8-m.main/nofp" {-march=armv8-m.main+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-march=armv8-m.main+fp+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp" {-march=armv8-m.main+fp.dp+cdecp0 -mfpu=auto -mfloat-abi=soft} "thumb/v8-m.main/nofp"