Philipp Klaus Krause schreef op 2021-07-17 07:43:
Am 17.07.21 um 00:38 schrieb Alan Cox:
On Fri, 16 Jul 2021 09:49:59 +0200
Philipp Klaus Krause <p...@spth.de> wrote:
For the Z80, many different calling conventions exist.
Recently, SDCC introduced keywords __raisonance, __cosmic, __iar for
the
stm8 port, that can be used to mark an individual function to use the
calling convention of the Raisonance, Cosmic or IAR compiler.
For Z80, we already have __smallc, which was introduced to allow
calling
functions originally written in assembler for Small-C.
Would it be useful if z80 and related ports would support more such
conventions, e.g. for BDS C, Aztex C, IAR, Dynamic C, Hi-Tech, Cross
C
or another C compiler for Z80/Z180/Rabbit?
Do you plan to also support linking with object modules from those
compilers ? If not I can't see a use case at all. [...]
When __smallc was introduced due to user demand, the use case was
calling asm code originally written for Small-C from SDCC-generated C
code.
With recent work on calling conventions, it could be relatively easy to
support some further foreign calling conventions, the way we support
__smallc. [...]
Philipp
I suppose the use case could be function pointers to existing code in
ROM.
Maarten
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user