This is the mail archive of the gdb@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: assertion failure in regcache.c


I just did an update and now I'm getting an assertion failure with my sh4
port.

gdb/regcache.c:241: internal-error: init_regcache_descr: Assertion
`descr->register_offset[i] == REGISTER_BYTE (i)' failed.

My code worked in the past few weeks so it looks like this is something
recent.  The only change I can see to regcache.c and sh-tdep.c is to use
DEPRECATED_REGISTER_BYTES.  Can anyone give any suggestions as to what might
be going wrong?

Can you go back to the ``working'' code and check the output from:


(gdb) maint print registers

(look for footnotes). I added a sanity check with:

2003-05-04 Andrew Cagney <cagney@redhat.com>

        * sentinel-frame.c (sentinel_frame_prev_register): Replace
        REGISTER_BYTE with register_offset_hack.
        * regcache.c (init_regcache_descr): When REGISTER_BYTE_P, check
        that REGISTER_BYTE is consistent with the regcache.
        * gdbarch.sh (REGISTER_BYTE): Add a predicate.
        * gdbarch.h, gdbarch.c: Regenerate.

however, I suspect that there has been long standing disagreement over the offsets only nothing was noticing it :-/

Andrew



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