From patchwork Wed Dec 6 12:45:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Carlotti X-Patchwork-Id: 174564 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp4077903vqy; Wed, 6 Dec 2023 04:46:38 -0800 (PST) X-Google-Smtp-Source: AGHT+IED9lZyduLb/aMSb6tOFB+dUY+0V1Ednso2y7vUIyfhI79XZjQQ8I3LJzrkIk4d09mTwghb X-Received: by 2002:a05:622a:1909:b0:421:c349:73f6 with SMTP id w9-20020a05622a190900b00421c34973f6mr1240923qtc.22.1701866798707; Wed, 06 Dec 2023 04:46:38 -0800 (PST) ARC-Seal: i=4; a=rsa-sha256; t=1701866798; cv=pass; d=google.com; s=arc-20160816; b=Nnk+MgttfQ94Hdfe1aDdFs7/wAqY12jJpfNxOpm8nC7T/KPeqyuiJJfSttgQ11nGUl e2er4Y5/V7N7iUg7lqBE8f/bXXoh5r7e9IgK1oUbeWsimkbcaeODnQnMk8fCAnfLvoTX 4BBs0bRBtPX8Fo9umxXXwaq/rsmXYQGysXQ5AUsYGiZiLpZtp3xBftE+A/pSEuSwLWdw XdernqpHBc2poxRH3nZAyE1S246I3Ne7tZyVwCfHSzPIMDrWS4TAsmFwgPlsIc9Ak+1E 0oglSVh0dObK4oW+xpA5fJzc4swXczATGHleDqlf1yZUihrwyI7ISVIZtiPYpq7H0PB3 o87w== ARC-Message-Signature: i=4; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:original-authentication-results :nodisclaimer:mime-version:in-reply-to:content-disposition :references:message-id:subject:to:from:date :authentication-results-original:dkim-signature:dkim-signature :arc-filter:dmarc-filter:delivered-to; bh=ky5Mkguy4A915nrYUOq7d34wWWVu6F4poyK5/rq/7cU=; fh=hPrbWPhweUx4V0GV9uXJqbyAzg2ABmTz7kczrAQqMmM=; b=dTjkAC6Blk+qeS2ZYQB9WCPWxByGMBD/D1r2etYE9j31sNmgaUYPQr5c+2SXA65YKk Lh/WW2P8HdhKPF4F4ZREyDJPF/hnNQC0GZkwH3j+odsXq/1RBvV/5Xp0de69+lYA5D34 Gd04rA7wzd0PosB+vSIGV1U/zmeRvtBgbaBghBUTpkkdB8HaldqJfrG9pwKmOj/xSJNS UmlHvO8csIUAfDV5vzAZedRF/pDYSahXIS9OAdQw8uooOCxUSrmjP+ZbYaHxvgWpdyEV MNtkCiFSAkJMCHtrjVpfrtIShYZ7D1G8DHplz23ZI5Z/4dRjZQ+0jIVFv6hcV0viO48b LiKg== ARC-Authentication-Results: i=4; mx.google.com; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=7I1i4SlE; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=7I1i4SlE; arc=pass (i=3); 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=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id bc11-20020a05622a1ccb00b0042385a0d221si15009203qtb.203.2023.12.06.04.46.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Dec 2023 04:46:38 -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=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=7I1i4SlE; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=7I1i4SlE; arc=pass (i=3); 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=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id D15D2385842A for ; Wed, 6 Dec 2023 12:46:36 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on2048.outbound.protection.outlook.com [40.107.7.48]) by sourceware.org (Postfix) with ESMTPS id 1ABC03858C20 for ; Wed, 6 Dec 2023 12:46:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1ABC03858C20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 1ABC03858C20 Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=40.107.7.48 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1701866774; cv=pass; b=A9VTc1vu8EV2Prt397upRXcHx2U1fWvIzpyZZB4lj7dQKW0IE/Eq042Q/veFYD9+ViWbi5PH807tVJBxT5VVlwYYWiFcwrrqHXWVP4QLBQOfP6T7FYGYcRlF122Szvar2b+ZxOsbcJFl+uBp+GOlH7KA8UsvwgqxCBbeh6vl7Wk= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1701866774; c=relaxed/simple; bh=3UlA2bjaYHjKXry8I+A+D9yzkmELZToTil6WnaWX2E0=; h=DKIM-Signature:DKIM-Signature:Date:From:To:Subject:Message-ID: MIME-Version; b=pncEl4E4XNDDb9OFsOyE71AmEEx6RQY6wATZR48xy+HsjWIv+Sdkabuwqu56mHTJ0oXp4nkBQrOmS1/1SbfA5kf+f6DNFsGUaA51VIZZgquIzQAruSv7IW0c9aFchLRB/7lsuw835Yt4UNj0vYDHcv6lfABje2Lw3oqPwrHR4Yg= ARC-Authentication-Results: i=3; server2.sourceware.org ARC-Seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=UxoSwc52Z219k4AV6p60ZQNG9BW1TPoW52hu+E6zIMIUH9eaN4Vg1/Nb+VxXET/iUG9QHoYktm4bEddsjqUgUY7i1AcIYkDuxdEbppTwvegZe8zLTeQsPtpIgoBr+4R9+H5Nv8Mowoz/Qg7WbCcf2TrgxRFo/E5AF1534EHfqr3ZOxv89q03iyO01BVBvzzRdDRu48cXajhil+2MwwrixAGh7D7ZWKnJFHRamdwgThMpmsgiJy0KFA/Vg3aqlZE7Ph4MV0x9Le5c9bSOiikrxsqQdDe5m79RvC68cr3jgAVZnwpE4kP4ljMLmKtMW5Z06X8FM4EMZ7jNntzW/Z69Pw== ARC-Message-Signature: i=2; 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=ky5Mkguy4A915nrYUOq7d34wWWVu6F4poyK5/rq/7cU=; b=ANGNP0X30XhT8v6oAs3iBBq1bBiZrr4GLFh6AoIoN2KFYLxKuRXsbYA5gYuuEh3q/Co06KTRAbo7FYHJqi3bWfnS08GDPXtjBkLB1nwSOIGumbAqMb+EBfwephj8gA/+SHOHLodqAatOvDDacwLGzSOP5KThK60VZBYtB8PeQ4+PC79sVhSxfDKTQdHn4+fZYSIA60HjhhB0lqH2qD83gRAa1/6vf0q6JIsxZF2beRDhFMGP9n6NXn+5o0/jx6boQxjpXj+vOKhAxL/7LbYBDw2O/XCShWTfvxQ5WEAqJDCSaZTvHkWwPDAHBRFw2XC84gg3kGR81e50XnMVehxSog== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=gcc.gnu.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com]) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ky5Mkguy4A915nrYUOq7d34wWWVu6F4poyK5/rq/7cU=; b=7I1i4SlEiHk/NpxS4f+lLfqdD427XTsZUSiEbOAJmov6ArOqWVnt9CpRpbmDaq9OHAF4HJdy2TJKYa7709siYrnOYSxqmj5ydTz7+cgZ87RDMpFuxIf9b1v8z9OyDyK1mhGWjY2pcVb+UbG+Y1NLFMeAr7G+ESePI827qotfj4E= Received: from AS9PR05CA0286.eurprd05.prod.outlook.com (2603:10a6:20b:492::33) by PA4PR08MB6205.eurprd08.prod.outlook.com (2603:10a6:102:e6::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7046.34; Wed, 6 Dec 2023 12:46:05 +0000 Received: from AMS0EPF000001A0.eurprd05.prod.outlook.com (2603:10a6:20b:492:cafe::39) by AS9PR05CA0286.outlook.office365.com (2603:10a6:20b:492::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7046.34 via Frontend Transport; Wed, 6 Dec 2023 12:46:05 +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 AMS0EPF000001A0.mail.protection.outlook.com (10.167.16.230) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7068.20 via Frontend Transport; Wed, 6 Dec 2023 12:46:05 +0000 Received: ("Tessian outbound 20615a7e7970:v228"); Wed, 06 Dec 2023 12:46:05 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 62872b1306276c54 X-CR-MTA-TID: 64aa7808 Received: from c9aacbf40c1c.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 80DFA8EC-97D8-47E8-A6D1-F84085A1FBB7.1; Wed, 06 Dec 2023 12:45:59 +0000 Received: from EUR04-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id c9aacbf40c1c.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Wed, 06 Dec 2023 12:45:59 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Z73wsU7WGSyxJb4RsNTvUOCdAMnutks3DCtj1sqdbiF9b6J4KJzeQ+xnOMMBVSOF3HL6xdl9xZ/ltvhlGpJY9caViOhRMWKMP/gRr1i3k3o5ipKQjrMhNdKHlcfAwauhwNmLXwW72gy9GAocRBwv0mPN9Ql+c+4D8NLZPv+nIH9IXS+e8E9VkSxStD6s0q8WAtv9gcN6Gq3vkqwMTc3VVsbVkO6iUHOKM88gaIC+HHWzANvQNrNAhxBeRqFBpYApb5rgYKuKAXxCo8pGkegmyiqYXdXrmteHSEO+Z2e7H3nCXEGrZEjdNmkW+o961UF8SnuYPn8ib8krOfMyHum/Xw== 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=ky5Mkguy4A915nrYUOq7d34wWWVu6F4poyK5/rq/7cU=; b=DbjLz4A71YYkbTLmKTwiQE3Q7oRkOLTDvtG67SG1ugwcbK481R7Yr+/ZS1bbzKuHD5llBrv28LrfAmAtboJIt7MgRvghRlk3A821gYcGGRVI+MQlzaccD4Nxl5qC8Fwpr0j+dXsFJkhheJ0ZnFfaAqS+BLYQdNqHBXVw1UE2taAaxIfXL61jpQGzo8e48/S2Qk+rDAhBErF6+Uagd5BRgdfN+DeeUMwfryWBQPXKnD2rJdHXlGN4xHjXwpLE2im6i0P3bQ0i0akq3oVKeotr99OzoHxhBv/zLN9G/5UarLEuMxduLWF8ieGMyLvF0rzUfSYMK+y09cc1VgUB4R8vKw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ky5Mkguy4A915nrYUOq7d34wWWVu6F4poyK5/rq/7cU=; b=7I1i4SlEiHk/NpxS4f+lLfqdD427XTsZUSiEbOAJmov6ArOqWVnt9CpRpbmDaq9OHAF4HJdy2TJKYa7709siYrnOYSxqmj5ydTz7+cgZ87RDMpFuxIf9b1v8z9OyDyK1mhGWjY2pcVb+UbG+Y1NLFMeAr7G+ESePI827qotfj4E= Authentication-Results-Original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; Received: from AS8PR08MB6678.eurprd08.prod.outlook.com (2603:10a6:20b:398::8) by AS8PR08MB10171.eurprd08.prod.outlook.com (2603:10a6:20b:62a::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7046.34; Wed, 6 Dec 2023 12:45:56 +0000 Received: from AS8PR08MB6678.eurprd08.prod.outlook.com ([fe80::af15:c9d7:cd8c:6da2]) by AS8PR08MB6678.eurprd08.prod.outlook.com ([fe80::af15:c9d7:cd8c:6da2%7]) with mapi id 15.20.7068.025; Wed, 6 Dec 2023 12:45:56 +0000 Date: Wed, 6 Dec 2023 12:45:53 +0000 From: Andrew Carlotti To: gcc-patches@gcc.gnu.org Subject: [PATCH v3 3/5] ada: Improve attribute exclusion handling Message-ID: References: <4cdd7089-edd4-96b9-5c0e-120d5357f01b@e124511.cambridge.arm.com> Content-Disposition: inline In-Reply-To: <4cdd7089-edd4-96b9-5c0e-120d5357f01b@e124511.cambridge.arm.com> X-ClientProxiedBy: LO2P265CA0054.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:60::18) To AS8PR08MB6678.eurprd08.prod.outlook.com (2603:10a6:20b:398::8) MIME-Version: 1.0 X-MS-TrafficTypeDiagnostic: AS8PR08MB6678:EE_|AS8PR08MB10171:EE_|AMS0EPF000001A0:EE_|PA4PR08MB6205:EE_ X-MS-Office365-Filtering-Correlation-Id: 5a92db6c-0f88-4153-000f-08dbf6594ff6 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: USfJswLqMOJM4JBMiiwa/5SFMfh6ksnce6+n6ZJRFdxMrMkMC+RbmLbz35H2Eqheho6Njl97dqtIHwcEmR0/Vs+0z56D3fScBUhvRa8ACd0aWi3L648yla9p2XJjxyuSszt4fldtYVMwIAoM5+YuqH3KWVmLA+jT3FcJr9eB5OKIPvvDg5p/DfqUKwAWDDmz8cy3xGA85HgGVPgGLNdnmgnLi/KwIdvd/WrXDilXnyCnGB9zgZhOehOiofhcvdZr15Llb7PZT9uRP/KvWorA4YlPungTFGwSgRmNJMz5MP1haTb8k+qR8vdt15aP3NquZxr7RlS0cT+E6iQXbxHy1JOuEhp8xNhzm/ezpGCYq5hjNFZU+DdbpAMBOtDjMjQ5MoYDAUUTsTA92mpumS5q9RYSc3k7adCG1My5Ntwp9FMDDErqBDuVU83YzMTmwshhnhv82CdYhU9/EZtwvMTcENpmPRAVn1iZ81fvsuDCjeU2zvpMmasmSEqsCc4m6E0AcR2PsJoR4f4KgPWjc77dVV69aphZhg563gJkcwuteiexd9jJKbcolJT66FHVVohewwA8tA2iMhyQ3sKDzWrDJJrFELFvCKqt0XrGLepSEh96uMNGPzxDu7WGNFwxEae0 X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AS8PR08MB6678.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(366004)(396003)(376002)(346002)(136003)(39860400002)(230273577357003)(230173577357003)(230922051799003)(1800799012)(451199024)(64100799003)(186009)(6486002)(31696002)(86362001)(83380400001)(6916009)(316002)(6666004)(66476007)(66946007)(66556008)(44832011)(6506007)(8676002)(8936002)(31686004)(6512007)(478600001)(26005)(5660300002)(38100700002)(41300700001)(2906002); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB10171 Original-Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AMS0EPF000001A0.eurprd05.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: dccdfcfa-6227-420d-2c68-08dbf6594a95 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: pT6eJRy91dNSwZYevNBUtVH8727TRdmZJfw/iFdTD8tFut9q7gJPhzN1RZ9s9bfwc7VAe8dbbbVbTndSVrAhcJoyaMlyNCh9o3d+etvx9PIpCbPMTt3u4nfqBoWkI07xZeNZlNzP9pdCOwWfGh9caFYeqbecg8FDwstPfpOPYjp9W8ftORTfzv/MVogPOIsWfx+VHT+Dae8KDiWidx9xpj4JmEH3o4D/F0T5ePd+XoBCRTi7eNNHiaiK/DoFZygrojJI/RTTs9QjFsnNjIlKkMr+whS1CpOBZWbTQz53vMGZkD5uORn6dzkGsEV5HScDVuaMARGC69hVjrb7WPO6jcQwHVc5joJ7K2L4EuyLbSg+aljN/RWt26WUYzeVsPPny4pYUWPBuYRuhlV/vS7avvByAIkkNJsvuYnp5JLqtLaxp44dh3k0N7hiG9F1k1rw3cYoe+PSTNpk1TRW0kJqr8g/Glcn59tFxouYK63Yp2ws4kMyTC5YrBTruVnsDTjRWLr2cRjmN7hO0OfcYT33QF6m+4iMIPZ1w52pb6Fnx6Q0EXr6yGHh2B6xslOa79LSFaP985qNbp7amHqO+/fj/ZQn2aHvJwnW1Okp4IO2hHhog9kWARapfCgALIlIB2QVvqkmTCgmu1EfsTiOTd0kNxSVI/qp5ewH0ZYB2ZLa8xmZlP3wPHF8GohHpWG+blbPlHHAGkn3glXlYin01hCjn2+vHLCNCw/7JFQ1RwURiVrPcQXhsCdb/tD8Jy4mRr9i5lWwK4Qtzy7gNOAihushZyzQgrh51mvMTkaZrWXP2sM= 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:(13230031)(4636009)(396003)(39860400002)(376002)(346002)(136003)(230173577357003)(230922051799003)(230273577357003)(64100799003)(451199024)(82310400011)(1800799012)(186009)(40470700004)(46966006)(36840700001)(31686004)(40480700001)(40460700003)(356005)(81166007)(47076005)(2906002)(5660300002)(82740400003)(83380400001)(6512007)(336012)(6666004)(6506007)(36860700001)(26005)(41300700001)(478600001)(6486002)(70206006)(6916009)(316002)(70586007)(8676002)(44832011)(8936002)(31696002)(86362001); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Dec 2023 12:46:05.6476 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5a92db6c-0f88-4153-000f-08dbf6594ff6 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: AMS0EPF000001A0.eurprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PA4PR08MB6205 X-Spam-Status: No, score=-12.2 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.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 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784536680456271975 X-GMAIL-MSGID: 1784536680456271975 Change the handling of some attribute mutual exclusions to use the generic attribute exclusion lists, and fix some asymmetric exclusions by adding the exclusions for always_inline after noinline or target_clones. Aside from the new always_inline exclusions, the only change is functionality is the choice of warning message displayed. All warnings about attribute mutual exclusions now use the same message. gcc/ada/ChangeLog: * gcc-interface/utils.cc (attr_noinline_exclusions): New. (attr_always_inline_exclusions): Ditto. (attr_target_exclusions): Ditto. (attr_target_clones_exclusions): Ditto. (gnat_internal_attribute_table): Add new exclusion lists. (handle_noinline_attribute): Remove custom exclusion handling. (handle_target_attribute): Ditto. (handle_target_clones_attribute): Ditto. diff --git a/gcc/ada/gcc-interface/utils.cc b/gcc/ada/gcc-interface/utils.cc index e7b5c7783b1f1c702130c8879c79b7e329764b09..f2c504ddf8d3df11abe81aec695c9eea0b39da6c 100644 --- a/gcc/ada/gcc-interface/utils.cc +++ b/gcc/ada/gcc-interface/utils.cc @@ -130,6 +130,32 @@ static const struct attribute_spec::exclusions attr_stack_protect_exclusions[] = { NULL, false, false, false }, }; +static const struct attribute_spec::exclusions attr_always_inline_exclusions[] = +{ + { "noinline", true, true, true }, + { "target_clones", true, true, true }, + { NULL, false, false, false }, +}; + +static const struct attribute_spec::exclusions attr_noinline_exclusions[] = +{ + { "always_inline", true, true, true }, + { NULL, false, false, false }, +}; + +static const struct attribute_spec::exclusions attr_target_exclusions[] = +{ + { "target_clones", true, true, true }, + { NULL, false, false, false }, +}; + +static const struct attribute_spec::exclusions attr_target_clones_exclusions[] = +{ + { "always_inline", true, true, true }, + { "target", true, true, true }, + { NULL, false, false, false }, +}; + /* Fake handler for attributes we don't properly support, typically because they'd require dragging a lot of the common-c front-end circuitry. */ static tree fake_attribute_handler (tree *, tree, tree, int, bool *); @@ -165,7 +191,7 @@ const struct attribute_spec gnat_internal_attribute_table[] = { "strub", 0, 1, false, true, false, true, handle_strub_attribute, NULL }, { "noinline", 0, 0, true, false, false, false, - handle_noinline_attribute, NULL }, + handle_noinline_attribute, attr_noinline_exclusions }, { "noclone", 0, 0, true, false, false, false, handle_noclone_attribute, NULL }, { "no_icf", 0, 0, true, false, false, false, @@ -175,7 +201,7 @@ const struct attribute_spec gnat_internal_attribute_table[] = { "leaf", 0, 0, true, false, false, false, handle_leaf_attribute, NULL }, { "always_inline",0, 0, true, false, false, false, - handle_always_inline_attribute, NULL }, + handle_always_inline_attribute, attr_always_inline_exclusions }, { "malloc", 0, 0, true, false, false, false, handle_malloc_attribute, NULL }, { "type generic", 0, 0, false, true, true, false, @@ -192,9 +218,9 @@ const struct attribute_spec gnat_internal_attribute_table[] = { "simd", 0, 1, true, false, false, false, handle_simd_attribute, NULL }, { "target", 1, -1, true, false, false, false, - handle_target_attribute, NULL }, + handle_target_attribute, attr_target_exclusions }, { "target_clones",1, -1, true, false, false, false, - handle_target_clones_attribute, NULL }, + handle_target_clones_attribute, attr_target_clones_exclusions }, { "vector_size", 1, 1, false, true, false, false, handle_vector_size_attribute, NULL }, @@ -6755,16 +6781,7 @@ handle_noinline_attribute (tree *node, tree name, int ARG_UNUSED (flags), bool *no_add_attrs) { if (TREE_CODE (*node) == FUNCTION_DECL) - { - if (lookup_attribute ("always_inline", DECL_ATTRIBUTES (*node))) - { - warning (OPT_Wattributes, "%qE attribute ignored due to conflict " - "with attribute %qs", name, "always_inline"); - *no_add_attrs = true; - } - else - DECL_UNINLINABLE (*node) = 1; - } + DECL_UNINLINABLE (*node) = 1; else { warning (OPT_Wattributes, "%qE attribute ignored", name); @@ -7063,12 +7080,6 @@ handle_target_attribute (tree *node, tree name, tree args, int flags, warning (OPT_Wattributes, "%qE attribute ignored", name); *no_add_attrs = true; } - else if (lookup_attribute ("target_clones", DECL_ATTRIBUTES (*node))) - { - warning (OPT_Wattributes, "%qE attribute ignored due to conflict " - "with %qs attribute", name, "target_clones"); - *no_add_attrs = true; - } else if (!targetm.target_option.valid_attribute_p (*node, name, args, flags)) *no_add_attrs = true; @@ -7096,23 +7107,8 @@ handle_target_clones_attribute (tree *node, tree name, tree ARG_UNUSED (args), { /* Ensure we have a function type. */ if (TREE_CODE (*node) == FUNCTION_DECL) - { - if (lookup_attribute ("always_inline", DECL_ATTRIBUTES (*node))) - { - warning (OPT_Wattributes, "%qE attribute ignored due to conflict " - "with %qs attribute", name, "always_inline"); - *no_add_attrs = true; - } - else if (lookup_attribute ("target", DECL_ATTRIBUTES (*node))) - { - warning (OPT_Wattributes, "%qE attribute ignored due to conflict " - "with %qs attribute", name, "target"); - *no_add_attrs = true; - } - else - /* Do not inline functions with multiple clone targets. */ - DECL_UNINLINABLE (*node) = 1; - } + /* Do not inline functions with multiple clone targets. */ + DECL_UNINLINABLE (*node) = 1; else { warning (OPT_Wattributes, "%qE attribute ignored", name);