Just wanted to drive by and toss this out there:
https://llvm-mos.org/wiki/Welcome
https://github.com/llvm-mos
I've been poking around on the beginnings of a game, something I wish I'd known enough to be able to do 35 years ago... I was using KickC, which is very cool, but I was running into too many issues and starting to spend more time on workarounds than on programming. Then, yesterday, I found out that there's an actively developed and complete 6502 backend for LLVM, which means you can do pretty much anything the LLVM frontends can do and then spit it out to your 6502. Library support may be challenging, of course. As of today, only the C64 (and Atari 800) has linker target files, but I've played with them (they're compatible with GCC ld linker scripts) and it shouldn't be too hard to create new ones for other targets. If you follow that link, you'll see that they've built programs for VIC-20, Apple IIe, C64, and even built a simple Rust program onto an Atari 800. Creating target files for the X16 shouldn't be particularly difficult.
That having been said, don't expect any of the IO (printf, gets, files) to magically work out of the box today. This is in _ACTIVE_ development, and their focus is currently on C64. The backend 6502 codegen passes all LLVM unit tests (a few thousand), and that was announced in a post from just a few days ago.
But if you're willing to just hammer the hardware with your own routines, well, it's pretty slick. I haven't gotten around to X16 programming yet, but I wanted to attach a screenshot of what I've been working on as compiled by LLVM-MOS's clang compiler for the C64. I've been building the project to cross compile for the PET, VIC-20, C64, and C128 with different graphics on each, so I should probably just add an X16 target ?
![hexgame.png](<fileStore.core_Attachment>/monthly_2021_06/hexgame.thumb.png.69feb7dd4a482693c103a9cc8ccf5680.png)