[K42-discussion] Problem debugging linux user mode apps with K42 remote gdb

Bryan S Rosenburg rosnbrg at us.ibm.com
Tue Aug 29 06:52:50 EST 2006


That all looks completely normal.  So the problem is with how gdb is 
interpreting the machine state, not with the machine state itself.  What 
version of gdb are you using?  And how was it built?  Is it a 
cross-debugger (x86 to powerpc)?

- Bryan




Patrick Bozeman <PEBozeman at lbl.gov> 
Sent by: k42-discussion-bounces+rosnbrg=us.ibm.com at ozlabs.org
08/28/2006 04:22 PM
Please respond to
Discussion about K42 <k42-discussion at ozlabs.org>


To
Discussion about K42 <k42-discussion at ozlabs.org>
cc

Subject
Re: [K42-discussion] Problem debugging linux user mode apps with K42 
remote gdb






This is from an early break in the process via DEBUGPROC

(gdb) print/x $pc
$1 = 0x1000702e1a08
(gdb) print/x $lr
$2 = 0x1000702e19d4
(gdb) print/x $r1
$3 = 0x100000029b70
(gdb) print/x $r2
$4 = 0x10008009fb38
(gdb) x/i $pc
0x1000702e1a08 <breakpoint+108>:        ld      r31,-32736(r30)
(gdb) x/i $lr
0x1000702e19d4 <breakpoint+56>: nop
(gdb) x/4xg $r1
0x100000029b70: 0x0000100000029bf0      0x000000000003e000
0x100000029b80: 0x00001000702e19d4      0x000000000003e000
(gdb) x/4xg (*((unsigned long long *) $r1))
0x100000029bf0: 0x0000100000029ef0      0x0000100000029e30
0x100000029c00: 0x00001000702e6b3c      0x000010000002aba0


This is from a tassertMsg(0, ...) in dup2.C

(gdb) print/x $pc
$1 = 0x1000702e1a08
(gdb) print/x $lr
$2 = 0x1000702e19d4
(gdb) print/x $r1
$3 = 0x10000002a8d0
(gdb) print/x $r2
$4 = 0x10008009fb38
(gdb) x/i $pc
0x1000702e1a08 <breakpoint+108>:        ld      r31,-32736(r30)
(gdb) x/i $lr
0x1000702e19d4 <breakpoint+56>: nop
(gdb) x/4xg $r1
0x10000002a8d0: 0x000010000002a950      0x0000000000000000
0x10000002a8e0: 0x00001000702e19d4      0x000000000000ffff
(gdb) x/4xg (*((unsigned long long *) $r1))
0x10000002a950: 0x000010000002ab70      0x00001000066425c0
0x10000002a960: 0x00001000702dcd4c      0x0000100006683c80


Bryan S Rosenburg wrote:
>
> Patrick,
>
> I can't think of anything you're doing wrong.  Next time you connect, 
> would you collect and publish some of the machine state?  To start 
> with, I'd like to see the output of:
>
> print/x $pc
> print/x $lr
> print/x $r1
> print/x $r2
> x/i $pc
> x/i $lr
> x/4xg $r1
> x/4xg (*((unsigned long long *) $r1))
>
> - Bryan
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> K42-discussion mailing list
> K42-discussion at ozlabs.org
> https://ozlabs.org/mailman/listinfo/k42-discussion
> 

_______________________________________________
K42-discussion mailing list
K42-discussion at ozlabs.org
https://ozlabs.org/mailman/listinfo/k42-discussion

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/k42-discussion/attachments/20060828/73ecd282/attachment.htm 


More information about the K42-discussion mailing list