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: SH5 compact register numbering in gcc -> gdb interface


aoliva@redhat.com wrote:
> The register numbering used by GCC is definitely arbitrary.  I hadn't
> even considered there might be reasons for it not to be, for which I
> apologize.  It's a bit unfortunate that this has come up when we're
> this close to the first GCC release to include the SH5 port.  I'm not
> sure we have enough time to come up with a solution, nor whether Mark
> would accept it in the branch.  It would be too bad if GDB couldn't
> debug code compiled by GCC 3.1.  Perhaps we can come up with a
> backward-compatible register mapping, even if GDB would work in a
> degraded mode when the current register numbering is in use.

I was proposing only to change the SHcompact mapping, so that code
compiled with the default options won't be affected.  Moreover, there
are still a number of bugs in gcc 3.1 that affect the SH5 port, some
of which can only be fixed with changes to the machine-independent sources.
I am working on this, but it is not feasible to finish this work in time
for gcc 3.1 .  Hence, I'd expect some gcc 3.2 snapshots to be better
for SH5 than gcc 3.1 for production code.

Another reason to switch to a post 3.1 compiler will be debugging speed.
The prologue-disassembling slows backtraces considerably when debugging
on real hardware.  We are currently working on SH gcc emitting proper
cfi information, and gdb making use of it.  For SH4 this has already
proved to make quite an improvement, and the gcc bug fixes for this
are among the next patches I intend to put into the FSF gcc repository.

-- 
--------------------------
SuperH
2430 Aztec West / Almondsbury / BRISTOL / BS32 4AQ
T:+44 1454 462330


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