From patchwork Fri Feb 24 18:41:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luis Machado X-Patchwork-Id: 65615 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 E5E3F385B507 for ; Fri, 24 Feb 2023 18:42:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E5E3F385B507 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1677264121; bh=Xx7Nb1UGaI4yFCDssN18/jwlMyxhSKgneR6e5SqsHgY=; 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=WBQ8kWNWMZmTfcL/8c2Xy/yHWaG/odX1j/SrDMP3i9J9XYQZRwCt0UnlVjbHwIeoJ U78pR49q2jWxiicFcD0eqlMDF5mhyANr/hFLtfDC05Rr/sxIjZItfr8zzFioPkXDLV BwbWbNBfUMEUsqxOufBJvNRwiEjZY2leNWNctrPA= X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from EUR03-AM7-obe.outbound.protection.outlook.com (mail-am7eur03on2046.outbound.protection.outlook.com [40.107.105.46]) by sourceware.org (Postfix) with ESMTPS id DE9CD385B53C for ; Fri, 24 Feb 2023 18:41:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DE9CD385B53C Received: from DB7PR05CA0017.eurprd05.prod.outlook.com (2603:10a6:10:36::30) by DB8PR08MB5369.eurprd08.prod.outlook.com (2603:10a6:10:11c::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.24; Fri, 24 Feb 2023 18:41:32 +0000 Received: from DBAEUR03FT008.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:36:cafe::87) by DB7PR05CA0017.outlook.office365.com (2603:10a6:10:36::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.24 via Frontend Transport; Fri, 24 Feb 2023 18:41: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 DBAEUR03FT008.mail.protection.outlook.com (100.127.142.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.24 via Frontend Transport; Fri, 24 Feb 2023 18:41:32 +0000 Received: ("Tessian outbound 8038f0863a52:v132"); Fri, 24 Feb 2023 18:41:32 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: bb38db4d392d445e X-CR-MTA-TID: 64aa7808 Received: from 88299c4783b5.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 65CEC093-3114-4188-88BB-B1A827647526.1; Fri, 24 Feb 2023 18:41:25 +0000 Received: from EUR04-HE1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 88299c4783b5.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 24 Feb 2023 18:41:25 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=obYd1m09XyJiZ8t8N9L961E1iCJ9nzAzYUHj3rvM+C6X6PYZj7/th606oFM2FGIMYF/ZOlRLSBd+Yr++fJ4Fr+UR4J7u560KtqVpUZ/ntXvb5teb5IYZcyrcEc1e0jXh4zZXtj9cMJrv9r8qv8LkCvkawFMfdfc3l7JxvkkQiWtK5Xajp4R1yjVpw1/z5oK4a+NrujbojoK66tt62cjVNIFDwVypN7G8MICTieuxiiw/R275GLfHqNbXojZNtRkz2+E/hjk5fSYjo0OD+1kNcb8p/BFh1gbBXvqteoupBi7X7Ntp+VBsCH10V987J1CathgJ6DjMChLuKcCsrdy8EA== 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=Xx7Nb1UGaI4yFCDssN18/jwlMyxhSKgneR6e5SqsHgY=; b=Tixhs108BYfA30pweSVQ12mmFB69tStrh1LlQPFqEBTaJqbUr/7JEzGQ/5qk2q0/ALu32FLK9Sw2dcO1QC9FESZCdb9DGqrDbSdAuRAy/bqKeEho7mib1N5+W5WwSPFImKuTXnigDct43CUw1Cf+DhcDEqD/9qJjMNOanFKaLS4kpP9Rq0OPHdb+npZxrK74yXFrVQ+/BYgtW0oGITXhzPnkO2Qpq5AiJYNGWs6hiH7qIATnGL6tcY2TEi1b9fHYF2Dy8OyxjcMJYEstTW/ec/RUHMOyz8uG5+3ryVCNGYOXcQMECDXsRe+/VFnAWDO9t4HGxaOf1uXC+H92Rl7kPA== 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 Received: from DU2PR04CA0175.eurprd04.prod.outlook.com (2603:10a6:10:2b0::30) by AS8PR08MB10314.eurprd08.prod.outlook.com (2603:10a6:20b:5c0::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.21; Fri, 24 Feb 2023 18:41:23 +0000 Received: from DBAEUR03FT063.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:2b0:cafe::ae) by DU2PR04CA0175.outlook.office365.com (2603:10a6:10:2b0::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.24 via Frontend Transport; Fri, 24 Feb 2023 18:41:22 +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 DBAEUR03FT063.mail.protection.outlook.com (100.127.142.255) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6134.24 via Frontend Transport; Fri, 24 Feb 2023 18:41:22 +0000 Received: from AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) 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.17; Fri, 24 Feb 2023 18:41:22 +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.17; Fri, 24 Feb 2023 18:41:21 +0000 Received: from e129171.arm.com (10.57.90.34) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.17 via Frontend Transport; Fri, 24 Feb 2023 18:41:20 +0000 To: CC: Subject: [PATCH, v2] [gdb/doc] aarch64: Expand documentation of XML features Date: Fri, 24 Feb 2023 18:41:23 +0000 Message-ID: <20230224184123.2172049-1-luis.machado@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230223095244.1813332-1-luis.machado@arm.com> References: <20230223095244.1813332-1-luis.machado@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DBAEUR03FT063:EE_|AS8PR08MB10314:EE_|DBAEUR03FT008:EE_|DB8PR08MB5369:EE_ X-MS-Office365-Filtering-Correlation-Id: 648d324c-5c54-4bd0-36cf-08db1696bffe 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: aYorTVY0typCnQNEGWct/EiAkmeB8XkadAEENA0yN/M/apMUYbQfkIj5/jwcMK8M9ygrGe26eRBL3FGyhpMdf/c5JACEtPgb0Hmlnv2NHQXzu7fpgs5tVaaMldVdkiq9x5FOYknecCe+KFhboLbdOovz1WvhuiJcJXgUiavCA9LJK32SOeAYwYayXAetN35g9eT8mWRIv1j3z9CD68Wz+MxqIvcnxbCgoA4TVo+PTt0oe9/N9xyp2yRvnysRVrckdYy2a5hL+8rSn5gR49LiiRzxxU+Y4YUAxSRgYVDyrY+rTgZn0nZptovHHRiGNhtlXOnQ1+P/r5L4bqY2+KUO/NV1TN6VG8nK6xIYYRgFH7tt115pAnR27RGdUejs2CPokUO0XfHTkKr8IBU9TdDjIYEoC4sjX+luyDLPoQoIXJGQMdQNNgQ508yKmQENmumAxRy/5p7o14UxcDZomS242gxF4cT4egueEnPB+IsS6yvqBpvjvwGPvb99g1NzeIdITJwYy4BgTcBOoRo+/Fa0Grl8WLxMvrgfiCwcQeJs0B83GD+34u+BjCpQSL6mUKKqzpu2eUXGUSkmd3N6vOKl8vFNWSXlBsTONN2dnrU0QPd2xr2vSWnK+kjv+Votfo7hSZQ32exG3cVcbTg5e5iRWU7XpC+KsoOggma4Nt6s5f8KI5lxeT8s4how/9cKIBGxNq5+2F+nhOFMFVA6Lmg3Tw== 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:(13230025)(4636009)(39860400002)(376002)(346002)(396003)(136003)(451199018)(46966006)(36840700001)(7696005)(478600001)(1076003)(186003)(26005)(81166007)(47076005)(426003)(6916009)(70206006)(316002)(336012)(4326008)(41300700001)(8676002)(83380400001)(8936002)(44832011)(2906002)(36860700001)(5660300002)(82740400003)(2616005)(356005)(82310400005)(86362001)(70586007)(40480700001)(36756003)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB10314 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DBAEUR03FT008.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 160daade-d990-4541-e91c-08db1696ba32 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: t/PKxku4YGwUdS/FJaYk0/VOeu5rFB6DnUHXoNW2xibfeEWecVIu9/mhN9D9WoyTQTbqXrKUlk+aZhG+aDXi6es8ymSpD5w2Qxoqk76XJ9RwcuIFobirEKoEoXWfCA+3H2Ffu0Y44ZGDar4IrluF6jGtngcq6BdphIgZiHJ0lpaRcWgGwkTsVwRwB5yjvkFWQSVGYdJgl4ePnIxeJA4gBa1RQilN8+/jetU6b4XsuYqe4FRvWhT3rcYCXESkncScf8FGrqRAyqBAst49cglfV9loYk3M6a1jX0OQl+a+l+Nhl1A3hJIfNw/2FkG8jJlmIpvWTk2Q+NRhEE64Jn5qgwtbHxendGARaGrTWasgMva4KVVXHo8W8MKgW96k5t5mJ9a3ntUjbNWiQH8Y4o2pnfFzJ/3j5AtqtGmlG1pnO/gGBXaQi3dQUjRQnqE8RX+SVfmB4Xt7KGiVsHWY79vKNcatFbE1iJDAF5kcf1FjmdoownE/63ip8jpsgAEypMYg0U7gLRqWFA9awcucTyjqYSGHm6o4iEXSV/1C0P/VWjU0xL+6ivBqONhkGf5ljqZDsMcPtQIy/I05O6g1SNdofTelucHiCiFoX4jgF/s+LInqYQRaDEdMMoPOu45Z8gGQ2UcoTbRJwWOCBVXklAa15GAsI8VlNV7vX5KqTX8i7r9N2iIg+7/ttvxwkpZUngCoENOspCVYUmoS2uUt9z2kEA== 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:(13230025)(4636009)(136003)(396003)(346002)(376002)(39860400002)(451199018)(46966006)(36840700001)(40470700004)(8936002)(81166007)(316002)(82740400003)(336012)(36756003)(186003)(26005)(478600001)(44832011)(40460700003)(1076003)(7696005)(86362001)(40480700001)(2906002)(2616005)(5660300002)(82310400005)(41300700001)(426003)(47076005)(36860700001)(83380400001)(8676002)(6916009)(4326008)(70206006)(70586007); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Feb 2023 18:41:32.4914 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 648d324c-5c54-4bd0-36cf-08db1696bffe 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: DBAEUR03FT008.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR08MB5369 X-Spam-Status: No, score=-11.3 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, RCVD_IN_VALIDITY_RPBL, 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: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Luis Machado via Gdb-patches From: Luis Machado Reply-To: Luis Machado Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" Similar to the arm target documentation situation, the documentation of the XML features for AArch64 targets is rather brief. I have received the same feedback that what gdb carries in the documentation is quite unclear from the perspective of what debugging servers should define in the XML features, how and what the outcome is in gdb. This patch attempts to clarify a bit more what all the possible features are. --- gdb/doc/gdb.texinfo | 210 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 202 insertions(+), 8 deletions(-) diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index efb059efd46..4e259acb1cd 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -47761,20 +47761,214 @@ registers using the capitalization used in the description. @subsection AArch64 Features @cindex target descriptions, AArch64 features +@subsubsection AArch64 core registers feature + The @samp{org.gnu.gdb.aarch64.core} feature is required for AArch64 -targets. It should contain registers @samp{x0} through @samp{x30}, -@samp{sp}, @samp{pc}, and @samp{cpsr}. +targets. It must contain the following: + +@itemize @minus +@item +@samp{x0} through @samp{x30}, the general purpose registers, with size of +64 bits. Register @samp{x30} is also known as the @dfn{link register}, +or @samp{lr}. +@item +@samp{sp}, the stack pointer register or @samp{x31}. It is 64 bits in size and +has a type of @samp{data_ptr}. +@item +@samp{pc}, the program counter register. It is 64 bits in size and has a type +of @samp{code_ptr}. +@item +@samp{cpsr}, the current program status register. It is 32 bits in size +and has a custom flags type. +@end itemize + +The semantics of the individual flags and fields in @samp{cpsr} can change as +new architectural features are added. The current layout can be found in the +aarch64-core.xml file. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. + +@subsubsection AArch64 floating-point registers feature The @samp{org.gnu.gdb.aarch64.fpu} feature is optional. If present, -it should contain registers @samp{v0} through @samp{v31}, @samp{fpsr}, -and @samp{fpcr}. +it must contain the following registers: + +@itemize @minus +@item +@samp{v0} through @samp{v31}, the vector registers with size of 128 bits. The +type is a custom vector type. +@item +@samp{fpsr}, the floating-point status register. It is 32 bits in size and has +a custom flags type. +@item +@samp{fpcr}, the floating-point control register. It is 32 bits in size and has +a custom flags type. +@end itemize + +The semantics of the individual flags and fields in @samp{fpsr} and @samp{fpcr} +can change as new architectural features are added. + +The types for the vector registers, @samp{fpsr} and @samp{fpcr} registers can +be found in the aarch64-fpu.xml file. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. + +@subsubsection AArch64 SVE registers feature The @samp{org.gnu.gdb.aarch64.sve} feature is optional. If present, -it should contain registers @samp{z0} through @samp{z31}, @samp{p0} -through @samp{p15}, @samp{ffr} and @samp{vg}. +it means the target supports the Scalable Vector Extension and must contain +the following registers: + +@itemize @minus +@item +@samp{z0} through @samp{z31}, the scalable vector registers. Their sizes are +variable and a multiple of 128 bits up to a maximum of 2048 bit. Their type is +a custom union type that helps visualize different sizes of sub-vectors. +@item +@samp{fpsr}, the floating-point status register. It is 32 bits in size and has +a custom flags type. +@item +@samp{fpcr}, the floating-point control register. It is 32 bits in size and has +a custom flags type. +@item +@samp{p0} through @samp{p15}, the predicate registers. Their sizes are +variable, based on the current vector length, and a multiple of +16 bits. Their types are a custom union to help visualize sub-elements. +@item +@samp{ffr}, the First Fault register. It has a variable size based on the +current vector length and is a multiple of 16 bits. The type is the same as +the predicate registers. +@item +@samp{vg}, the vector granule. It represents the number of 64 bits chunks in +a @samp{z} register. It is closely associated with the current vector +length. It has a type of @samp{int}. +@end itemize + +When @value{GDBN} sees the SVE feature, it will assume the Scalable Vector +Extension is supported, and will adjust the sizes of the @samp{z}, @samp{p} +and @samp{ffr} registers accordingly, based on the value of @samp{vg}. + +@value{GDBN} will also create pseudo-registers equivalent to the @samp{v} +vector registers from the @samp{org.gnu.gdb.aarch64.fpu} feature. + +The first 128 bits of the @samp{z} registers overlap the 128 bits of the +@samp{v} registers, so changing one will trigger a change to the other. + +For the types of the @samp{z}, @samp{p} and @samp{ffr} registers, please +check the aarch64-sve.c file. No XML file is available for this feature +because it is dynamically generated based on the current vector length. + +The semantics of the individual flags and fields in @samp{fpsr} and @samp{fpcr} +can change as new architectural features are added. + +The types for the @samp{fpsr} and @samp{fpcr} registers can be found in the +aarch64-sve.c file, and should match what is described in aarch64-fpu.xml. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. + +@subsubsection AArch64 Pointer Authentication registers feature + +The @samp{org.gnu.gdb.aarch64.pauth} optional feature was introduced so +@value{GDBN} could detect support for the Pointer Authentication +extension. If present, it must contain one of two possible register sets. + +Pointer Authentication masks for user-mode: -The @samp{org.gnu.gdb.aarch64.pauth} feature is optional. If present, -it should contain registers @samp{pauth_dmask} and @samp{pauth_cmask}. +@itemize @minus +@item +@samp{pauth_dmask}, the user-mode pointer authentication mask for data +pointers. It is 64 bits in size. +@item +@samp{pauth_cmask}, the user-mode pointer authentication mask for code +pointers. It is 64 bits in size. +@end itemize + +Pointer Authentication masks for user-mode and kernel-mode: + +@itemize @minus +@item +@samp{pauth_dmask}, the user-mode pointer authentication mask for data +pointers. It is 64 bits in size. +@item +@samp{pauth_cmask}, the user-mode pointer authentication mask for code +pointers. It is 64 bits in size. +@item +@samp{pauth_dmask_high}, the kernel-mode pointer authentication mask for +data pointers. It is 64 bits in size. +@item +@samp{pauth_cmask_high}, the kernel-mode pointer authentication mask for +code pointers. It is 64 bits in size. +@end itemize + +If @value{GDBN} sees any of the two sets of registers in this feature, it will +assume the target is capable of signing pointers. If so, @value{GDBN} will +decorate backtraces with a @samp{[PAC]} marker alongside a function that +has a signed link register value that needs to be unmasked/decoded. + +@value{GDBN} will also use the masks to remove non-address bits from pointers. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. + +@subsubsection AArch64 TLS registers feature + +The @samp{org.gnu.gdb.aarch64.tls} optional feature was introduced to expose +the TLS registers to @value{GDBN}. If present, it must contain either one +of the following register sets. + +Only @samp{tpidr}: + +@itemize @minus +@item +@samp{tpidr}, the software thread id register. It is 64 bits in size and has a +type of @samp{data_ptr}. +@end itemize + +Both @samp{tpidr} and @samp{tpidr2}. + +@itemize @minus +@item +@samp{tpidr}, the software thread id register. It is 64 bits in size and has a +type of @samp{data_ptr}. +@item +@samp{tpidr2}, the second software thread id register. It is 64 bits in size +and has a type of @samp{data_ptr}. It may be used in the future alongside +the Scalable Matrix Extension for a lazy restore scheme. +@end itemize + +If @value{GDBN} sees this feature, it will attempt to find one of the +variations of the register set. If @samp{tpidr2} is available, +@value{GDBN} may act on it to display additional data in the future. + +There is no XML for this feature as the presence of @samp{tpidr2} is +determined dynamically at runtime. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. + +@subsubsection AArch64 MTE registers feature + +The @samp{org.gnu.gdb.aarch64.mte} optional feature was introduced so +@value{GDBN} could detect support for the Memory Tagging Extension and +control memory tagging settings. If present, this feature must have the +following register: + +@itemize @minus +@item +@samp{tag_ctl}, the tag control register. It is 64 bits in size and has a type +of @samp{uint64}. +@end itemize + +Memory Tagging detection is done via a runtime check though, so the presence +of this feature and register is not enough to enable memory tagging support. + +This restriction may be lifted in the future. + +Extra registers are allowed in this feature, but they will not affect +@value{GDBN}. @node ARC Features @subsection ARC Features