This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: gdb testsuite with remote target of qemu in linux-user mode?


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]