The 6502 is somewhat famously a hard target for the C language, and KickC does quite well at producing good results in spite of this. The C language is heavily based around pointers and stack usage. The 6502 has a minimal hardware stack: 256 bytes with no stack-relative addressing. So a "stack frame" is an alien concept that requires slow workarounds to emulate. And the 6502 only has pointers in the form of words stored in the first 256 bytes of RAM ("zero page") and also requires the use of one of the three registers to dereference.
Heh, the repo comes with the cruncher plugins I once hacked up for Kick Assembler. Cool!<p><a href="https://gitlab.com/camelot/kickc/-/tree/master/repo/se/triad/kickass/kickass-cruncher-plugins?ref_type=heads" rel="nofollow">https://gitlab.com/camelot/kickc/-/tree/master/repo/se/triad...</a>