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]

different packet sequence form same gdb version


Hi all,

  I am using a cross gdb (arm-elf-gdb.exe) on windows.
I  have two arm-elf-gdb.exe files of same gdb version
6.1. One I got from precompiled GNUARM toolchain and
one is compiled by me on cygwin from sources
(gdb-6.1.tar.gz, dated 2004-04-03). 
 With both of these, I am getting different packet
sequence while I debug the same program. I don't know
how this can happen? Even the beahviour I noticed is
different for both of arm-elf-gdb.exe's. 

  Following is the disassembly and packet sequence
from both --

 Disassembly
  ===========

00000054 <abc_main>:
      54:	eb000000 	bl	5c <main>

00000058 <HERE>:
      58:	eafffffe 	b	58 <HERE>

0000005c <main>:
      5c:	e1a0c00d 	mov	ip, sp
      60:	e92dd800 	stmdb	sp!, {fp, ip, lr, pc}
      64:	e24cb004 	sub	fp, ip, #4	; 0x4
		........	...
		........	...
		........	...

  

  Precompiled (GNUARM) arm-elf-gdb:
  =================================

GNU gdb 6.1
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General
Public License, and you are welcome to change it
and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show
warranty" for details.
This GDB was configured as "--host=i686-pc-cygwin
--target=arm-elf"...
(gdb) set debug remote 1
(gdb) tar re /dev/ttyS0
Remote debugging using /dev/ttyS0
Sending packet: $Hc-1#09...Ack
Packet received: OK
Sending packet: $qC#b4...Ack
Packet received:
Sending packet: $qOffsets#4b...Ack
Packet received: Text=0;Data=0;Bss=0
Sending packet: $?#3f...Nak
Sending packet: $?#3f...Ack
Packet received: S05
Sending packet: $Hg0#df...Ack
Packet received: OK
Sending packet: $g#67...Ack
Packet received: 3100000<...long packet...>000020
0x000001e0 in .abc_loop ()
(gdb) s
Sending packet: $m1d0,4#92...Ack
Packet received: 0000a0e3
Sending packet: $m1d4,4#96...Ack
Packet received: 0b0000eb
Sending packet: $m1d8,4#9a...Ack
Packet received: 2a0700eb
Sending packet: $m1dc,4#c5...Ack
Packet received: ff00ffe7
Single stepping until exit from function .abc_loop,
which has no line number information.
Sending packet: $vCont?#49...Ack
Packet received:
Packet vCont (verbose-resume) is NOT supported
Sending packet: $Hc0#db...Ack
Packet received: OK
Sending packet: $s#73...Nak
Sending packet: $s#73...Ack =====================>>>>>
sends s-pkt if I ask to take step
Packet received: S05
Sending packet: $g#67...Nak
Sending packet: $g#67...Ack
Packet received: 31000000<...long packet...>000020
abc_main () at abc_start.s:21
21              BL main   
Current language:  auto; currently asm
(gdb) s
Sending packet: $s#73...Ack  
=======================>>>>> sends s-pkt if I ask to
take step
Packet received: S05
Sending packet: $g#67...Nak
Sending packet: $g#67...Ack
Packet received: 3100000<...long packet...>000020
Sending packet: $Z0,6c,4#af...Ack
Packet received: OK
Packet Z0 (software-breakpoint) is supported
Sending packet: $c#63...Ack
Packet received: S05



   My own compiled arm-elf-gdb
   ===========================

GNU gdb 6.1
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General
Public License, and you are
welcome to change it and/or distribute copies of it
under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show
warranty" for details.
This GDB was configured as "--host=i686-pc-cygwin
--target=arm-elf"...
(gdb) set debug remote 1
(gdb) tar re /dev/ttyS0
Remote debugging using /dev/ttyS0
Sending packet: $Hc-1#09...Ack
Packet received: OK
Sending packet: $qC#b4...Ack
Packet received:
Sending packet: $qOffsets#4b...Ack
Packet received: Text=0;Data=0;Bss=0
Sending packet: $?#3f...Nak
Sending packet: $?#3f...Ack
Packet received: S05
Sending packet: $Hg0#df...Ack
Packet received: OK
Sending packet: $g#67...Ack
Packet received: 3100000<...long packet...>000020
0x000001e0 in .abc_loop ()
(gdb) s
Sending packet: $m1d0,4#92...Ack
Packet received: 0000a0e3
Sending packet: $m1d4,4#96...Ack
Packet received: 0b0000eb
Sending packet: $m1d8,4#9a...Ack
Packet received: 2a0700eb
Sending packet: $m1dc,4#c5...Ack
Packet received: ff00ffe7
Single stepping until exit from function .abc_loop,
which has no line number information.
Sending packet: $m1e0,4#93...Ack
Packet received: 9bffffea
Sending packet: $Z0,54,4#7f...Ack
====================>>>>> sends (bkpt) Z-pkt if I ask
to take step
Packet received: OK
Packet Z0 (software-breakpoint) is supported
Sending packet: $vCont?#49...Ack
Packet received:
Packet vCont (verbose-resume) is NOT supported
Sending packet: $Hc0#db...Ack
Packet received: OK
Sending packet: $c#63...Nak        
=======================>>>>> and then tell continue 
Sending packet: $c#63...Ack
Packet received: S05
Sending packet: $g#67...Ack
Packet received: 3100000<...long packet...>000020
Sending packet: $z0,54,4#9f...Ack
Packet received: OK
abc_main () at abc_start.s:21
21              BL main         
Current language:  auto; currently asm

>>>>>>>>>>> here doesn't step to main though I asked,
instead put bkpt at next n cont >>>>>>>>>>>> 

(gdb) s                             
sending packet: $m54,4#36...Ack           
Packet received: f202f0e7
Sending packet: $Z0,58,4#83...Ack 
===================>>>>> sends (bkpt) Z-pkt if I ask
to take step
Packet received: OK
Sending packet: $c#63...Nak
Sending packet: $c#63...Ack     
=======================>>>>> and then tell continue 


  I am not able to find how two gdbs of same version
can behave like this? I'd really appericiate if anyone
Can explain me this...?

Thanks and regards,
Mangesh Edake.



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


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