▲ | PaulHoule 9 days ago | |||||||
The earliest home computers had tiny amounts of memory: my TRS-80 Color Computer started out with 4K of RAM and BASIC in ROM although within a few years I had it filled out with 64K of RAM. There weren't a lot of languages that would fit in 4K, but they included BASIC, FORTH and assembler (like the actual assembler.) [1] My FORTH experience with that was writing a subroutine-threaded FORTH for the 6809 under the OS-9 operating system in about 3000 lines of assembler. I wrote to the Forth Interest Group and they sent me a card which had a list of standard words in FIG FORTH, mine complied with that except that I used the Unix-like system calls from OS-9 for file I/O instead of the block scheme most FORTHs used. [1] The popular 6502 (Apple ][, Atari 400/800, C-64, ...) was particularly weak in support for compiled languages because it had few registers and fewer addressing modes but it was easy to write a FORTH for too. | ||||||||
▲ | satiated_grue 9 days ago | parent [-] | |||||||
The 6502's lack of registers is one point of view. Another point of view is that the zero page provides 256 registers: https://spectrum.ieee.org/q-a-with-co-creator-of-the-6502-pr... "[Bill Mensch]:Rod Orgill and I had completed the designs of a few microprocessors before the 6501/6502. In other words, Rod and I already knew what was successful in an instruction set. And lower cost was key. So we looked at what instructions we really needed. And we figured out how to have addressable registers by using zero page [the first 256 bytes in RAM]. So you can have one byte for the op code and one byte for the address, and [the code is compact and fast]. There are limitations, but compared to other processors, zero page was a big deal." | ||||||||
|