multi-arch and CALL_DUMMY_BREAKPOINT_OFFSET
Richard Earnshaw
rearnsha@arm.com
Fri Feb 8 03:35:00 GMT 2002
I guess I'm going to find several things like this...
Well it appears that in a multi-arch gdb (even at level 1),
CALL_DUMMY_BREAKPOINT_OFFSET can only be a constant for any particular
architecture. This is a problem, because on the ARM it is currently a
function that returns one of two values depending on whether the
call-dummy stub has to be ARM code or Thumb code. Note that both types of
code can exist within a single application and it is not always safe to
assume that every function is interworking safe.
I guess I could re-write the whole of the call-dummy stuff so that
appropriate breakpoints are built in, but that is certainly going to be
non-trivial.
Any suggestions? Can I diddle with the gdbarch setting dynamically -- eg
by calling gdbarch_set_call_dummy_breakpoint_offset() from within
arm_fix_call_dummy()? It's quite gross, but it might work.
Long term it would probably be better to rewrite the call-dummy handling
to remove the covert variable that is used to communicate between the
various call-dummy stubs, but I'd rather not do that now.
R.
More information about the Gdb
mailing list