Am 08.01.2018 um 22:28 schrieb Vaclav Peroutka:
> Hello,
> 
> I found following page https://stm8-binutils-gdb.sourceforge.io/ stating
> that patch for SDCC 3.6.0 is necessary.
> 
> "SDCC already had a back end for stm8. Unfortunately not so much
> debugging info although most of the debugging code was already
> available. However it is still lacking dwarf CFI (call frame info) so
> sdcc hade to be patched to use a frame pointer to assist gdb unwinding
> the stack. The soft frame pointer register is enabled with the --debug
> and --out-fmt-elf option. The sdlk linker was updated to supply proper
> entry point address in the ELF header. The startup code now also
> includes initialization of the stackpointer."
> 
> I just downloaded new SDCC snapshot which is version 3.6.9. Are those
> abovementioned patches already included ?
> 
> Vaclav

No. I worked with the author of those patches to make an improved
version (that has proper CFI and does not need a soft frame pointer any
more, and also can display local variables correctly in more - but still
not all - cases). This improved version is included in current SDCC.
However it also requires newer versions of the patches to binutils and
OpenOCD.

So if you want the setup as currently documented at
https://stm8-binutils-gdb.sourceforge.io/ you'll have to use SDCC 3.6.0
with the patches there for the versions of binutils/gdb and OpenOCD
documented there.

If you want the current bleeding edge, you use the current development
version of SDCC with the new patches to binutils (and a corresponding
binutils version) and the current development version of OpenOCD with
the new patches (http://openocd.zylin.com/3952 and
http://openocd.zylin.com/4265).

I assume that the documentation
https://stm8-binutils-gdb.sourceforge.io/ will get updated after the
SDCC 3.7.0 release, and hope that OpenOCD will merge the patches before
their next release. That would make the use of STM8 debugging
considerably easier: One could use out-of-the box SDCC and OpenOCD and
would only need a custom gdb.

Philipp

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to