4 ms·
It's very easy to bootstrap and can be made Turing-incomplete if needed. Bitcoin script is a Forth IIRC.
by qsort 5y ago
It's very easy to bootstrap and can be made Turing-incomplete if needed. Bitcoin script is a Forth IIRC.
- whartung 5y agoSpeaking of this, I've always loved this paper [1] about Forth. And it's a real eye opener. It's a real eye opener when you understand that primitives such as assignment and variable references are, indeed, in Forth, actual primitives. Primitives that can be readily changed. Combine this with a venerable Forth (cross)assembler and it's pretty powerful for all of its simplicity. This is bootstrapping without even a boot, just need a sniglet. [1] https://pygmy.utoh.org/3ins4th.html https://pygmy.utoh.org/3ins4th.html
- rbanffy 5y ago> It's very easy to bootstrap Indeed. In college, I designed a stack based CPU that made it trivially easy to build a Forth compiler for it. It also had registers, because I started with a register based design, but the microcode fleshed out stack based instructions and the registers were mostly for storing data outside the stack.
- RodgerTheGreat 5y agoChuck is quite fond of indexing registers on his forth machines; they make operations like memory copies much less messy than exclusively keeping state on the parameter stack.