public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
From: Tom Tromey <tom@tromey.com>
To: Pedro Alves <pedro@palves.net>
Cc: "gdb@sourceware.org" <gdb@sourceware.org>
Subject: Re: A note about a GDB BoF topic - libgdbserver
Date: Fri, 28 Aug 2020 10:55:13 -0600	[thread overview]
Message-ID: <87mu2e90cu.fsf@tromey.com> (raw)
In-Reply-To: <61f8f765-8984-b6ce-8732-5f3e637492d7@palves.net> (Pedro Alves's message of "Fri, 28 Aug 2020 00:48:27 +0100")

Pedro> Of course, another option would be to make gdbserver itself
Pedro> link with libsim.a -- make the sim another gdbserver backend.
Pedro> But that doesn't sound as cool.  ;-)

I looked into this a bit, since I was curious what it would take to make
gdb require target async.

My thought was to have a sort of "libgdbserver" -- basically consisting
of all the non-"target low" files in gdbserver.  Then, write a new low
target somewhere in sim/.

This seemed doable enough, but a bit of a pain as well.  Testing the
sims seems hard, at least for someone like me who isn't up on the
details of the linker scripts to use etc.

Another issue is that gdb lets the sims define a non-standard register
layout.  Maybe this could be reverse-engineered into an XML file that
would be served by the sim.  Or, maybe the sims could be changed to use
gdb's built-in register layout.

Anyway, the main problem is that it looks like a reasonably large amount
of work, but where the impact is low.  This seems especially true since
IIUC, gdb requires even async-capable targets to still support leaving
async mode at times.

Tom

      reply	other threads:[~2020-08-28 16:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-27 23:48 Pedro Alves
2020-08-28 16:55 ` Tom Tromey [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mu2e90cu.fsf@tromey.com \
    --to=tom@tromey.com \
    --cc=gdb@sourceware.org \
    --cc=pedro@palves.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).