From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ot1-x329.google.com (mail-ot1-x329.google.com [IPv6:2607:f8b0:4864:20::329]) by sourceware.org (Postfix) with ESMTPS id DAF533858D35 for ; Mon, 9 Oct 2023 12:10:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org DAF533858D35 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ot1-x329.google.com with SMTP id 46e09a7af769-6c4e30a3604so3033355a34.2 for ; Mon, 09 Oct 2023 05:10:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1696853403; x=1697458203; darn=sourceware.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=V9h+teff6Dq7YwI3WpeDNewPXOxX0TdaKi83rLQw48c=; b=KweVgDld2zSY496ccQ96VbHnho3ZMjEm3jEKxJdcsQDOEFt+TJOvwikWApHHbh9H/C BWai2nHSqZ8TVeGL81AgX+SQ/K4yW9jy+zKAXM2aPHDdYxFutkstu2LHO+BDVX4bPDVv tRBJnxdS58yk0yUFF3iIB4gMNpXsFLvpFNMI+p1B/JMQ0lo2iTzlLI3ppBqFXESNUhBJ mvsjuRbA00RiTdXBnILZFdkcxP1/1Xjo7jR+83Np7K4GHZDLSQRGlmczjW9+jUkpHxFg FKHEo9Q4+D6TFbGbmQ70CfU2BCoO/gFE9qP69G9PlD+tUWp/YlpoMBptH2TqmhREzqUR tpcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696853403; x=1697458203; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=V9h+teff6Dq7YwI3WpeDNewPXOxX0TdaKi83rLQw48c=; b=X5Pc39Z6RBQqJQA8eP4r3uf31oV8IwgmhmzV1FE2ZcmtTCoHaNJjubvEOMbq4EeMa7 0/1evLvT/bwGwIHuZnVAwdF2YlmTjmwimV0vFhHbYARPEkQievPA9XFUM8TZ7XL057nG P3TAyE5e2sBTFDwHDmHO1GwMOYBlRPcVeoeK6kwnm4Nn51LgABFt3jDA5Lw9B7ELQTwP X99AuURpqQCa4F67NN0mrzGJAZzKhHSQ6qxsqzTADfzVNf9HU9vpz+/uC0cfTmJloErE Y9vCRXnylpk+pqRGMMs575xVgHdGTzogl7b+JQ7gbnb53nUbDzpaBqaA+o3CvI/QJl73 G00Q== X-Gm-Message-State: AOJu0Yz9mKLFCPEYAlH//4IvU+lDOx3/mSS5PF+YWAIxdFPCF71/5gqZ Z/ebbYkfj3B68u/ejd5YQWPFJHagr1aND7Ixfsw= X-Google-Smtp-Source: AGHT+IE0jkVZFJTk98ye7wxk3aRUWs5ylUNbw2e1ln5prSEyeFqTHCayCk/cxa4/SHT+Dmv6DOu3H50wzvugxoAmHMw= X-Received: by 2002:a05:6870:3328:b0:1d1:2605:bb0a with SMTP id x40-20020a056870332800b001d12605bb0amr18384663oae.26.1696853403016; Mon, 09 Oct 2023 05:10:03 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: William Tambe Date: Mon, 9 Oct 2023 07:09:53 -0500 Message-ID: Subject: Re: warning: Target-supplied registers are not supported by the current architecture To: Luis Machado Cc: "Aktemur, Tankut Baris" , "gdb@sourceware.org" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On Mon, Oct 9, 2023 at 6:23=E2=80=AFAM Luis Machado = wrote: > > On 10/9/23 11:46, William Tambe via Gdb wrote: > > On Mon, Oct 9, 2023 at 1:45=E2=80=AFAM Aktemur, Tankut Baris > > wrote: > >> > >> On Monday, October 9, 2023 1:14 AM, William Tambe wrote: > >>> I am working on gdbserver support. > >>> > >>> I am able to remotely execute the executable and set breakpoints, > >>> however right after issuing the `target remote` command, I am getting > >>> following warning: > >>> > >>> (gdb) target remote 192.168.1.164:2000 > >>> Remote debugging using 192.168.1.164:2000 > >>> warning: Target-supplied registers are not supported by the current a= rchitecture > >>> > >>> Error message is coming from gdb/target-descriptions.c at line 576, > >>> due to data->arch_regs.empty () return true. > >>> > >>> Any idea what I might have missed causing data->arch_regs.empty () to > >>> return true ? > >> > >> When gdbserver is started with the --remote-debug flag, it prints the > >> received and sent RSP packages. There, the target description XML wou= ld > >> be seen. I'd suggest starting with inspecting if the contents of that= XML > >> look right. > > > > Below snippet of the prints when using --remote-debug shows the target > > description XML. > > I see a star in front of blocks; any idea whether > > that could be the issue ? > > In the source code, I am not using an actual XML file, instead, I am > > manually building the target description XML through calls to > > tdesc_create_reg: > > https://github.com/fontamsoc/binutils-gdb/blob/main/gdbserver/linux-pu3= 2-low.cc#L63 > > > > [remote] getpkt: getpkt ("qXfer:features:read:target.xml:0,1000"); > > [no ack sent] > > [remote] putpkt_binary_1: putpkt ("$l > > > > > > pu32 > > GNU/Linux > > > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > * > > > > > > #ae"); [noack mode] > > [remote] getpkt: getpkt ("qXfer:auxv:read::0,1000"); [no ack sent] > > > > > > Any ideas on what I am doing wrong ? > > What architecture is this out of curiosity? Are you enabling a new archit= ecture called pu32? Correct, I am enabling a new architecture called pu32; more detail at https://github.com/fontamsoc . >