It draws 1000 frames and then prints the time taken in jiffies (1/60 sec), which turns out to be about 90 frames/sec. Was pretty fun to port the program and see it whizz by on the screen. It's a lot slower on the C-64 but still fun to watch on that machine too.
Paul's Various Languages for the X16
Posted: Sat Nov 28, 2020 10:58 am
by paulscottrobson
Nice. It's done almost entirely in bytes which probably amounts for most of the difference, everything in AMORAL is words. I did experiment with various ideas, including bytes only languages (there are some) and autoswitching on demand, but it was just too messy ? The only one that worked was an 8 bit FORTH on FRED (the Cosmac Elf prototype sort of) and that machine had only 1k of RAM.
Lean appears to be a bizarre utility for handling 16 bit integers in local compilation. Or something. Quote:
Lean is basically a macroassembler that *only* does macros.
So every action you need is defined as a macro (and some structure, and procedures are provided). So you define your own assembler instructions and register and lean converts it into the target CPU. Lean as implemented chooses something close to the 6502 (e.g. treating XA as a faux 16 bit register) for efficiency. Much of it is 1:1 so y++ maps to iny for example.
Paul's Various Languages for the X16
Posted: Mon Jan 10, 2022 7:50 pm
by TomXP411
On 1/10/2022 at 7:47 AM, paulscottrobson said:
Lean is basically a macroassembler that *only* does macros.
So every action you need is defined as a macro (and some structure, and procedures are provided). So you define your own assembler instructions and register and lean converts it into the target CPU. Lean as implemented chooses something close to the 6502 (e.g. treating XA as a faux 16 bit register) for efficiency. Much of it is 1:1 so y++ maps to iny for example.
I like the idea of a meta-assembler. I've been knocking around a similar idea myself, but just can't find the time for the thousand things I'm trying to learn and do all at the same time.