qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jamie Lokier <jamie@shareable.org>
To: qemu-devel@nongnu.org
Cc: Jan Kiszka <jan.kiszka@web.de>
Subject: Re: [Qemu-devel] Re: [RESEND][PATCH] gdbstub: Add vCont support
Date: Sat, 17 Jan 2009 10:03:51 +0000	[thread overview]
Message-ID: <20090117100350.GB20389@shareable.org> (raw)
In-Reply-To: <200901160015.44729.paul@codesourcery.com>

Paul Brook wrote:
> >  a) Modeling cpus as processes buys us nothing compared to threads given
> >     the fact that we cannot provide a stable memory mapping to the gdb
> >     frontend anyway. (*)
> 
> I disagree. The process model fits perfectly. The whole point is
> that each CPU has its own virtual address space. Separate address
> spaces is the fundamental difference between a process and a thread.

That isn't so fundamental.

Distinct CPUs in an OS like Linux have most of the kernel address
space shared between them - except when in special modes like 4G.  But
some of the kernel address space is per-CPU.

Threads do not necessarily share the whole virtual address space:
sometimes thread-specific storage is mapped into the same address in
each thread.

In Windows processes, historically it's been possible to have a
mixture of process-specific mapped segments and system-wide shared
segments, which looks more like threads.

Of course there's the no-MMU architectures too.

So the distinction which really matters is, surely, with which model
does GDB behave most usefully with multiple CPUs having their own
MMUs?  Does GDB _assume_ all threads have exactly the same address
space, or does GDB allow for threads which have some thread-local
mappings, and therefore always use the correct thread when examining
memory etc.?

-- Jamie

  parent reply	other threads:[~2009-01-17 10:04 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-14 14:44 [Qemu-devel] [RESEND][PATCH] gdbstub: Add vCont support Jan Kiszka
2009-01-14 15:03 ` Krumme, Chris
2009-01-14 16:30   ` [Qemu-devel] " Jan Kiszka
2009-01-15 20:32 ` [Qemu-devel] " Anthony Liguori
2009-01-15 21:27   ` [Qemu-devel] " Jan Kiszka
2009-01-16  0:15     ` Paul Brook
2009-01-16  8:05       ` Jan Kiszka
2009-01-16  8:38         ` Jan Kiszka
2009-01-16 17:05         ` Paul Brook
2009-01-16 19:25           ` Jan Kiszka
2009-01-16 20:42       ` Daniel Jacobowitz
2009-01-17 10:03       ` Jamie Lokier [this message]
2009-01-17 17:33         ` Paul Brook

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=20090117100350.GB20389@shareable.org \
    --to=jamie@shareable.org \
    --cc=jan.kiszka@web.de \
    --cc=qemu-devel@nongnu.org \
    /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 NNTP newsgroup(s).