From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oa1-x31.google.com (mail-oa1-x31.google.com [IPv6:2001:4860:4864:20::31]) by sourceware.org (Postfix) with ESMTPS id 289333858D1E for ; Mon, 30 Jan 2023 14:05:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 289333858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-oa1-x31.google.com with SMTP id 586e51a60fabf-15fe106c7c7so15073449fac.8 for ; Mon, 30 Jan 2023 06:05:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :user-agent:references:from:to:cc:subject:date:message-id:reply-to; bh=4oAxSsdQbxVnoMre8LQC81w5MSTx0TrCPV6j8JWSTBA=; b=VaR4UTmKS1fbXJAUf132ZRyoCkXaPFSq3qLtcutmhTuUB35QA3u/0DtUejKfaSGvd7 4uBRelv0Lq+0mUiDttEYTHtHT8y8BMoWvgzq2PZoQRZE+lRmoc8J3FCIX51tNJVNPpjT /eqdIpHaouyoVIVJKTW/k/emh09L5y/baC0m876PbklyHe+iVi9iaKCmbE2LoN1Nl7pn 5BHMwT4RGh8k+Yp0YObfj90Pzn/wA6Fgy8iAx6YsYFnC23zs/jZd1hkXPaVO1O/DY1mM CFYiQpc8BUzjKtvdNd0WTVU+bN/qf7yj/qaUJoXmF7WGSbcseOdLPOy2FRd/2SYfoGuK q6Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :user-agent:references:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=4oAxSsdQbxVnoMre8LQC81w5MSTx0TrCPV6j8JWSTBA=; b=TkZAFUOEKwAhCEfaiG6LpwczaaKQw1to78c5LAvIqoJ1YL0CmiJF7VSxPN2pBh5P5i RRUcWOEXGCTQBMB/cjBZaWCoRyQ+X9O0BAWDIBEpF0MzwWykF6hAQPQrvuwfQN+EWc0A bAx1mWbzqzCQO7i3g8S3meVLDMJsgflY3UH+SHCZ6Zba8f3iWg0wXfGI+O4OeaiQQtyR nWEVsccYWNdJ2cfOPsVz2uihneqvzXT4U2OZUpvwYyG7xxxwgrcFwOlCqVOyQxQf3l9J AA0sLq0JAvFSkdgX+86ADvXzdds59hc2SFxmOLnpUcDMuDJM/lIbzZvTQr1/z8qYpklJ ubCw== X-Gm-Message-State: AFqh2kqfZz0dpuT8/srY0/k+uHqvmU0qunTVesoUXsZk4c6sLSdrLb4i Kt395yOkAuOfsDKBL0OmHkTHGA== X-Google-Smtp-Source: AMrXdXtyCJcqyhVTpT61YCkSdj9dg8psW1cD0/dikP2l/KsoOQxdWjYNgK0hL0GARLnzifKSZl+0Mg== X-Received: by 2002:a05:6870:9c8f:b0:15f:5ccb:d294 with SMTP id pq15-20020a0568709c8f00b0015f5ccbd294mr19608357oab.34.1675087547494; Mon, 30 Jan 2023 06:05:47 -0800 (PST) Received: from localhost ([2804:14d:7e39:8470:6aec:4492:7143:747]) by smtp.gmail.com with ESMTPSA id w8-20020a9d5388000000b0068bbb73006bsm3192038otg.47.2023.01.30.06.05.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Jan 2023 06:05:46 -0800 (PST) References: <20230130044518.3322695-1-thiago.bauermann@linaro.org> <20230130044518.3322695-6-thiago.bauermann@linaro.org> <83ilgo5gnc.fsf@gnu.org> User-agent: mu4e 1.8.13; emacs 28.2 From: Thiago Jung Bauermann To: Eli Zaretskii Cc: gdb-patches@sourceware.org, simon.marchi@efficios.com Subject: Re: [PATCH v3 5/8] gdbserver: Transmit target description ID in thread list and stop reply In-reply-to: <83ilgo5gnc.fsf@gnu.org> Date: Mon, 30 Jan 2023 14:05:44 +0000 Message-ID: <87y1pkkthj.fsf@linaro.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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: Hello Eli, Eli Zaretskii writes: >> Now that an inferior thread can have a different target description than >> its process, there needs to be a way to communicate this target >> description to GDB. So add the concept of a target description ID to the >> remote protocol, which is used to reference them and allows them to be >> transferred only once over the wire. >> >> The ID is an unsigned integer, and is sent in the 'T AA n1:r1;n2:r2;...' >> stop reply packet as a new 'n:r' pair, where n is "tdesc" and "r" is an >> unsigned integer containing the ID. >> >> It is also sent in the threads list XML in the response of a >> qXfer:threads:read request. The ID is sent as a new "tdesc" attribute of >> the node. >> >> To request the target description XML of a given ID, GDB sends the >> qXfer:features:read request with "target-id-%u.xml" as the annex, where %u >> is the target description ID. >> >> Suggested-By: Simon Marchi >> --- >> gdb/doc/gdb.texinfo | 27 ++++++++++++++++--- >> gdbserver/remote-utils.cc | 57 +++++++++++++++++++++++++++++++++++++++ >> gdbserver/remote-utils.h | 9 +++++++ >> gdbserver/server.cc | 17 ++++++++++-- >> gdbserver/server.h | 4 +++ >> 5 files changed, 109 insertions(+), 5 deletions(-) > > Thanks. Thank you for the quick review! >> +If target description IDs are being used (@pxref{Target Description ID}), >> +@value{GDBN} can retrieve a target description with a given ID by using >> +@samp{target-id-ID.xml} as the @var{annex}, where @var{ID} is the > ^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^ > @file{target-id-@var{id}.xml} @var{id} > > The arguments of @var should be in lower-case, as that looks better in > the printed and HTML versions of the manual. Ah, nice to know that I can nest tags like that. Thank you for the explanation as well. > The documentation part is OK with these problems fixed. Fixed locally. -- Thiago