From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 0YDsOkqh92iJqAEAWB0awg (envelope-from ) for ; Tue, 21 Oct 2025 11:05:46 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=SEclgxZ/; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=SEclgxZ/; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id EC3A91E04C; Tue, 21 Oct 2025 11:05:46 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-2.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED autolearn=ham autolearn_force=no version=4.0.1 Received: from server2.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 ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id CB6AA1E04C for ; Tue, 21 Oct 2025 11:05:45 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 81DBF3858410 for ; Tue, 21 Oct 2025 15:05:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 81DBF3858410 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=SEclgxZ/; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=SEclgxZ/ Received: from AM0PR83CU005.outbound.protection.outlook.com (mail-westeuropeazon11010023.outbound.protection.outlook.com [52.101.69.23]) by sourceware.org (Postfix) with ESMTPS id A4CB43858C56 for ; Tue, 21 Oct 2025 15:03:58 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A4CB43858C56 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 A4CB43858C56 Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=52.101.69.23 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1761059038; cv=pass; b=DFidIXTzKA9z5pHXR0BiYwZ1/49jaidMrHvlZgDsSCxx2lCFiaUWB4bwzCY4rIIM3/fs2rrIDpgrHGMTJaRl3bVLuDtzGdCoyJvLK1cKQKV9esQryrib2Ns+HHR9Ft0ZnhKooSDQTyfe/UJaFHilFO5FjIMwYMhWinSNxqAh45s= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1761059038; c=relaxed/simple; bh=xPkqODl4eB9qjqSawM/ON2snZNvwEVaNhU/3jjyR/UQ=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=kH1iui+ZSbmoQBmb3fltmQaAHauteZPP3W3j4HjTqltdctWDsGyqvDi29ylCP653Cp/XJhN0wUntIli39jPqmWXsKPDvioi6jG8ZNz/Ng9IrC7SRUWa5eOUzyh3dpew0Yp8ba5QeQOwnxvML7mrPLeWoEF5r2s2JkPT90dJRDs4= ARC-Authentication-Results: i=3; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A4CB43858C56 ARC-Seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=UhAxkqs5BPZBnXAh6SZNO/Kx227BSlLCIdwxvCgUALKD8nVy4d3yodoZfcMzYZm5i62l6aAaci2ZbRCESQyvvRrkIXXMmVYSvD7XilcV5k274jKkOAX9HHWBRgBINTD4RVDOu8bThq5M86vLWmKkxZjgDxB8VuYoA3+6xfkakT19hqd5MesPSBMpVOvz31F8cI1bMTuLtuY1KQ4B52kYsBg//EaOCnfUzsraQL2k7WMuApN1S8f9c9G69Qod6zVfXd8JOWZM3oVuyLxwjZ9KBOXvae7Mu1os7zh9Fe0OEpcGCx4+sdpu+CrayIZ7YzbFpqeUtCwtB8R1wqN0+3nB6A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=fG4yytIrWfEnlVTi/gzRoqcG0f6iqLS+oPC6Q1WNyJw=; b=KbNbGFuSqzVtsoJB1I4TYZTppm06wz5cuk7QT/HSkfv5Ep5uuZqw+mLfJ8pm4umaJwD2f8n4liLQt7OGFtEHTgHnybuAvXvDsGSdlZpk7YnXP1X7E3EM1MEiVwDGipvDL+kQ0J46QGatxF1yaWtxqFDHKOa6xGg44Csb9wNS0JoReYrTAn9s2fCpW+3fgOavnLkNwMP7qz+yA26YhBHnNUUZnTdBqH/iOkbvX6NnXc17BcbwUxE+CbGVzz6FlhJ5HDiNgy18dF+wx1/l1Kjkaq0lBU+Bg2bHmK242CJAcLZW6XOEoOg27jxon2H786DW75Iki2nCbkXYWnjuJQ60QQ== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 4.158.2.129) 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=arm.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=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fG4yytIrWfEnlVTi/gzRoqcG0f6iqLS+oPC6Q1WNyJw=; b=SEclgxZ/6xnUx5IqtAuCKTF/ZpOJPy5nMp2/bVkSrk1hX5aKN19vFtyAnGjFx3F5NaTVrClnT+gfxdoVhCh17ZyLMGh5Ciq9vdrWTu63Yby5LTHyxRi835NGeMuidPN8/2uXI0yxjDUSbI+PVYSSidc9i7CugtauvdHLPhJFdYA= Received: from AS8PR04CA0049.eurprd04.prod.outlook.com (2603:10a6:20b:312::24) by GVXPR08MB11535.eurprd08.prod.outlook.com (2603:10a6:150:2c1::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9253.12; Tue, 21 Oct 2025 15:03:29 +0000 Received: from AM2PEPF0001C717.eurprd05.prod.outlook.com (2603:10a6:20b:312:cafe::ef) by AS8PR04CA0049.outlook.office365.com (2603:10a6:20b:312::24) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9228.16 via Frontend Transport; Tue, 21 Oct 2025 15:03:29 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 4.158.2.129) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=arm.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 4.158.2.129 as permitted sender) receiver=protection.outlook.com; client-ip=4.158.2.129; helo=outbound-uk1.az.dlp.m.darktrace.com; pr=C Received: from outbound-uk1.az.dlp.m.darktrace.com (4.158.2.129) by AM2PEPF0001C717.mail.protection.outlook.com (10.167.16.187) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9253.7 via Frontend Transport; Tue, 21 Oct 2025 15:03:29 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=xA8WCviw0mK3X5PUpA0bxRIXWWq1VL2IhGlWPtzhvGSEz3dm1jErzDz9HIJSaoGywO6sXH+3kl4EZ3eh3EHUYOE+wy6xg1Z6ic35nUBmpkhBwq8DNlgKnTx5LI4cTk/t5tK3I+3olVTwUpjW9ARqLVOsmlfGnC203xLN2r3UmBWPyFLuxDr7y28d3fjbfcI3s+PyItp+kEBwpo2dUMXTWtEglE8sBjzfDL2HINdK2hZKzp5G5uRneDqcXvcwPdBIfk2HA/hcrgyVfXQIwLnQdn7rehPRs6Wl5bumYIBbgNUhw7OZW96knZFQzbs9GRRTlqoosf4zHrOtCWL9JpvzLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=fG4yytIrWfEnlVTi/gzRoqcG0f6iqLS+oPC6Q1WNyJw=; b=qh4iGZHstL8ohQIaZc/GPlA8okqrsqlJc6PAWvkNG4IUPQ/9p9msWM4pONH9WiDA29aHji/yJxGS0RPK3wxcNhtBSyajA0LWBj6eWTqlkbtle7t6DeHVGyGiN2B2AkMFqqXYAjOy4nROPJLFAxHnvV2ZZ+vVADpQooOfeab8MnnKjgtgg/TzQZ8xyU/MPF0rJHPAxvBahVjr2IdDfA8v8H4kNnMWB/GYeACEA/kiE18Xtu7EcNTmlAHDsO6BQEDUcaTGTrXI1Sq5hUkRECJKIPPxERXEwpS3X441Yczsvi8vqcmFvJvVe/fdi5xiadqDVE9F5rrrgZ0fQ2nDhIOuXw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 172.205.89.229) 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=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fG4yytIrWfEnlVTi/gzRoqcG0f6iqLS+oPC6Q1WNyJw=; b=SEclgxZ/6xnUx5IqtAuCKTF/ZpOJPy5nMp2/bVkSrk1hX5aKN19vFtyAnGjFx3F5NaTVrClnT+gfxdoVhCh17ZyLMGh5Ciq9vdrWTu63Yby5LTHyxRi835NGeMuidPN8/2uXI0yxjDUSbI+PVYSSidc9i7CugtauvdHLPhJFdYA= Received: from DU7PR01CA0005.eurprd01.prod.exchangelabs.com (2603:10a6:10:50f::28) by AS8PR08MB9865.eurprd08.prod.outlook.com (2603:10a6:20b:5a9::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9228.16; Tue, 21 Oct 2025 15:02:56 +0000 Received: from DU2PEPF0001E9C4.eurprd03.prod.outlook.com (2603:10a6:10:50f:cafe::3c) by DU7PR01CA0005.outlook.office365.com (2603:10a6:10:50f::28) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9228.17 via Frontend Transport; Tue, 21 Oct 2025 15:04:00 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 172.205.89.229) 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 172.205.89.229 as permitted sender) receiver=protection.outlook.com; client-ip=172.205.89.229; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (172.205.89.229) by DU2PEPF0001E9C4.mail.protection.outlook.com (10.167.8.73) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9253.7 via Frontend Transport; Tue, 21 Oct 2025 15:02:56 +0000 Received: from AZ-NEU-EX05.Arm.com (10.240.25.133) by AZ-NEU-EX03.Arm.com (10.240.25.137) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.2.2562.27; Tue, 21 Oct 2025 15:02:56 +0000 Received: from AZ-NEU-EX03.Arm.com (10.240.25.137) by AZ-NEU-EX05.Arm.com (10.240.25.133) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Tue, 21 Oct 2025 15:02:55 +0000 Received: from D2G2X7XGD1.arm.com (10.57.5.208) by mail.arm.com (10.240.25.137) with Microsoft SMTP Server id 15.2.2562.27 via Frontend Transport; Tue, 21 Oct 2025 15:02:55 +0000 From: To: CC: , , Ezra Sitorus Subject: [PATCH v3 1/6] gdb/aarch64: Enable FPMR for AArch64 in gdb on Linux Date: Tue, 21 Oct 2025 16:02:55 +0100 Message-ID: <20251021150300.59860-2-Ezra.Sitorus@arm.com> X-Mailer: git-send-email 2.51.1 In-Reply-To: <20251021150300.59860-1-Ezra.Sitorus@arm.com> References: <20251021150300.59860-1-Ezra.Sitorus@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DU2PEPF0001E9C4:EE_|AS8PR08MB9865:EE_|AM2PEPF0001C717:EE_|GVXPR08MB11535:EE_ X-MS-Office365-Filtering-Correlation-Id: ab2dc2c7-875d-4abe-288b-08de10b2feb0 x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; ARA:13230040|82310400026|1800799024|36860700013|376014; X-Microsoft-Antispam-Message-Info-Original: =?us-ascii?Q?mCiutPRG13CP+irGDsA75ly8JL3GEKDPKvHnu2wUscTDkzjz+Rof3dOe0guO?= =?us-ascii?Q?dFD6lSmSUIW8SWI3A5TDu8TCFU0TLMqmGyL3vZy+s+UUarht4ASUziYQ+yrM?= =?us-ascii?Q?NSZ+WckS71yDLQon1gExQM8y8FqmtzxWy9MZMKra574MvbynK44HrSH7rMPb?= =?us-ascii?Q?zyFKNTROzou2zjR0kJe56CFK5xFYcgDwjxdlZ+n31VBrGQFTM3fmCZA4S/2o?= =?us-ascii?Q?OZj37Au1FVX43MLW2fvhPs2oA/PsbRSP8C8pl6HiuslQrsb92HSXxUa4+Bu8?= =?us-ascii?Q?ECnt+mvBKSDDZPpEdGPj3Xa1nArDrHP8r63tjg5I33GVnPxuGXRFIUS8Wo53?= =?us-ascii?Q?4uDg/FhGJjl7BBS2c99QHPthZ5qT6BVD4gtJSP3qPUjxWGoeGjZimO3AcQix?= =?us-ascii?Q?FUOZIRMBO7ze2cMFs2vPljOzblld/SYhm1a9CVOsjL2xMEna/a6J9IjZ/JVR?= =?us-ascii?Q?d3Dzt4jalRRhxbOsz7E9DLaxTVYGCV5WQe6+ru27AdcsdH/bwzUKFqu8wORu?= =?us-ascii?Q?1iI5QA9oFCHw6doLoFWjUvwLZL3drdkHELN61xxG5b5HF2hCV2naxlIqEuu8?= =?us-ascii?Q?KT+REUTmIp6qiPwgMVPZtibYeP1xOdwd8qIFx0mmc7OW1JhWmxemjNJ0Co0k?= =?us-ascii?Q?KsOqzTVpFn9xiNJSuBCbjY795ksqDEwGUMSapZngUm/FQqc6KBA5Q4yP7tVf?= =?us-ascii?Q?m+eK54vDDGOCyktkf1yOaLx5Z+P92flgfVU7LYWkNeZH8ECE+H2G3MkDV3Dc?= =?us-ascii?Q?E+7dGW+EZyDY647rVmGxo9R9sAQgB+pRdzlB0pX8JiOJN+RzwG5pARnBvd3f?= =?us-ascii?Q?sc2kI2FZATkwDHZ/H5ehYlUcJyIhW/HJ9RxrLFmmONsZoitIQZDqVYjzIuXq?= =?us-ascii?Q?+lckBaMElqNZ15AWOoaaRS12R2xbmb4j3fRNjcfau/KNzKwn99hyHZqhgW//?= =?us-ascii?Q?m012TLJ+/YA+kKqudU312usxqMdBOIjgKE85xmCxix1ulyavIHVpdNq61ALD?= =?us-ascii?Q?wttwfLOmz+8qKuQQkERF6L7Dif2L9DaagHPj2vr3h7YT4UV/NLRZfo1P6Mc9?= =?us-ascii?Q?Tll7yh6hqlEms3MR2EoeuKMUcJVz8bBhc2wB0OTF7oFVg5FP1SASXCQkxLKJ?= =?us-ascii?Q?i3eqeXzQ0G0kOW1MAwRiVXbW1Ny8WSsHLTyFwtmiQPX86wJhmGz2QkRjA1I5?= =?us-ascii?Q?wSpUEscedMH1RQC32DuEAOlaNH8IcZR1XyKN+xZHEUAGyIevFeb3aSELu4+c?= =?us-ascii?Q?9atCtiCo6JE/pgD9bwM9okSnoOrJC6l/8jhYAbeOZMarp09ZX7XUzzXDqMlY?= =?us-ascii?Q?j6HadjyImr+GhyH6fOwS8XyH2nYV/7g09EthvLW4DajDmye6x8nSclCvNtAD?= =?us-ascii?Q?WDkmZZspOTy/vWrEbFAwtjQl59IuItqRb+CkQMJHz6Zmct13m3tb/6HVFCLH?= =?us-ascii?Q?07+6dba5QtpcVWRSjCdKbSsmm/i9XgdgsylzjoppENqboxrhFQ+pJnVY6b4y?= =?us-ascii?Q?gGquIPLWrFYsKdNEDasqhPvJI3L4RboTu9RkRb9A6udMM2l7XOiexUjwA3Vl?= =?us-ascii?Q?ugIeD9sgsLfwlPkLUK0=3D?= X-Forefront-Antispam-Report-Untrusted: CIP:172.205.89.229; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(82310400026)(1800799024)(36860700013)(376014); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR08MB9865 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM2PEPF0001C717.eurprd05.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 8bcf895d-2810-4b79-cb2e-08de10b2eafc X-Microsoft-Antispam: BCL:0; ARA:13230040|376014|82310400026|1800799024|36860700013|35042699022|14060799003; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?SKONXLI+zidXYSezHTKN56PcCJQILADD6LCNRpSIGUz0x4j9sI9jYsKI7fni?= =?us-ascii?Q?6uHlmYaNIj8Myp85HMnkr9/ld7iDz/WlHfm7Nh8H52GTMObSvFu+7q/3mOL+?= =?us-ascii?Q?ooriHCb7pIiAmtYZBmTBIGPVujsgLJGzNYskDsuuroihrfBof0/FaRG0BzZP?= =?us-ascii?Q?oWGuNmjCxZMkbF1KG7VCdvF9ArUQhN1SYzjT7x+SjLHWSoD12nin24uzfU95?= =?us-ascii?Q?edU4d2FqTt2qb7A8B+uLuFWhWZdLbz0RxfQ8P8KLnhUkCdHKPGC4UWLTfktw?= =?us-ascii?Q?Msvo2ACKsvBYmK4N0c7z0SnKhA8AftuUbi9CQscnSYBO1Ioa+RCznzTGO2Fx?= =?us-ascii?Q?n2bzLEomxwyt+rQKnEbL12aADtCwmxj5qLPAucsArYAmSSrHxRXGrlL6KVFo?= =?us-ascii?Q?yOiDm1l7KNeVFATsb+nPvzUvNigiSEK3UgBnEnR6Zh0Be7xC/ceK74yW8dZq?= =?us-ascii?Q?pAHT3qdDENe+xF5U4jnQ92ge9vH88/oc/bjkXt2JUxLnyjrqPzNetNvpqMcG?= =?us-ascii?Q?1L8vQYdO3tDvlcaTUzSbBwxsn4rFwI1bJ21l4ik+oBEY8EL4D77BpvQlCSxS?= =?us-ascii?Q?hmDTyyR7m0IIRI5xVaZpguVwwcuJK6cNisJGOsYVGzhjc8HO5m+WKScCsPdC?= =?us-ascii?Q?wrhomMXPgCg+/7U3fbUsEfCj+qvmejISL4/bUxpRon2uptjpeNCtfAShkX1K?= =?us-ascii?Q?54Z2ljR3hmaGPP4th2Myo08hvMXb6VigU0Ydz+rdWT4yFAw62+nfq+z5N/iD?= =?us-ascii?Q?rYGYkLeNca/1+Sbbj+7u8TQGIdoUksMi3YOW68DGUO+73VuxxSmKkqUhgZI+?= =?us-ascii?Q?97N3Ffjdi92ziPjs9EHleak4IdzgaWFZsETLAZsDbt/y4ZhVDSjsaziv+Qdn?= =?us-ascii?Q?CqOECQh1S1+dZpDUc/kp7tC4sEhZ+JmoB+osLqvoxY8IX5pJaslut2oiDsJ0?= =?us-ascii?Q?EigoUO7pwvoIzNX/3STN0sol37G4IzZ4fy9JLJybgPadpd9OGstvc5PMO4xk?= =?us-ascii?Q?lBmaThISogU1zJELLIG+8uRrWcz3V0jKZqKc5r/to4X9J+rOA7YZjKfShHz4?= =?us-ascii?Q?kpCGb8HGtYoU+1/WOJCFQU91MizM0pkdf6Yc9jZAyTwKgQ0/HWLSCjSLaxl5?= =?us-ascii?Q?OUU2jFGwNrpM1eCzMW01/t52v/bOSDrtqumJ34a019Ktq+WiLlPpNeraEGuO?= =?us-ascii?Q?giDwkCcPdM866YGEcAQTo5eL9apjeYmxxwQgoGrROFsq2IHws0M8lph/BCkQ?= =?us-ascii?Q?4eYe+OXYzGCGQJYSGxllb7cQvuvz3sm7MnHnqFotvK8BAf2xE95PYUq8wnID?= =?us-ascii?Q?M2eytNcQlqwqI22OqFcDkRn7cRwWIg3lCCVVTU/akknVgHPf23pF9e9HdaDB?= =?us-ascii?Q?HxQCPfpKhyAb63PDrGJDYOCwaStDBFwEpP6qIHDxuvoRD7raoqpfGeb1fUdA?= =?us-ascii?Q?lYcy9yXaEh2XMnAEKrprRMfYgF6mU1s/qh7WVWQ870fMR1zBEObLhKc/Mn8m?= =?us-ascii?Q?kTn0UsvXTWxw8PTHvJ4B3fEWoUQ6UYZ3jWY6N5uszP4twOhPdpbrUnq9M4JQ?= =?us-ascii?Q?ImbQXB4NQWbyrdSnKJ4=3D?= X-Forefront-Antispam-Report: CIP:4.158.2.129; CTRY:GB; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:outbound-uk1.az.dlp.m.darktrace.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(376014)(82310400026)(1800799024)(36860700013)(35042699022)(14060799003); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Oct 2025 15:03:29.5278 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ab2dc2c7-875d-4abe-288b-08de10b2feb0 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[4.158.2.129]; Helo=[outbound-uk1.az.dlp.m.darktrace.com] X-MS-Exchange-CrossTenant-AuthSource: AM2PEPF0001C717.eurprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: GVXPR08MB11535 X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org From: Ezra Sitorus The Floating Point Mode Register controls the behaviours of FP8 instructions. This patch add FPMR to GDB if it is enabled on the target. --- Changes from v1->v2: * Addressed comments/whitespace/formatting issues. * gdb/arch/aarch64.h: operator() takes fpmr into account now. * Defined HWCAP2_FPMR in gdb/arch/aarch64.h Changes from v2-v3: * Formatting fixes. * Moved initialisation of fpmr variables closer to where they are used. Ezra gdb/aarch64-linux-nat.c | 57 +++++++++++++++++++++++++++++++++++ gdb/aarch64-linux-tdep.c | 1 + gdb/aarch64-tdep.c | 15 +++++++++ gdb/aarch64-tdep.h | 9 ++++++ gdb/arch/aarch64.c | 4 +++ gdb/arch/aarch64.h | 12 +++++++- gdb/features/Makefile | 1 + gdb/features/aarch64-fpmr.c | 44 +++++++++++++++++++++++++++ gdb/features/aarch64-fpmr.xml | 57 +++++++++++++++++++++++++++++++++++ 9 files changed, 199 insertions(+), 1 deletion(-) create mode 100644 gdb/features/aarch64-fpmr.c create mode 100644 gdb/features/aarch64-fpmr.xml diff --git a/gdb/aarch64-linux-nat.c b/gdb/aarch64-linux-nat.c index 89ecedda57d..503a41c973d 100644 --- a/gdb/aarch64-linux-nat.c +++ b/gdb/aarch64-linux-nat.c @@ -604,6 +604,48 @@ store_gcsregs_to_thread (regcache *regcache) perror_with_name (_("Unable to store GCS registers")); } +/* Fill GDB's REGCACHE with the FPMR register set content from the + thread associated with REGCACHE. */ + +static void +fetch_fpmr_from_thread (struct regcache *regcache) +{ + aarch64_gdbarch_tdep *tdep + = gdbarch_tdep (regcache->arch ()); + + int tid = regcache->ptid ().lwp (); + + struct iovec iov; + uint64_t val; + iov.iov_base = &val; + iov.iov_len = sizeof (val); + + if (ptrace (PTRACE_GETREGSET, tid, NT_ARM_FPMR, &iov) < 0) + perror_with_name (_("Unable to fetch FPMR register set")); + regcache->raw_supply (tdep->fpmr_regnum, &val); +} + +/* Store the NT_ARM_FPMR register set contents from GDB's REGCACHE to the + thread associated with REGCACHE. */ + +static void +store_fpmr_to_thread (struct regcache *regcache) +{ + aarch64_gdbarch_tdep *tdep + = gdbarch_tdep (regcache->arch ()); + + int tid = regcache->ptid ().lwp (); + + struct iovec iov; + uint64_t val; + iov.iov_base = &val; + iov.iov_len = sizeof (val); + + regcache->raw_collect (tdep->fpmr_regnum, (char *) &val); + if (ptrace (PTRACE_SETREGSET, tid, NT_ARM_FPMR, &iov) < 0) + perror_with_name (_("Unable to store FPMR register set")); +} + /* The AArch64 version of the "fetch_registers" target_ops method. Fetch REGNO from the target and place the result into REGCACHE. */ @@ -642,6 +684,9 @@ aarch64_fetch_registers (struct regcache *regcache, int regno) if (tdep->has_gcs_linux ()) fetch_gcsregs_from_thread (regcache); + + if (tdep->has_fpmr ()) + fetch_fpmr_from_thread (regcache); } /* General purpose register? */ else if (regno < AARCH64_V0_REGNUM) @@ -679,6 +724,9 @@ aarch64_fetch_registers (struct regcache *regcache, int regno) && (regno == tdep->gcs_reg_base || regno == tdep->gcs_linux_reg_base || regno == tdep->gcs_linux_reg_base + 1)) fetch_gcsregs_from_thread (regcache); + /* FPMR? */ + else if (tdep->has_fpmr () && (regno == tdep->fpmr_regnum)) + fetch_fpmr_from_thread (regcache); } /* A version of the "fetch_registers" target_ops method used when running @@ -753,6 +801,9 @@ aarch64_store_registers (struct regcache *regcache, int regno) if (tdep->has_gcs_linux ()) store_gcsregs_to_thread (regcache); + + if (tdep->has_fpmr ()) + store_fpmr_to_thread (regcache); } /* General purpose register? */ else if (regno < AARCH64_V0_REGNUM) @@ -784,6 +835,9 @@ aarch64_store_registers (struct regcache *regcache, int regno) && (regno == tdep->gcs_reg_base || regno == tdep->gcs_linux_reg_base || regno == tdep->gcs_linux_reg_base + 1)) store_gcsregs_to_thread (regcache); + /* FPMR? */ + else if (tdep->has_fpmr () && regno == tdep->fpmr_regnum) + store_fpmr_to_thread (regcache); /* PAuth registers are read-only. */ } @@ -969,6 +1023,9 @@ aarch64_linux_nat_target::read_description () if ((hwcap2 & HWCAP2_SME2) || (hwcap2 & HWCAP2_SME2P1)) features.sme2 = supports_zt_registers (tid); + /* Check for FPMR. */ + features.fpmr = hwcap2 & HWCAP2_FPMR; + return aarch64_read_description (features); } diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c index 048be4f3532..10b44d978af 100644 --- a/gdb/aarch64-linux-tdep.c +++ b/gdb/aarch64-linux-tdep.c @@ -1712,6 +1712,7 @@ aarch64_linux_core_read_description (struct gdbarch *gdbarch, features.pauth = hwcap & AARCH64_HWCAP_PACA; features.gcs = features.gcs_linux = hwcap & HWCAP_GCS; features.mte = hwcap2 & HWCAP2_MTE; + features.fpmr = hwcap2 & HWCAP2_FPMR; /* Handle the TLS section. */ asection *tls = bfd_get_section_by_name (abfd, ".reg-aarch-tls"); diff --git a/gdb/aarch64-tdep.c b/gdb/aarch64-tdep.c index 500ac77d75a..969554ed571 100644 --- a/gdb/aarch64-tdep.c +++ b/gdb/aarch64-tdep.c @@ -4140,6 +4140,10 @@ aarch64_features_from_target_desc (const struct target_desc *tdesc) features.gcs_linux = (tdesc_find_feature (tdesc, "org.gnu.gdb.aarch64.gcs.linux") != nullptr); + /* Check for FPMR feature. */ + features.fpmr = (tdesc_find_feature (tdesc, "org.gnu.gdb.aarch64.fpmr") + != nullptr); + return features; } @@ -4550,6 +4554,16 @@ aarch64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) num_pseudo_regs += 32; /* add the Bn scalar register pseudos */ } + int fpmr_regnum = -1; + const struct tdesc_feature *feature_fpmr + = tdesc_find_feature (tdesc, "org.gnu.gdb.aarch64.fpmr"); + if (feature_fpmr != nullptr) + { + fpmr_regnum = num_regs++; + valid_p &= tdesc_numbered_register (feature_fpmr, tdesc_data.get (), + fpmr_regnum, "fpmr"); + } + int first_sme_regnum = -1; int first_sme2_regnum = -1; int first_sme_pseudo_regnum = -1; @@ -4749,6 +4763,7 @@ aarch64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) tdep->tls_register_count = tls_register_count; tdep->gcs_reg_base = first_gcs_regnum; tdep->gcs_linux_reg_base = first_gcs_linux_regnum; + tdep->fpmr_regnum = fpmr_regnum; /* Set the SME register set details. The pseudo-registers will be adjusted later. */ diff --git a/gdb/aarch64-tdep.h b/gdb/aarch64-tdep.h index 99e7d26ce4a..9acd29b2d88 100644 --- a/gdb/aarch64-tdep.h +++ b/gdb/aarch64-tdep.h @@ -207,6 +207,15 @@ struct aarch64_gdbarch_tdep : gdbarch_tdep_base { return gcs_linux_reg_base != -1; } + + /* First FPMR register. This is -1 if FPMR is not supported. */ + int fpmr_regnum = -1; + + bool + has_fpmr () const + { + return fpmr_regnum != -1; + } }; const target_desc *aarch64_read_description (const aarch64_features &features); diff --git a/gdb/arch/aarch64.c b/gdb/arch/aarch64.c index dff2bc16003..622138f43b5 100644 --- a/gdb/arch/aarch64.c +++ b/gdb/arch/aarch64.c @@ -20,6 +20,7 @@ #include "../features/aarch64-core.c" #include "../features/aarch64-fpu.c" +#include "../features/aarch64-fpmr.c" #include "../features/aarch64-sve.c" #include "../features/aarch64-pauth.c" #include "../features/aarch64-mte.c" @@ -73,6 +74,9 @@ aarch64_create_target_description (const aarch64_features &features) if (features.gcs_linux) regnum = create_feature_aarch64_gcs_linux (tdesc.get (), regnum); + if (features.fpmr) + regnum = create_feature_aarch64_fpmr (tdesc.get (), regnum); + return tdesc.release (); } diff --git a/gdb/arch/aarch64.h b/gdb/arch/aarch64.h index 679d845df74..8f4ba9c9e0c 100644 --- a/gdb/arch/aarch64.h +++ b/gdb/arch/aarch64.h @@ -34,6 +34,7 @@ struct aarch64_features uint64_t vq = 0; bool pauth = false; bool mte = false; + bool fpmr = false; /* A positive TLS value indicates the number of TLS registers available. */ uint8_t tls = 0; @@ -68,7 +69,8 @@ inline bool operator==(const aarch64_features &lhs, const aarch64_features &rhs) && lhs.svq == rhs.svq && lhs.sme2 == rhs.sme2 && lhs.gcs == rhs.gcs - && lhs.gcs_linux == rhs.gcs_linux; + && lhs.gcs_linux == rhs.gcs_linux + && lhs.fpmr == rhs.fpmr; } namespace std @@ -94,6 +96,9 @@ namespace std /* SME2 feature. */ h = h << 1 | features.sme2; + + /* FPMR feature. */ + h = h << 1 | features.fpmr; return h; } }; @@ -238,4 +243,9 @@ enum aarch64_regnum /* Size of the SME2 ZT0 register in bytes. */ #define AARCH64_SME2_ZT0_SIZE 64 +/* Feature check for Floating Point Mode Register. */ +#ifndef HWCAP2_FPMR +#define HWCAP2_FPMR (1ULL << 48) +#endif /* HWCAP2_FPMR */ + #endif /* GDB_ARCH_AARCH64_H */ diff --git a/gdb/features/Makefile b/gdb/features/Makefile index d17c349b6cf..ed1b8bf119c 100644 --- a/gdb/features/Makefile +++ b/gdb/features/Makefile @@ -201,6 +201,7 @@ $(outdir)/%.dat: %.xml number-regs.xsl sort-regs.xsl gdbserver-regs.xsl # For targets with feature based target descriptions, # the set of xml files we'll generate .c files for GDB from. FEATURE_XMLFILES = aarch64-core.xml \ + aarch64-fpmr.xml \ aarch64-fpu.xml \ aarch64-pauth.xml \ aarch64-mte.xml \ diff --git a/gdb/features/aarch64-fpmr.c b/gdb/features/aarch64-fpmr.c new file mode 100644 index 00000000000..a372b12530b --- /dev/null +++ b/gdb/features/aarch64-fpmr.c @@ -0,0 +1,44 @@ +/* THIS FILE IS GENERATED. -*- buffer-read-only: t -*- vi:set ro: + Original: aarch64-fpmr.xml */ + +#include "gdbsupport/tdesc.h" + +static int +create_feature_aarch64_fpmr (struct target_desc *result, long regnum) +{ + struct tdesc_feature *feature; + + feature = tdesc_create_feature (result, "org.gnu.gdb.aarch64.fpmr"); + tdesc_type_with_fields *type_with_fields; + type_with_fields = tdesc_create_enum (feature, "fp8_fmt", 3); + tdesc_add_enum_value (type_with_fields, 0, "E5M2"); + tdesc_add_enum_value (type_with_fields, 1, "E4M3"); + + type_with_fields = tdesc_create_enum (feature, "osc", 1); + tdesc_add_enum_value (type_with_fields, 0, "Inf/NaN"); + tdesc_add_enum_value (type_with_fields, 1, "MaxNormal"); + + type_with_fields = tdesc_create_enum (feature, "osm", 1); + tdesc_add_enum_value (type_with_fields, 0, "Inf"); + tdesc_add_enum_value (type_with_fields, 1, "MaxNormal"); + + type_with_fields = tdesc_create_flags (feature, "fpmr_flags", 8); + tdesc_type *field_type; + field_type = tdesc_named_type (feature, "fp8_fmt"); + tdesc_add_typed_bitfield (type_with_fields, "F8S1", 0, 2, field_type); + field_type = tdesc_named_type (feature, "fp8_fmt"); + tdesc_add_typed_bitfield (type_with_fields, "F8S2", 3, 5, field_type); + field_type = tdesc_named_type (feature, "fp8_fmt"); + tdesc_add_typed_bitfield (type_with_fields, "F8D", 6, 8, field_type); + field_type = tdesc_named_type (feature, "osm"); + tdesc_add_typed_bitfield (type_with_fields, "OSM", 14, 14, field_type); + field_type = tdesc_named_type (feature, "osc"); + tdesc_add_typed_bitfield (type_with_fields, "OSC", 15, 15, field_type); + tdesc_add_bitfield (type_with_fields, "LSCALE", 16, 22); + field_type = tdesc_named_type (feature, "int8"); + tdesc_add_typed_bitfield (type_with_fields, "NSCALE", 24, 31, field_type); + tdesc_add_bitfield (type_with_fields, "LSCALE2", 32, 37); + + tdesc_create_reg (feature, "fpmr", regnum++, 1, NULL, 64, "fpmr_flags"); + return regnum; +} diff --git a/gdb/features/aarch64-fpmr.xml b/gdb/features/aarch64-fpmr.xml new file mode 100644 index 00000000000..edbae6d107c --- /dev/null +++ b/gdb/features/aarch64-fpmr.xml @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- 2.45.2