public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* gdb testsuite with remote target of qemu in linux-user mode?
@ 2012-02-08 21:24 Greg McGary
  2012-02-10 20:54 ` Tom Tromey
  0 siblings, 1 reply; 6+ messages in thread
From: Greg McGary @ 2012-02-08 21:24 UTC (permalink / raw)
  To: gdb

Does anyone use gdb testsuite with remote target of qemu in linux-user mode?
I see no mention of qemu as a remote simulator in dejagnu, or in gdb/testsuite.

I threw together a qemu.exp to do this, and it seems to work OK everywhere except
with mi-support.exp, which does not appear to have infrastructure to spawn an external
simulator.

G

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb testsuite with remote target of qemu in linux-user mode?
  2012-02-08 21:24 gdb testsuite with remote target of qemu in linux-user mode? Greg McGary
@ 2012-02-10 20:54 ` Tom Tromey
  2012-02-13 20:31   ` Greg McGary
  0 siblings, 1 reply; 6+ messages in thread
From: Tom Tromey @ 2012-02-10 20:54 UTC (permalink / raw)
  To: Greg McGary; +Cc: gdb

>>>>> "Greg" == Greg McGary <greg.mcgary@gmail.com> writes:

Greg> Does anyone use gdb testsuite with remote target of qemu in
Greg> linux-user mode?  I see no mention of qemu as a remote simulator
Greg> in dejagnu, or in gdb/testsuite.

Greg> I threw together a qemu.exp to do this, and it seems to work OK
Greg> everywhere except with mi-support.exp, which does not appear to
Greg> have infrastructure to spawn an external simulator.

I haven't heard of anything, but I think it would be a welcome addition
to gdb/testsuite/boards, if you are so inclined.

Tom

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb testsuite with remote target of qemu in linux-user mode?
  2012-02-10 20:54 ` Tom Tromey
@ 2012-02-13 20:31   ` Greg McGary
  2012-02-14 15:16     ` Mike Frysinger
  2012-02-14 17:24     ` Pedro Alves
  0 siblings, 2 replies; 6+ messages in thread
From: Greg McGary @ 2012-02-13 20:31 UTC (permalink / raw)
  To: Tom Tromey; +Cc: gdb

On 02/10/12 13:54, Tom Tromey wrote:
> >>>>> "Greg" == Greg McGary <greg.mcgary@gmail.com> writes:
>
> Greg> Does anyone use gdb testsuite with remote target of qemu in
> Greg> linux-user mode?  I see no mention of qemu as a remote simulator
> Greg> in dejagnu, or in gdb/testsuite.
>
> Greg> I threw together a qemu.exp to do this, and it seems to work OK
> Greg> everywhere except with mi-support.exp, which does not appear to
> Greg> have infrastructure to spawn an external simulator.
>
> I haven't heard of anything, but I think it would be a welcome addition
> to gdb/testsuite/boards, if you are so inclined.

Correction: mi-support.exp can spawn sid, which is external.  I think
the sensible thing to do is take the sid.exp code and generalize it to
become an external-sim framework, then write a small qemu.exp and
new sid.exp to use it.

Maybe in a few weeks, if I survive this month's death march. :-)

G

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb testsuite with remote target of qemu in linux-user mode?
  2012-02-13 20:31   ` Greg McGary
