The way I handled things for inline assembly was to simply force use of
the old calling convention when being compiled with newer SDCC versions.
I simply define a faux function attribute depending on whether the
aforementioned __SDCCCALL define is present; if it is, 4.2.0+ is being
used, so force call ABI version 0; otherwise do nothing.
#if defined(__SDCCCALL) && __SDCCCALL != 0
#define __stack_args __sdcccall(0)
#else
#define __stack_args
#endif
extern uint8_t some_asm_function(uint8_t foo, uint8_t bar) __naked
__stack_args;
Obviously, if you actually want to use the new calling convention, then
this doesn't help, but I thought this approach was the most expedient
for getting existing inline assembly code compiling with 4.2.0+.
Regards,
Basil Hussain
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user