Dear Raphael, dear SDCC developers,
since SDCC revision 5531 I am not able to compile a stable version of
my pic webserver project any more. Attached you can find a tar file
containing all assembler output and listings of a minimal subpart of
my project to help you find the possible bug.
In subdirectory r5530 you can find the listings of the last usable
In subdirectory r5882 you can find the listings of the broken hex file
Also included is a diff file showing the differences of main.asm
My assembler-knowledge of pic16 is very low, but I think there is
something wrong with pointers. "debug.log" shows some output:
r5882-compiled project is unstable and reboots after some seconds of
run time. r5530-compiled project is running properly as expected.
Hope you can help me.
> Also included is a diff file showing the differences of main.asm
Very helpful indeed.
> [...] I think there is something wrong with pointers.
The problem is probably the introduction of UPPER(_ResolveMac_search_1_1)
(which returns the third, most significant byte of the address of symbol,
which in turn is almost inevitably 0x00) instead of the hard-coded 0x80
(which signifies __data space in PIC16 generic pointers; 0x00 would point
to __code space ...). I guess the behaviour changed after some
modification to the CAST operator down below in the AST, but could not
pinpoint the source (or fix it).
I am busy dealing with my PhD thesis, so I will probably not be able to
dig into this any time soon :-(
If anyone wants to help -- you are very welcome.