From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id z3IGNsk8SWQ85jYAWB0awg (envelope-from ) for ; Wed, 26 Apr 2023 11:01:29 -0400 Received: by simark.ca (Postfix, from userid 112) id CAC321E221; Wed, 26 Apr 2023 11:01:29 -0400 (EDT) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=PKvCgl82; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A, RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 20E401E128 for ; Wed, 26 Apr 2023 11:01:26 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 2ECE93858404 for ; Wed, 26 Apr 2023 15:01:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2ECE93858404 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1682521285; bh=Z+7knCLgfkqhxbxPhwtukJGa69TBuDWlMwIicqzqvsc=; h=Date:Subject:To:Cc:References:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=PKvCgl82mK2VT2/qhxwARFAq+q+P3ySi1fzLZFjt5OmcDObs4h24/x+j0Z5BhuCxc s/KCVHJX0ZjCnXCu3Smy79US7OaWxzD/VOlKyVHFNQ5pLeX0rs4/vuwEu75irNMkp7 REOcqEj6uukodKbKJ4/TrD9TTOzK0kuBxFvKuGVs= Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-he1eur04on2079.outbound.protection.outlook.com [40.107.7.79]) by sourceware.org (Postfix) with ESMTPS id 983F53858C54 for ; Wed, 26 Apr 2023 15:01:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 983F53858C54 Received: from AS9PR05CA0252.eurprd05.prod.outlook.com (2603:10a6:20b:493::18) by AS8PR08MB9599.eurprd08.prod.outlook.com (2603:10a6:20b:619::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6340.21; Wed, 26 Apr 2023 15:00:58 +0000 Received: from AM7EUR03FT028.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:493:cafe::55) by AS9PR05CA0252.outlook.office365.com (2603:10a6:20b:493::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6340.21 via Frontend Transport; Wed, 26 Apr 2023 15:00: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 AM7EUR03FT028.mail.protection.outlook.com (100.127.140.192) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6340.22 via Frontend Transport; Wed, 26 Apr 2023 15:00:58 +0000 Received: ("Tessian outbound 945aec65ec65:v136"); Wed, 26 Apr 2023 15:00:58 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 5ef16dc9bcf47841 X-CR-MTA-TID: 64aa7808 Received: from 8639ad94f36c.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 7A91DF11-FE19-4A11-BE3A-40E4F1AF7D7B.1; Wed, 26 Apr 2023 15:00:51 +0000 Received: from EUR04-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 8639ad94f36c.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Wed, 26 Apr 2023 15:00:51 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ZaXRSJooRE05WH0qMbXELWI0hSo0YgUN0qe2bbl0zek12WWLeilBktVm0/aI+8shmrl1ifUbOu1g/uvNSDgz0K2zFcuYe6nGXEkpCu+uz/wil9VJkAvf9y7neb3C+5ABnNsZK3xPKHRX4MBRpKIAYKQs8lAGKmevOaW7zl3ArLWCcp6qKkGekbn0oA4Q2a6HsndjR/wcz8h+TdpWPCeRMKIwzSd/5aIQUEehazJ1dJXyQRHYh5rZzZ3j8IzWJvxVS1Rpuq/z5+M2SVgYT/1FsKwwquf22tPgUkC/6WqT9RDX/ty/C9OH3ABIwHX6Wt3tRRbtAy0I/uYRCoB7WDtTCQ== 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=Z+7knCLgfkqhxbxPhwtukJGa69TBuDWlMwIicqzqvsc=; b=R3DVTDuQq5DTwBH4TgZvSWSeJNvaVNpPAEIbe8lcrov3DavsGHdRJjCCP2Uhxwk4cs5v7Fs8S0EMD/W/BRrqRHrp630I7jXVywqOtEnofm/ugkddctAn7FSsqQwwAYaqprtcwEIuLer+OCA+pfa+2EqjN1fjDB+dhP2X5FbsPJgiqqkDxtaOnh0gW3H0f2TESQ7FDCgXLBUz3TpDw8afn7dluNBv20votffG0IAMdj9v2dtleaC6UzY76TqAtJW+MocKquD+MCNfqdXeO3OhFzJmDsdHm2h/zohxVNVVUF5KVBencOfBI5RP9XxBiYJ2+o1qaPFYFIv4sxzbJ+ZGnA== 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 Authentication-Results-Original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com; Received: from VI1PR08MB3919.eurprd08.prod.outlook.com (2603:10a6:803:c4::31) by PAWPR08MB10165.eurprd08.prod.outlook.com (2603:10a6:102:361::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.33; Wed, 26 Apr 2023 15:00:49 +0000 Received: from VI1PR08MB3919.eurprd08.prod.outlook.com ([fe80::61f2:6a3c:f256:8616]) by VI1PR08MB3919.eurprd08.prod.outlook.com ([fe80::61f2:6a3c:f256:8616%6]) with mapi id 15.20.6319.033; Wed, 26 Apr 2023 15:00:48 +0000 Message-ID: Date: Wed, 26 Apr 2023 16:00:44 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: [PATCH,v3 17/17] [gdb/docs] sme: Document SME registers and features Content-Language: en-US To: Eli Zaretskii Cc: gdb-patches@sourceware.org References: <20230411042658.1852730-18-luis.machado@arm.com> <20230417171945.328823-1-luis.machado@arm.com> <83ttx81dcc.fsf@gnu.org> In-Reply-To: <83ttx81dcc.fsf@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LNXP265CA0037.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:5c::25) To VI1PR08MB3919.eurprd08.prod.outlook.com (2603:10a6:803:c4::31) MIME-Version: 1.0 X-MS-TrafficTypeDiagnostic: VI1PR08MB3919:EE_|PAWPR08MB10165:EE_|AM7EUR03FT028:EE_|AS8PR08MB9599:EE_ X-MS-Office365-Filtering-Correlation-Id: 2b1aa248-8c22-4c3b-679a-08db46670b2f 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: d0Al9Ou7qGc0FgzY8BrjOVMmskMZDqoUKk3WqQ0p16V/WiugbWw3NYHw3Iitx56epn3s9vVsxuGfon8vT4LJWG5l1gBL1luqu4bhDcoQUiPBj/XwF3PDm67pDOO96cyO/2RTrXh3vEKOCRnUuFdAn1Z6f3sMo+jDbNAbgQqcZ2uR0wbQzhjM1AswzW++Fkb1bodc3BSeGlKA6UzitKuTURUIWfKFmkDW86VM+BGxAivhb8JtV5oA6nPWH8u8LUl7UdvhPrOwrHFPrk8ySgRGOseiO/KoXUnX2H7qprU/EvYy5UaYBCuifVzuxA3YRCsR8PHw/E8CFPo28HIgM+Nr0AMZ5pjvyV+uvMbpcmvQcmtEwzcxNVjQN4snWTTIP5CQSz8hIdyH2laoN0bmJnC1Rv5JlI18My+MKJB06Oysy/smhZ1yqtTkVnhj++GUTkkncKAkL3XSxvGu5wJV4Z2gn9x5WTe4+cJwZAzrUeA/RVRypqXP0KaDmzxE62qlAJc0CxvCyrIvKMf5GKN+Ja+Pa0amlkx2XMWCmClXnT/NSkCFGNeOHCdm33LW0Yprq218hYmEVkICTF3FAeC31jkrJt92+oKM5owNpaKdhFSTN9iP/94lXE624phBcJaJenL0SkVE9wuQ4h+EYhzYPD/mVA== X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VI1PR08MB3919.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(4636009)(366004)(376002)(346002)(396003)(39860400002)(136003)(451199021)(38100700002)(6512007)(53546011)(26005)(6506007)(2616005)(186003)(83380400001)(8676002)(44832011)(2906002)(5660300002)(8936002)(86362001)(41300700001)(36756003)(6666004)(478600001)(6486002)(316002)(4326008)(6916009)(66556008)(66946007)(31696002)(66476007)(31686004)(45980500001)(43740500002); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAWPR08MB10165 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: AM7EUR03FT028.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 4bb7d4cb-d02b-4033-4912-08db466704c7 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: x4UmcxjdkUR8DRRGQ+ozg6NXdDBXcApe1f0bHEf6Lqltp6yjWHgZNcXOnZz4H9T9ToODVGcbVwucFOPOHVbrOtvJThYpw3cdjKR+sxhSXm42CAVR0iwBmDwOmx8bWxZE+4bu1zis6HQwV0L6bZhw/MPD55e9rJX8hnDkZ25pDIS62Iw1W8JKGxoD/ichZ9vQWsHxfB/Wz1HFSo4St+S1gHdeIY38tTyswZCV1rQR2R/sOxyE0s9zh853UqMaRw25vOZyKHlA5CVcKD7ZKPWwsXwjwJT504AykqElQqN9cqyKTRvFTqybpSWiJlxkYetEZDxekix6WG1TwdakeRb3xrwHKVHqW2urBiKWngk/I2rylxi7RbRP7MDIIoE3RYJgBKxoUSzs3RkhQvLxTi3rn50qUJbKzGteX3UE/jb3h8FSJVUhX9MDyLg7dJB4/WboZjD2Z6xQT4l/sQNRtokDBeZx/Ql6bdiW6EzQGSjR3EJkc7EobJOW6E1XwsBYgsTsxHleGWGZMt97EZ1skvzMrX1EehepuL35YQ5UfE2P11YHUvYs23zH7y8nZjQan2OLYJTaakW04WraXXEB25sjoLKD8F7DcCZBYX5U9XpoXdV6UMkRrhFqrAyOXpF4luGf3uXrcIOvngELaC4C8Bf8LGSvDWiWUYQ0PCHW+0LWWPxjQ+iZHwyma9n5qVikmal0l4wTR8vu9oVVCDUvdeKob3sTmkVrj5f2yJ5HyOVzgL2tRnxRozisEQa/C2GVnZZqmgjnt2QOJ7cRXH9z6w15zA== 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)(396003)(346002)(376002)(136003)(39860400002)(451199021)(36840700001)(40470700004)(46966006)(36860700001)(31686004)(83380400001)(2906002)(47076005)(44832011)(82310400005)(2616005)(82740400003)(8676002)(6862004)(8936002)(5660300002)(356005)(53546011)(26005)(81166007)(186003)(40480700001)(34020700004)(6506007)(6512007)(336012)(41300700001)(40460700003)(4326008)(31696002)(86362001)(6486002)(70586007)(70206006)(6666004)(478600001)(36756003)(316002)(43740500002); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Apr 2023 15:00:58.5507 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2b1aa248-8c22-4c3b-679a-08db46670b2f 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: AM7EUR03FT028.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB9599 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: , From: Luis Machado via Gdb-patches Reply-To: Luis Machado Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 4/22/23 10:21, Eli Zaretskii wrote: >> From: Luis Machado >> Date: Mon, 17 Apr 2023 18:19:45 +0100 >> >> Provide documentation for the SME feature and other information that >> should be useful for users that need to debug a SME-capable target. >> --- >> gdb/NEWS | 11 ++ >> gdb/doc/gdb.texinfo | 249 ++++++++++++++++++++++++++++++++++++++++++++ >> 2 files changed, 260 insertions(+) > > Thanks. > >> diff --git a/gdb/NEWS b/gdb/NEWS >> index 54b5da21245..e3ce7d7e881 100644 >> --- a/gdb/NEWS >> +++ b/gdb/NEWS >> @@ -3,6 +3,17 @@ >> >> *** Changes since GDB 13 >> >> +* GDB now supports the AArch64 Scalable Matrix Extension (SME), which includes >> + a new matrix register named ZA, a new thread register TPIDR2 and a new vector >> + length register SVG (streaming vector granule). GDB also supports tracking >> + ZA state across signal frames. >> + >> + Some features are still under development or are dependent on ABI specs that >> + are still in alpha stage. For example, manual function calls with ZA state >> + don't have any special handling, and tracking of SVG changes based on >> + DWARF information is still not implemented, but there are plans to do so in >> + the future. >> + >> * The AArch64 'org.gnu.gdb.aarch64.pauth' Pointer Authentication feature string >> has been deprecated in favor of the 'org.gnu.gdb.aarch64.pauth_v2' feature >> string. > > This part is OK. > >> +For SVE, the following definitions are used throughout @value{GDBN}'s source >> +code and in this document: >> + >> +@itemize >> + >> +@item >> +@anchor{VL} >> +@cindex VL >> +@code{VL}: The vector length, in bytes. It defines the size of each @code{Z} >> +register. >> + >> +@item >> +@anchor{VQ} >> +@cindex VQ >> +@code{VQ}: The number of 128 bit units in @code{VL}. This is mostly used >> +internally by @value{GDBN} and the Linux Kernel. >> + >> +@item >> +@anchor{VG} >> +@cindex VG >> +@code{VG}: The number of 64 bit units in @code{VL}. This is mostly used >> +internally by @value{GDBN} and the Linux Kernel. > > I thought we agreed to use @var{vl}, @var{vq}, etc., instead of > @code{VL} etc.? These are meta-syntactic parameters, they stand for > something else, not literally for themselves, so @var is more > appropriate. Ok. That wasn't completely clear to me. I've made the change now. > > Also, you place @cindex between @item and the text of the @item -- did > you verify that typing "i VQ" in an Info reader goes to the beginning > of the item's line? I think @cindex should be before @item. You're right. Fixed and verified now. > >> +Similarly to SVE, where the size of each @code{Z} register is directly related >> +to the vector length (@code{VL} for short), the @acronym{SME} @code{ZA} matrix >> +register's size is directly related to the streaming vector length > > Elsewhere you use @code{za}, lower-case, for the register. Please be > consistent in the capitalization of the register names. > All the uses of za should now be lower-case. >> +(@code{SVL} for short). @xref{VL} @xref{SVL} > ^^ > Two spaces there. > Fixed. >> +@item >> +@anchor{SVL} >> +@cindex SVL >> +@code{SVL}: The streaming vector length, in bytes. It defines the size of each >> +dimension of the 2-dimensional square @code{ZA} matrix. The total size of >> +@code{ZA} is therefore @code{@var{SVL}x@var{SVL}}. >> + >> +When streaming mode is enabled, it defines the size of the @acronym{SVE} >> +registers as well. >> + >> +@item >> +@anchor{SVQ} >> +@cindex SVQ >> +@code{SVQ}: The number of 128 bit units in @code{SVL}. This is mostly used >> +internally by @value{GDBN} and the Linux Kernel. >> + >> +@item >> +@anchor{SVG} >> +@cindex SVG >> +@code{SVG}: The number of 64 bit units in @code{SVL}. This is mostly used >> +internally by @value{GDBN} and the Linux Kernel. > > Likewise here: I thought we agreed on using @var{svl} etc., not > @code{SVL}. > Fixed now. >> +The @code{za} register is a 2-dimensional square @code{@var{SVL}x@var{SVL}} > > And here you actually use @var (which is correct), but with an > upper-case argument, which is sub-optimal. The argument of @var > should be in lower-case. > Fixed. >> +@item >> +@samp{za} is a register represented by a vector of @code{SVL} x @code{SVL} > ^^^^^^^^^^^^^^^^^^^^^^^ > This should use @var, not @code. Also, I'd remove the whitespace > around "x". Fixed. But I used spaces between "x" and the two @var entries because it gets rendered as a single block of characters like svlxsvl. Using @math{x} doesn't look too nice. Suggestions? > > Reviewed-By: Eli Zaretskii