@ 2012-02-14 15:16     ` Mike Frysinger
  2012-02-14 15:23       ` Greg McGary
  2012-02-14 17:24     ` Pedro Alves
  1 sibling, 1 reply; 6+ messages in thread
From: Mike Frysinger @ 2012-02-14 15:16 UTC (permalink / raw)
  To: gdb; +Cc: Greg McGary, Tom Tromey

[-- Attachment #1: Type: Text/Plain, Size: 1213 bytes --]

On Monday 13 February 2012 15:30:43 Greg McGary wrote:
> On 02/10/12 13:54, Tom Tromey wrote:
> > >>>>> "Greg" == Greg McGary <greg.mcgary@gmail.com> writes:
> > Greg> Does anyone use gdb testsuite with remote target of qemu in
> > Greg> linux-user mode?  I see no mention of qemu as a remote simulator
> > Greg> in dejagnu, or in gdb/testsuite.
> > 
> > Greg> I threw together a qemu.exp to do this, and it seems to work OK
> > Greg> everywhere except with mi-support.exp, which does not appear to
> > Greg> have infrastructure to spawn an external simulator.
> > 
> > I haven't heard of anything, but I think it would be a welcome addition
> > to gdb/testsuite/boards, if you are so inclined.
> 
> Correction: mi-support.exp can spawn sid, which is external.  I think
> the sensible thing to do is take the sid.exp code and generalize it to
> become an external-sim framework, then write a small qemu.exp and
> new sid.exp to use it.

i'm not entirely clear on what you want to do.  when you compile programs, you 
want to run them through qemu-user to verify they execute properly ?  or you 
want to launch qemu-user in gdb mode and then have gdb connect to that remote 
target ?
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb testsuite with remote target of qemu in linux-user mode?
  2012-02-14 15:16     ` Mike Frysinger
@ 2012-02-14 15:23       ` Greg McGary
  0 siblings, 0 replies; 6+ messages in thread
From: Greg McGary @ 2012-02-14 15:23 UTC (permalink / raw)
  To: Mike Frysinger; +Cc: gdb

On 02/14/12 08:15, Mike Frysinger wrote:

> i'm not entirely clear on what you want to do.  when you compile programs, you 
> want to run them through qemu-user to verify they execute properly ?

No--that's the GCC testsuite's job.

> ... or you 
> want to launch qemu-user in gdb mode and then have gdb connect to that remote 
> target ?

Yes.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: gdb testsuite with remote target of qemu in linux-user mode?
  2012-02-13 20:31   ` Greg McGary
  2012-02-14 15:16     ` Mike Frysinger
@ 2012-02-14 17:24     ` Pedro Alves
  1 sibling, 0 replies; 6+ messages in thread
From: Pedro Alves @ 2012-02-14 17:24 UTC (permalink / raw)
  To: Greg McGary; +Cc: Tom Tromey, gdb

On 02/13/2012 08:30 PM, Greg McGary wrote:
> On 02/10/12 13:54, Tom Tromey wrote:
>>>>>>> "Greg" == Greg McGary <greg.mcgary@gmail.com> writes:
>>
>> Greg> Does anyone use gdb testsuite with remote target of qemu in
>> Greg> linux-user mode?  I see no mention of qemu as a remote simulator
>> Greg> in dejagnu, or in gdb/testsuite.
>>
>> Greg> I threw together a qemu.exp to do this, and it seems to work OK
>> Greg> everywhere except with mi-support.exp, which does not appear to
>> Greg> have infrastructure to spawn an external simulator.
>>
>> I haven't heard of anything, but I think it would be a welcome addition
>> to gdb/testsuite/boards, if you are so inclined.
> 
> Correction: mi-support.exp can spawn sid, which is external.  I think
> the sensible thing to do is take the sid.exp code and generalize it to
> become an external-sim framework, then write a small qemu.exp and
> new sid.exp to use it.

Since you'll be using "target remote", it'd be a good idea to look at
how we handle testing with gdbserver.  There's probably not much different
from testing with qemu, other than that you spawn a different program with different
args.  You may want to take a look at the boards under gdb/testsuite/boards (guts in
gdb/testsuite/lib/gdbserver-support.exp).   There are examples of both connecting with
tcp, and with a pipe (target remote | qemu ...).

> Maybe in a few weeks, if I survive this month's death march. :-)

-- 
Pedro Alves

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-02-14 17:24 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-02-08 21:24 gdb testsuite with remote target of qemu in linux-user mode? Greg McGary
2012-02-10 20:54 ` Tom Tromey
2012-02-13 20:31   ` Greg McGary
2012-02-14 15:16     ` Mike Frysinger
2012-02-14 15:23       ` Greg McGary
2012-02-14 17:24     ` Pedro Alves

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).