From patchwork Thu Nov 9 13:43:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Victor Do Nascimento X-Patchwork-Id: 79482 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 304A838319CF for ; Thu, 9 Nov 2023 13:44:48 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from EUR03-AM7-obe.outbound.protection.outlook.com (mail-am7eur03on2050.outbound.protection.outlook.com [40.107.105.50]) by sourceware.org (Postfix) with ESMTPS id D04E43858C3A for ; Thu, 9 Nov 2023 13:44:29 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D04E43858C3A 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 D04E43858C3A Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=40.107.105.50 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1699537471; cv=pass; b=LGIOgstjurU/VCin71K7EO0RKbfk+40jBiFR8zkuQy1j9mE1IBvf7x+2jymfBs1i/DRFAm1xeHvvzEuAjt6OOLsNLHqQFaMxe2VkCxLYX2wj3Ft3umXFS5dk5W1XaW4K69BDaTzphuzupvXnx0V5SzWS4vz5VLNoLVR1kBS65HQ= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1699537471; c=relaxed/simple; bh=xIsHk707CDKddqmg0rlBwiHRmhEYq+cQTciket/txIU=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=C6ibuRwAjsxu8+Iou6YnnfTPPC9tRjJu8Ivh00jrgxkItSvM3881VMlhvPdyyBH+rA1LOKxrchonsjPXal1CROqeFyC3ouIIS0QaH5oQh6NWc/OFokR3WqUgc0uZXIp3HU6/BtAF35cP4bP1CPRSrllocURTdclw6G9B+qrbswc= ARC-Authentication-Results: i=3; server2.sourceware.org ARC-Seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=QXNxWB2yG/sQ9FEPBvhkZ1kJwEd9t3kQokWOxr5C9QZ1irOnnEhkJx5KQtrN/lC/n+AsLFTQ2x84k5LszniWlbYfGAL1PUWWPn1WeG6uRe/POyLj72NFjXDyM/G4OJMA+vt396+nOOOuyAVOOFahe4C2+k4rQ9rFeHLZlxyvQMtOYQQsZK+aViRVfLe/951DFUMRMEWcL9sg4g899qXt/Gth/H68Z/IXqFcXtfiCgFdXyp0aRMI9kYmlVtXUQDzVSJAQB1+cI35Xs7YRbaDQmpsz/3aufNDFmAM7/oDDVuAJPr+TppDSmzVxHMb8doIGC4To1sc1Z9oGk8fWiUwmLA== 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=9ZC4CLQd3fZ3GzpLJUBCWImolLomGAzFUEp6S/H2LHc=; b=hxz3/r0fzgC2ctwXLEbRHP2Lse/rFyNmGRv+gLBKs0Lxjj00EXhNu7UHw+HmfF9vfUaP0FcnYV6t/QNX9igjwFNqH6PVPvTK+zbdO4bkd+vmV2P1Ss6sqfKz1IkDMN20oBEer7gd4jJ9VO00xFznHD5QCliyIpp2aERyVK9oCpDgiya4B8g7olCcs1vmBXD4/FjHdjB6xqUtaWZ+PtFBADlpOfmOiMgiczmkKYHtZq2Hq5a4PwyLtiN73Ga+pfhQNNPsGZqmsBL9Pp6egs7uw+KVye+aWYOR9mCGH3UfnU+qBLQ566HBz8hiVabirhG06lvPjsxTT10WC5nIJBzKxw== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=sourceware.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] 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=9ZC4CLQd3fZ3GzpLJUBCWImolLomGAzFUEp6S/H2LHc=; b=cdmSjfktJmFjZZAhgnyVLCFQG806udOvC3JMHigYtiN2aGy+Ns2R7Wai/S3KnWxYn/qzLuOx8V1FRtvSnQX8PDx3jtgny4IgxaMp4z2DDh2aGimjSHKHLR0LjZR1dAuCVTZ5yPNNgSj54Vgce1hD3O8yTZ9EUEp/EZx96HMn9TY= Received: from DU2PR04CA0190.eurprd04.prod.outlook.com (2603:10a6:10:28d::15) by AS2PR08MB10084.eurprd08.prod.outlook.com (2603:10a6:20b:648::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.29; Thu, 9 Nov 2023 13:44:26 +0000 Received: from DB1PEPF00039230.eurprd03.prod.outlook.com (2603:10a6:10:28d:cafe::75) by DU2PR04CA0190.outlook.office365.com (2603:10a6:10:28d::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.18 via Frontend Transport; Thu, 9 Nov 2023 13:44:26 +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 DB1PEPF00039230.mail.protection.outlook.com (10.167.8.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.18 via Frontend Transport; Thu, 9 Nov 2023 13:44:26 +0000 Received: ("Tessian outbound 26ee1d40577c:v228"); Thu, 09 Nov 2023 13:44:26 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 97ce08b37a881911 X-CR-MTA-TID: 64aa7808 Received: from 944dd29b5542.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 35AE0C75-9B65-42F6-BC8E-C3429FC45EA8.1; Thu, 09 Nov 2023 13:44:20 +0000 Received: from EUR02-DB5-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 944dd29b5542.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Thu, 09 Nov 2023 13:44:20 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nOGvawoWvxJT0Uz0Xs1lNA0b36DWfmh5BZIZjvTFusaES6zj+LJjS4dyJTZDockQKeGDSmCKFLzOk8nGh5y2ygQRgcGTkMyjgpzzkb8Ypr+PnaLP/fRsNBHf2I3g1BH4DiXQxmqHAvcfzMATL6uGHO81HbanNgZtvmxlgfmD/tvJVcfifxaR+Rw1c18gfn7cuPsmgA+zygg8OrPmoYpGouSEYXpQzhDAr+MAKBO+MmXYijTI+MnzvGFXxzMEZMxvx7U/lDXK/VVsAC/mrCxz0eHqX4fKJGWUpqF+oEAL9AYyQC90aebTihP7WWC6F8nBAdGG7qoYCTwHphgu/y1khA== 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=9ZC4CLQd3fZ3GzpLJUBCWImolLomGAzFUEp6S/H2LHc=; b=N/dilAWMWjHRN892p9dRBFIbEu1DFwxcgmQ+S1Rt/6iWYJ57ZrzC80izT+LibpyT82zxzXF3L0IzCigA0FHodxydCm7mUPo05XIHQoAeeFcQyZzgxcUjPpfAkAT5tvdngpnNwkIxn/Hk3xQ9YUlbSgM/2+UiB/bWcLiBqavg/LMWxD3j9BJSfBOq1kvjMnqlrsqgQh65IYEyWo0XjG7XJ+40vemWrtRB6IP7qIN4hXux83A/gALXy8TpG2BqCwYTD0J5re3ZnlhHQdGSHZZT8Cc/RBRLZL1Un0BDx4YyVx4XrV/pW0kau2jlO/mQJYTB1x6MPxB9RTMnlYbrxPU3xQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=sourceware.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 (0) 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=9ZC4CLQd3fZ3GzpLJUBCWImolLomGAzFUEp6S/H2LHc=; b=cdmSjfktJmFjZZAhgnyVLCFQG806udOvC3JMHigYtiN2aGy+Ns2R7Wai/S3KnWxYn/qzLuOx8V1FRtvSnQX8PDx3jtgny4IgxaMp4z2DDh2aGimjSHKHLR0LjZR1dAuCVTZ5yPNNgSj54Vgce1hD3O8yTZ9EUEp/EZx96HMn9TY= Received: from DB9PR01CA0025.eurprd01.prod.exchangelabs.com (2603:10a6:10:1d8::30) by AS8PR08MB9791.eurprd08.prod.outlook.com (2603:10a6:20b:614::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.18; Thu, 9 Nov 2023 13:44:17 +0000 Received: from DU6PEPF00009525.eurprd02.prod.outlook.com (2603:10a6:10:1d8:cafe::77) by DB9PR01CA0025.outlook.office365.com (2603:10a6:10:1d8::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.19 via Frontend Transport; Thu, 9 Nov 2023 13:44:17 +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 DU6PEPF00009525.mail.protection.outlook.com (10.167.8.6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6977.16 via Frontend Transport; Thu, 9 Nov 2023 13:44:17 +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.32; Thu, 9 Nov 2023 13:44:15 +0000 Received: from e125768.cambridge.arm.com (10.2.78.50) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.32 via Frontend Transport; Thu, 9 Nov 2023 13:44:15 +0000 From: Victor Do Nascimento To: CC: , , Victor Do Nascimento Subject: [PATCH] aarch64: Fix error in THE system register checking Date: Thu, 9 Nov 2023 13:43:56 +0000 Message-ID: <20231109134413.3536899-1-victor.donascimento@arm.com> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DU6PEPF00009525:EE_|AS8PR08MB9791:EE_|DB1PEPF00039230:EE_|AS2PR08MB10084:EE_ X-MS-Office365-Filtering-Correlation-Id: 2f080d1a-51ba-4d24-46ad-08dbe129fd6b X-LD-Processed: f34e5979-57d9-4aaa-ad4d-b122a662184d,ExtAddr 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: VIrz3fJoB51lb0yvz4UkidCCeU0bHqSHuptQKFglonjaKxCoiueofKo60p00uX+hVyBqkQt7UxnoSnJmpG+OxQxVobXMoxgDeHKtTtYqLeP3SZ7w4fkSy9s6iIEMk5vxrvssAO5AV5PeDZi5thcdnefumnT3CxQqCiCaDqTZCXW9SPDWuNysvcJ0hGIUrkDZyDI48ACZzuUkhcH98oekJmmMKDlY7eGTfju2VjBB44+1fGvmRq996Dp6cIQOZqpTx7XW3R510SinPFb5QtFypu8SYD/Fgk5RVrMa19eI8pfolNBROVRdTkp1ciRRXsp5NgUXVSwm5HSSqXC+EO1xdAppNy5lx3dfQot28IYBV4ZHb2JxKt0A+x2OfAUCrdBJusgOFrbjvoNjQwCSGxyh4bhkRDEuWC9DJdIj5kOE9GnfX0Oi0PKGTL6vKGYo+/KG6A/fOxbDWPdODF3rMg6SevVi2MJj92Vsxk0OJQ0Zmccv2Yq/mQSjzBn/yRgmXCOntFtg/XjtaWj27oTXO/ZPG6AyY6KDBeiXTVyrIbUna+EdkVtGxLA+HtoJ4S4M0SMCqUfrHlRXUF3rk9YoYFrIirnFVuidolQZZM7i8Ywj16w5dYDtFOFbJkeocevRfQkLtcxIGQNvcAgYSI6KkiZH9N7ipp95Ig8QDF2SwANjVBocX1RvHrr4q/bT6rCjCMiuY6+7ojhkCDuCnK/OOWNzacK7atmDsN51pXYEqvkVG80cXzhcrtmswfoMi5CRXW8m 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:(13230031)(4636009)(136003)(346002)(396003)(376002)(39860400002)(230922051799003)(451199024)(64100799003)(186009)(82310400011)(1800799009)(36840700001)(46966006)(40470700004)(36756003)(40460700003)(5660300002)(81166007)(82740400003)(336012)(478600001)(316002)(86362001)(6916009)(4326008)(70586007)(8676002)(8936002)(70206006)(54906003)(47076005)(26005)(426003)(966005)(7696005)(356005)(1076003)(2616005)(83380400001)(6666004)(36860700001)(41300700001)(2906002)(40480700001)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB9791 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB1PEPF00039230.eurprd03.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: a404e2da-4796-4d7d-9725-08dbe129f7ec X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: v79eTqhEpT5aeFYAZQJXXZOOlGHDUVyWn4ZaQqdbhhBwDRssaGeafuIUhTee66x/d7IUmysS7CSD9ZbbPUNEZLd5s4yqMfnHflHGxHYyf0pPj9UZhNZv+L6ryEDyjnF0c+HH14gleAKwlEBrqE/vbywb/wHWTibfRhkCIHP0TlP9LonYEuqPxGI158hm/QeMg3hPsMn03uLq9kgfgr4ff0HdxH3ut6WWiRBPadZsO8iRK4Yxc2OWenmeoIZ8DzqqSjqzk0KKUGEBb5UP/sXy3xz4oZso/zAVmJsxtWByoNCWDknileKv4pSILR3uhyg1Tm+vM1K9SJL4NxWpiZsLwd88aTr2Th9iS4GjnxszXitFLZvvkBhGwmpGEYsc2rstpItO+WrCn6vXq5b101aQSmXipC1BkEoBO0l/GUsvdJhX42JkRNGIjRkQqBx4ZqhHQy5tmn+t8RTZRaG1+Ca/up2AwG124BsAbVFZ+0xIm09iooXHiN7WENyl0Um5F21lo63sK6aty0x23/bud/dcRBfQUV3ECg869HA+DE5BwRgcOuLKku5eEde3IIgjHBRxFLKuBtKiYANqCGwJm1nYvku5KYb+SkcwDliqvNSPBxu+jRruAcyqFeCBp/gC3hOoO9+ic3Wz2s2gGaW4eGSGZ8JJlXxYtOCo3kbt6JvFUSUT7mvs+RVf+SU+gPpjmxKmtLcJtsfl1WiL/gLtlu5WDUuEXt0m00s/bfOeR5qqsLw= 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)(39860400002)(136003)(376002)(346002)(396003)(230922051799003)(186009)(451199024)(82310400011)(64100799003)(1800799009)(40470700004)(36840700001)(46966006)(36860700001)(40480700001)(40460700003)(7696005)(1076003)(478600001)(2616005)(6916009)(966005)(336012)(316002)(426003)(54906003)(70586007)(70206006)(82740400003)(8676002)(26005)(4326008)(8936002)(36756003)(5660300002)(6666004)(81166007)(2906002)(83380400001)(47076005)(41300700001)(86362001); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Nov 2023 13:44:26.4631 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2f080d1a-51ba-4d24-46ad-08dbe129fd6b 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: DB1PEPF00039230.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS2PR08MB10084 X-Spam-Status: No, score=-12.5 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: binutils@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces+patchwork=sourceware.org@sourceware.org The erroneous omission of a "reg_value == " in the THE system register encoding check added in [1] led to an error which was not picked up in GCC but which was flagged in Clang due to its use of [-Werror,-Wconstant-logical-operand] check. Together with this fix we add a new test for the THE registers to pick up their illegal use, adding an extra and important layer of validation. Furthermore, in separating system register from instruction implementation (with which only the former was of concern in the cited patch), additions made to `aarch64-tbl.h' are rolled back so that these can be added later when adding THE instructions to the codebase, a more natural place for these changes. [1] https://sourceware.org/pipermail/binutils/2023-November/130314.html opcodes/ChangeLog: * aarch64-opc.c (aarch64_sys_ins_reg_supported_p): Fix typo. * aarch64-tbl.h (THE): Remove. (aarch64_feature_set aarch64_feature_the): Likewise. gas/ChangeLog: * testsuite/gas/aarch64/illegal-sysreg-8.l: Add tests for THE system registers. * testsuite/gas/aarch64/illegal-sysreg-8.s: Likewise. --- gas/testsuite/gas/aarch64/illegal-sysreg-8.l | 8 ++++++++ gas/testsuite/gas/aarch64/illegal-sysreg-8.s | 2 ++ opcodes/aarch64-opc.c | 2 +- opcodes/aarch64-tbl.h | 3 --- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/gas/testsuite/gas/aarch64/illegal-sysreg-8.l b/gas/testsuite/gas/aarch64/illegal-sysreg-8.l index 6a5f8fe567c..773e8d80f7a 100644 --- a/gas/testsuite/gas/aarch64/illegal-sysreg-8.l +++ b/gas/testsuite/gas/aarch64/illegal-sysreg-8.l @@ -3,6 +3,14 @@ .*: *Info: macro .* .*: Error: selected processor does not support system register name 'ccsidr2_el1' .*: *Info: macro .* +.*: Error: selected processor does not support system register name 'rcwmask_el1' +.*: *Info: macro .* +.*: Error: selected processor does not support system register name 'rcwmask_el1' +.*: *Info: macro .* +.*: Error: selected processor does not support system register name 'rcwsmask_el1' +.*: *Info: macro .* +.*: Error: selected processor does not support system register name 'rcwsmask_el1' +.*: *Info: macro .* .*: Error: selected processor does not support system register name 'trfcr_el1' .*: *Info: macro .* .*: Error: selected processor does not support system register name 'trfcr_el1' diff --git a/gas/testsuite/gas/aarch64/illegal-sysreg-8.s b/gas/testsuite/gas/aarch64/illegal-sysreg-8.s index a1a7ae6faed..0ce61ddfe45 100644 --- a/gas/testsuite/gas/aarch64/illegal-sysreg-8.s +++ b/gas/testsuite/gas/aarch64/illegal-sysreg-8.s @@ -16,6 +16,8 @@ .arch armv8.2-a roreg ccsidr2_el1 + rwreg rcwmask_el1 + rwreg rcwsmask_el1 .arch armv8.3-a diff --git a/opcodes/aarch64-opc.c b/opcodes/aarch64-opc.c index 5a0f0e9f52e..f8d4c1a4d33 100644 --- a/opcodes/aarch64-opc.c +++ b/opcodes/aarch64-opc.c @@ -5037,7 +5037,7 @@ aarch64_sys_ins_reg_supported_p (const aarch64_feature_set features, return true; if ((reg_value == CPENC (3,0,13,0,3) - || CPENC (3,0,13,0,6)) + || reg_value == CPENC (3,0,13,0,6)) && AARCH64_CPU_HAS_FEATURE (features, THE)) return true; diff --git a/opcodes/aarch64-tbl.h b/opcodes/aarch64-tbl.h index feea209ea30..74fd6695d81 100644 --- a/opcodes/aarch64-tbl.h +++ b/opcodes/aarch64-tbl.h @@ -2578,8 +2578,6 @@ static const aarch64_feature_set aarch64_feature_chk = AARCH64_FEATURE (CHK); static const aarch64_feature_set aarch64_feature_gcs = AARCH64_FEATURE (GCS); -static const aarch64_feature_set aarch64_feature_the = - AARCH64_FEATURE (THE); #define CORE &aarch64_feature_v8 #define FP &aarch64_feature_fp @@ -2641,7 +2639,6 @@ static const aarch64_feature_set aarch64_feature_the = #define CSSC &aarch64_feature_cssc #define CHK &aarch64_feature_chk #define GCS &aarch64_feature_gcs -#define THE &aarch64_feature_the #define CORE_INSN(NAME,OPCODE,MASK,CLASS,OP,OPS,QUALS,FLAGS) \ { NAME, OPCODE, MASK, CLASS, OP, CORE, OPS, QUALS, FLAGS, 0, 0, NULL }