On 10/15/2010 10:11 AM, Camm Maguire wrote:
Greetings! What is wrong with this stub attempting a jump to contents
of register $t0?
(gdb) p/x *(ul *)0x1094...@4
$3 = {0x3c080077, /*lui t0,0x77*/
0x2508a170, /*addui t0,t0,0xa170*/
0x8d08a288, /*lw t0,-23928(t0) */
0x1000008 /* jr t0*/ }
What instruction follows this JR? It will always be executed in the
delay slot of the jump. If it causes an exception, like BREAK or an
illegal instruction would, $pc will be left pointing at the JR so that
it can retry the whole thing once the mess is cleaned up.
David Daney
(gdb) c
Program received signal SIGTRAP, Trace/breakpoint trap.
0x01094148 in ?? () /*this is the jump instruction*/
(gdb) i reg t0
t0: 0x2ae13bf0 /*this is the correct address*/
Any help most appreciated!
Take care,
David Daney<[email protected]> writes:
On 09/22/2010 04:05 PM, David Daney wrote:
[...]
[11] .init PROGBITS 10000458 000458 000078 00 AX 0 0 8
[12] .plt PROGBITS 100004e0 0004e0 000030 00 AX 0 0 32
[13] .text PROGBITS 10000510 000510 0002c0 00 AX 0 0 16
[14] .MIPS.stubs PROGBITS 100007d0 0007d0 000020 00 AX 0 0 4
[15] .fini PROGBITS 100007f0 0007f0 000048 00 AX 0 0 8
[16] .rodata PROGBITS 10000838 000838 000020 00 A 0 0 8
[17] .eh_frame PROGBITS 10000858 000858 000004 00 A 0 0 4
[18] .ctors PROGBITS 1001085c 00085c 000008 00 WA 0 0 4
[...]
Look there, the PLT is section 17.
Well really it is section 12. But what is a difference of 5 among friends?
David Daney
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]
Archive: http://lists.debian.org/[email protected]