This is the mail archive of the gdb-patches@sources.redhat.com 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: [patch rfc] Add NUM_REGS pseudo regs to MIPS


Sigh. Something in the backtrace is still amiss.


#2 0x080ca201 in gdbarch_register_sim_regno (gdbarch=0x82fdc48, reg_nr=90)
at ../../combined/gdb/gdbarch.c:4078
#3 0x08125173 in gdbsim_fetch_register (regno=90) at ../../combined/gdb/remote-sim.c:299
#4 0x08093e0b in legacy_read_register_gen (regnum=90, myaddr=0xbffff140 " ñÿ¿HÜ/\bhñÿ¿î\211\f\bHÜ/\bZ")
at ../../combined/gdb/regcache.c:727

As far as I can tell, frame_register_unwind doesn't call legacy_read_register_gen.


#5 0x08113891 in frame_register_unwind (frame=0x82e0f40, regnum=90, optimizedp=0xbffff0e8, lvalp=0xbffff0ec, addrp=0xbffff0f0, realnump=0xbffff014, bufferp=0xbffff140) at ../../combined/gdb/frame.c:534
#6 0x080dbd82 in mips_get_saved_register (
raw_buffer=0xbffff140 " ñÿ¿HÜ/\bhñÿ¿î\211\f\bHÜ/\bZ", optimizedp=0xbffff0e8, addrp=0xbffff0f0, frame=0x82e0f40, regnum=90, lvalp=0xbffff0ec)
at ../../combined/gdb/mips-tdep.c:5603

I suspect some agressive tail-call optimization by GCC is involved. Can you update your sources (so that we both have the same code) and then configure/build gdb using:


CFLAGS="-O -g" .../configure ....

so that -O2 is disabled (or at least should be).

Andrew



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