From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id e5oWBX1r7GqGjh8AWB0awg (envelope-from ) for ; Thu, 05 Nov 2026 06:41:49 -0500 Authentication-Results: simark.ca; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=hk/HgXhY; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id F2F471E089; Thu, 05 Nov 2026 06:41:48 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [IPv6:2620:52:6:3111::32]) (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 7DA311E023 for ; Thu, 05 Nov 2026 06:41:47 -0500 (EST) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id B64174BA23C9 for ; Thu, 5 Nov 2026 11:41:45 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B64174BA23C9 Authentication-Results: sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=hk/HgXhY Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.17]) by sourceware.org (Postfix) with ESMTPS id 595534BA2E09 for ; Thu, 5 Nov 2026 11:41:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 595534BA2E09 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=intel.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 595534BA2E09 Authentication-Results: sourceware.org; arc=none smtp.remote-ip=198.175.65.17 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1793878878; cv=none; b=rxFi3T7kl9NVP+awmJ+9HW4Wtnp1kAAy0sBtEpo75agNFlQRmL/rKcPQsKQB9dM4tneDnl5L8cS9yiJ3Pym7sLTRg1y1Scmr/q7gyr39OP/O+8WDA9KWaKJ8GnU3FWB1uhD1n5Sefd8uBlXULprzN0OnOYHvrAqZKOmvULQ8848= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1793878878; c=relaxed/simple; bh=HxbcpRmXYMFXEOyTuDDBfE3TSoIgk24Xl71o00dxYqY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=b+fwFUocwOG4KszcDsls/rmZdsQ3yCULb2jbl7jeVUX+vmJmKrtqnlZr7e4SP9Qlelq3qH+w9D97LsR/GiMFT2fzCYqR7vUBYvVL9RTtVdUeNfwSxqS0Cb+4v15cwUeCQQ9VF9mY742lvimAREusMf//T/p8Q0NgBxphksPA8UE= ARC-Authentication-Results: i=1; sourceware.org; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=hk/HgXhY DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 595534BA2E09 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1793878878; x=1825414878; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=HxbcpRmXYMFXEOyTuDDBfE3TSoIgk24Xl71o00dxYqY=; b=hk/HgXhY03JQ7lvtVPD/PbpXoPhTAY1PZVGD7uCbd1ddLPRxlHyRfetI DaYprR7mBc72x21G1JWj5jLHJo4A4fD9BZqiqpuaR49gYe8fsB2nodpQe 0VY0A6YtpM6xxjmGwxZ+rhgQSR188XfaUi2edcCQDKa/8iblVpiIbuPL5 uaAMR7DOoUAhNJAqZkBjfhgYm+VnBrD0HU9v8KELynvfaNwA1Tt7ZH+Pq Dbu1zZT1kLrsL4aGbqARidz/Po1WxVXkZI9JrYpFXz9RmeDqS9P4ABeqB XnWom3LNGdWnIMwnq+DF1aLZQCjVOtVNBJln2p3THucATOeZHRpjjQybE g==; X-CSE-ConnectionGUID: rKTqR+jrQwCBPOB08jJ5AA== X-CSE-MsgGUID: Iu5ar/0NTHGyC88sHmsY7g== X-IronPort-AV: E=McAfee;i="6800,10657,11956"; a="2681955" X-IronPort-AV: E=Sophos;i="6.27,197,1787036400"; d="scan'208";a="2681955" Received: from orviesa005.jf.intel.com ([10.64.159.145]) by orvoesa109.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Nov 2026 03:41:17 -0800 X-CSE-ConnectionGUID: ff0hD1B7SWqnxWsAUoRepw== X-CSE-MsgGUID: 9yw5pFYWSQeMQLF3D9C9MA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.27,197,1787036400"; d="scan'208";a="6874313" Received: from dut1048pvc.igk.intel.com (HELO localhost) ([10.211.177.228]) by smtpauth.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 05 Nov 2026 03:41:15 -0800 From: Stephan Rohr To: gdb-patches@sourceware.org Cc: pedro@palves.net, eliz@gnu.org, jhb@FreeBSD.org, luis.machado@arm.com, christina.joos@intel.com Subject: [PATCH v3 0/5] Add Intel AMX support Date: Thu, 5 Nov 2026 11:41:04 +0000 Message-ID: <20261105114109.153949-1-stephan.rohr@intel.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit 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: "Rohr, Stephan" Hi Christina, all, this is v3 of the series enabling Intel AMX support for GDB. I addressed the comments from Christina; here's a detailed list of changes: Changes since v2 ================ v2 was posted here: https://sourceware.org/pipermail/gdb-patches/2026-October/231500.html v2 patch 1/5: gdb: define additional integer built-in types No changes. v2 patch 2/5: gdb, gdbserver: Add Intel AMX registers. Christina posted feedback: https://sourceware.org/pipermail/gdb-patches/2026-November/231586.html https://sourceware.org/pipermail/gdb-patches/2026-November/231592.html - TILECFG and TILEDATA are now cleared separately in gdbserver, depending on their bits in XSTATE_BV. - Removed tilecfg_register_names and I387_NUM_TILECFG_REGS. The register name arrays are now const. - Test register groups for the raw tile registers and the $tilecfg pseudo register. - Updated the testcase: * The test now adds an Intel AMX instruction that operates on the tile registers written by GDB. * The test program now releases the tiles and runs to the end. - Updated the commit message. v2 patch 3/5: gdb: support register groups for user registers No changes. v2 patch 4/5: gdb: add a "matrix" register group No changes. v2 patch 5/5: gdb: add Intel AMX tile registers as user registers Christina posted feedback: https://sourceware.org/pipermail/gdb-patches/2026-November/231622.html https://sourceware.org/pipermail/gdb-patches/2026-November/231594.html - The user registers now show "void" for all invalid tile configurations: * If palette 0 is configured. * If rows or colsb is zero. * If the configured number of rows exceeds the upper bound. * If the configured number of bytes per row exceeds the upper bound. * If the configured number of bytes per row modulo 4 is not zero. Intel AMX operates on doublewords. If this requirement is not met, the CPU raises #UD (invalid opcode) for any instruction that loads, stores or computes with that tile; TILEZERO, LDTILECFG, STTILECFG and TILERELEASE are not affected. Since this is an invalid configuration, and the row would not consist of complete doublewords, we decided to show "void" in this case, too. - With the above, the assertion does not trigger anymore. - Renamed "tilecfg_reg" to "tile_dimensions". Removed the unused "operator==". - Describe the cases where the user registers print "void" in the manual. I kept the order of the patches; the last patch adds $tilecfg to the "matrix" register group. I appreciate your feedback. Thanks Stephan Aleksandar Paunovic (1): gdb: define additional integer built-in types Felix Willgerodt (1): gdb, gdbserver: Add Intel AMX registers. Rohr, Stephan (3): gdb: support register groups for user registers gdb: add a "matrix" register group gdb: add Intel AMX tile registers as user registers gdb/NEWS | 17 ++ gdb/amd64-linux-tdep.c | 2 + gdb/amd64-tdep.c | 134 +++++++- gdb/amd64-tdep.h | 3 + gdb/arch/amd64.c | 4 + gdb/arch/x86-linux-tdesc-features.c | 5 +- gdb/doc/gdb.texinfo | 79 ++++- gdb/features/Makefile | 1 + gdb/features/i386/64bit-amx.c | 26 ++ gdb/features/i386/64bit-amx.xml | 26 ++ gdb/gdbtypes.c | 8 + gdb/gdbtypes.h | 4 + gdb/i386-tdep.c | 236 +++++++++++++- gdb/i386-tdep.h | 120 +++++++- gdb/i387-tdep.c | 196 +++++++++++- gdb/i387-tdep.h | 5 + gdb/infcmd.c | 28 ++ gdb/nat/x86-xstate.c | 2 + gdb/reggroups.c | 3 + gdb/reggroups.h | 1 + gdb/target-debug.h | 2 + gdb/target-descriptions.c | 12 + gdb/testsuite/gdb.arch/amd64-amx.c | 142 +++++++++ gdb/testsuite/gdb.arch/amd64-amx.exp | 442 +++++++++++++++++++++++++++ gdb/testsuite/lib/amd64-amx.h | 41 +++ gdb/testsuite/lib/gdb.exp | 75 +++++ gdb/user-regs.c | 46 ++- gdb/user-regs.h | 17 +- gdbserver/i387-fp.cc | 70 ++++- gdbserver/linux-x86-low.cc | 2 + gdbsupport/tdesc.cc | 4 + gdbsupport/tdesc.h | 4 + gdbsupport/x86-xstate.h | 26 +- 33 files changed, 1748 insertions(+), 35 deletions(-) create mode 100644 gdb/features/i386/64bit-amx.c create mode 100644 gdb/features/i386/64bit-amx.xml create mode 100644 gdb/testsuite/gdb.arch/amd64-amx.c create mode 100644 gdb/testsuite/gdb.arch/amd64-amx.exp create mode 100644 gdb/testsuite/lib/amd64-amx.h -- 2.43.0 ________________________________________ Intel Deutschland GmbH Registered Address: Dornacher Strasse 1, 85622 Feldkirchen, Germany Tel: +49 (89) 99143-0 www.intel.de Managing Directors: Candice Moore, Jeffrey Schneiderman, Ramachandran Sitaraman Chairperson of the Supervisory Board: Sonja Pierer Registered Seat: Munich Commercial Register B: Amtsgericht Munich HRB 186928 This e-mail and any attachments may contain confidential material for the sole use of the intended recipient(s). Any review or distribution by others is strictly prohibited. If you are not the intended recipient, please contact the sender and delete all copies.