In 1993 Urban Müller invented a Turing tarpit programming language for which he created a tiny 240 byte compiler for the Amiga.
This repo collects some basic utilities, written in bf, for working with the original bfc
compiler and its compiled output.
- m68kd.bf decompiler: Takes an AmigaOS 2.0 executable generated by Urban Müller's original 240 byte bf compiler
bfc
and decompiles it back into bf source. - gengen.bf generator: Takes a text (NULL terminated binary) or AmigaOS 2.0 executable file as input and outputs bf code to reproduce those bytes as output.
- gen_bfc.bf
bfc
generator: Generated bygengen.bf
. Outputs thebfc
compiler AmigaOS executable. It compiles to 41,120 bytes usingbfc
, which is greater than its 32KCODSIZE
limit and therefore overlaps the memory tape. Thegengen.bf
algorithm aligns it so the single utilised memory cell falls on an already NULL byte, which doesn't cause the program to crash despite the instruction pointer having to cross the tape and adjacent cells to read the full program.
Assumes 8-bit wrapping cells. Tested using Urban Müller's 240 byte bf compiler bfc
running under vamos (virtual AmigaOS runtime) on Linux.
Another feature of this repo is its AmiNet and bf CI github workflow.
To test functionality, the workflow downloads bfc
from AmiNet (it's still there!), and uses that in conjunction with the vamos Amiga emulator to compile and run bf code and check the results are as expected.
- Original AmiNet bf distribution.
- AmiTools, Python based tools for running AmigaOS executables on other platforms.