HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
MitchBradley
cforth
C2018–2026
MitchBradley / cforth

cforth

Mitch Bradley's CForth implementation

2Distinct people
19Mentions
0Explicit recommenders
171GitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Mitch Bradley's CForth implementation

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 9–Nov 16 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/16/2026, 12:01:57 AM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year19 dated mentions

Observed mentions: 2018-07-07 20:56:31 UTC to 2026-10-14 05:57:22 UTC.

012342018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments20182019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments20222023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC202
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC303
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC000
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC404
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC000
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC404
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC101
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC303
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC202

What Hacker News says

2 sources
"Recreational Programming" sounds like a fun legal alternative to "Medical Programming" that you don't need a prescription from your doctor to do. I prefer the term "Pleasure Programming", to de-emphasize how addictive it is. >Permission to build useless things. I prefer the term "Ultimate Things", to de-emphasize how useless they are. https://en.wikipedia.org/wiki/Useless_machine >The Italian artist Bruno Munari began building "useless machines" (macchine inutili) in the 1930s. He was a "third generation" Futurist and did not share the first generation's boundless enthusiasm for technology but sought to counter the threats of a world under machine rule by building machines that were artistic and unproductive. >The version of the useless machine that became famous in information theory (basically a box with a simple switch which, when tur
Read the rest
ned "on", causes a hand or lever to appear from inside the box that switches the machine "off" before disappearing inside the box again) appears to have been invented by MIT professor and artificial intelligence pioneer Marvin Minsky, while he was a graduate student at Bell Labs in 1952. Minsky dubbed his invention the "ultimate machine", but this nomenclature did not catch on. The device has also been called the "Leave Me Alone Box". So here's a live demo of an ultimate thing I pleasure programmed: https://hyperties.org/cabinet/ultimate/ What this is: I've been using Claude to recreationally develop a PDP-7 and Type 340 vector graphics display emulator for the web browser, in order to run an early CAD system called PIXIE, which has the first known radial menus, driven by a light pen, developed at Cambridge in the late 1960's, whose 128 pages of PDP-7 assemblxy language source code the author Heinz Lemke scanned and sent me. Once I got it working, I told Mitch Bradley about how much I wanted a Forth system for it. Mitch has written useful things like OpenFirmware and CForth, and I was his summer intern at Sun in 1987, where we had a fun time hacking his CForth into CADroid (a circuit editing system developed at LucasFilms) as an extension language and macro system. https://github.com/MitchBradley/openfirmware https://github.com/MitchBradley/cforth http://www.art.net/~hopkins/Don/lang/forth.html Since then, Mitch developed his Sun Forth system into OpenFirmware for the boot ROMs of systems like the Sparcstation, PowerPC Mac, and the OLPC. So naturally I thought it would be fun to run Forth on the same machine that ran PIXIE, mainly because I'd love to work together and hack Forth with Mitch again after all these years, but also because Forth was the perfect language for the PDP-7. So then Mitch used Claude to whip up a PDP-7 Forth in one day, with Turtle Graphics! https://github.com/MitchBradley/pdp7forth https://hyperties.org/cabinet/forth/ It turns out that the PDP-7 instruction set is ideal for Forth. It has an "XCT" instruction for indirectly executing other instructions, which makes the Forth inner interpreter loop only require 3 instructions. PDP-7 Forth — Mitch Bradley, 26 September 2026: https://github.com/SimHacker/WillWrightShowForFood/blob/main... PDP-7 Forth, by Mitch Bradley: https://github.com/SimHacker/WillWrightShowForFood/blob/main... PDP-7 Forth Source Code, NEXT: The Inner Interpreter: https://github.com/SimHacker/WillWrightShowForFood/blob/main... " --- NEXT: the inner interpreter --- " Only LAC/LAW-tag cells fall through to "dac i 012"; CAL/JMP-tag cells " transfer control elsewhere and never reach it. next: xct i 010 " pre-increment IP, execute the thread cell dac i 012 " push AC (only reached by constant/variable cells) jmp next Now that Forth runs like a bat out of hell, I'm hacking virtual hardware devices for the PDP-7, and controlling and visualizing them with Forth. First I made an "Ultimate Machine" device for the PDP-7, inspired by Claud Shannon and Marvin Minsky, whose only purpose is to turn itself off! https://en.wikipedia.org/wiki/Useless_machine Bruno Munari called it a "Useless Machine", but Minsky was more compassionate, and appreciated its purpose of turning itself off as being ultimately useful, so he renamed it the Ultimate Machine. I think there are some deep implications to the halting problem, but I can't quite put my finger on it the way the Ultimate Machine puts its finger on its own off switch. The Ultimate Machine emulator plugs into the PDP-7 emulator as a virtual device cabinet, which has its own device control IOTs that augment the PDP-7 instruction set. DEC sold a lot of "plug-in instruction sets in a cabinet" like the Type 340 vector graphics display, its light pen, character generator, subroutine executer, advanced math instructions, etc. https://gunkies.org/wiki/Type_340_Precision_Incremental_Disp... The Ultimate Machine device, an emulator of device 56 with its registers, phases and IOTs: https://github.com/SimHacker/WillWrightShowForFood/blob/main... https://github.com/SimHacker/WillWrightShowForFood/blob/main... Then I made a Forth program that draws an animation of the Ultimate Machine on the 340 display, with a switch activated by the light pen. It's not a "simulation" -- it's an actual interactive visual representation of the emulated Ultimate Machine device state that FORTH controls via IOT instructions, the same way it controls the 340 display and light pen! The Forth 340 view, with the IOT words, the hand, lid and lamps, and the light-pen switch, so you can turn it on (and off) with the light pen (check out the tool tips the emulator user interface shows you when you point at the graphics): https://github.com/SimHacker/WillWrightShowForFood/blob/main... Instead of halting there, for even more Turing completeness, I made a Turing Machine device, which is like the 340 display in that it not only adds device control IOT instructions, but also executes its own Turing Machine instructions and tape via DMA from of the same 18-bit core memory as the PDP-7 and 340 display. The 340 display and the Turing Machine are both co-processors that execute their own instructions from the shared 18-bit core memory of the PDP-7, which generates code for them to execute, and controls them via IOT instructions. The Turing Machine device issues an interrupt when its head page faults off the edge of the tape window in core, so the PDP-7 can implement virtual memory to support "infinite" tape. Live Demo: https://hyperties.org/cabinet/turing/ Turing Engine: https://github.com/SimHacker/WillWrightShowForFood/blob/main... Forth => Turing Machine Compiler I made based on Christopher Cherniak's "TM*" courseware from the "Philosophy and Computers" course I took from him in the 1980's: https://github.com/SimHacker/WillWrightShowForFood/blob/main... https://terpconnect.umd.edu/~cherniak/philcomp/ https://terpconnect.umd.edu/~cherniak/PhlCogSci.pdf Ostensibly the real use is for education, but I actually did it because it was fun, and I felt like working with Mitch and programming Forth again. Forth, the 340, and co-processors in one core: what the cabinet teaches: https://github.com/SimHacker/WillWrightShowForFood/blob/main... Here's a demo video that tries to explain it: PIXIE and FORTH on PDP-7 Cabinet Emulator with Type 340 Vector Graphics Display: https://www.youtube.com/watch?v=lo8kdY-5i6c
In Recreational Programming
Good call! (Whether it's a directly threaded, indirectly threaded, subroutine threaded, token threaded, Huffman threaded, or string threaded call.) https://en.wikipedia.org/wiki/Threaded_code#Token_threading Mitch Bradley created OpenFirmware. It started at Sun as OpenBoot (informally "SunForth") on the SPARCstation 1 in 1989, was standardized as IEEE 1275-1994, and was renamed OpenFirmware at that time. Its lineage runs back through Mitch's earlier Forthmacs (Bradley Forthware, early 80s), which ran on 68k Macs, Sun-2/3, Atari ST, and Amiga. Mitch credits Henry Laxen and Michael Perry's F83 and Glen Haydon's MVP-Forth as the public-domain ancestors. The metacompiler can target many platforms, word sizes, CPUs, and threading models, and produce stripped ROMable images. It can build the kernel as direct-threaded (DTC), indirect-threaded (I
Read the rest
TC), subroutine-threaded (STC), or token-threaded (TTC), with 16, 32, or 64 bit cells. Shipping kernels are DTC native code with cell-sized xt pointers: 32 bit on the original SPARC and PowerPC machines, 64 bit on modern PPC64, SPARC64, and ARM64 builds. Peripheral expansion cards ship a separate, portable, variable-byte token format called FCode. The kernel interprets FCode at boot/probe time and recompiles it on the fly into the live native dictionary. After probe, FCode-loaded drivers run as ordinary native Forth words. That two-stage design (fast native runtime, portable FCode transport) is what let Sun ship one card PROM image that worked across CPU generations. https://github.com/MitchBradley https://github.com/MitchBradley/openfirmware FCode was designed for SBus on the SPARCstation 1, with cross-CPU portability built in. Sun's earlier and contemporary buses were not interchangeable with SBus (Sun-2 used Multibus, Sun-3 used VMEbus, the Sun386i "Roadrunner" used AT-bus), so the cross-architecture payoff arrived later, when IEEE 1275-1994 standardized OpenFirmware and PCI allowed FCode in option ROMs. After that, the same expansion-card PROM image could boot on Sun SPARC, Apple PowerPC Macs, IBM PowerPC servers (CHRP), and the OLPC XO. Interview with Mitch Bradley (he's like the Woz of Forth): https://web.archive.org/web/20120118132847/http://howsoftwar... In parallel with the OpenBoot work, Mitch also developed an extremely portable C-based Forth (the public version is "C Forth 93"). It runs a switch-threaded inner interpreter over packed tokens, with configurable cell width (16, 32, or 64 bit) and configurable token width (pointer-sized by default, 16 bit with the T16 build flag for tight flash budgets), plus a small hand-rolled FFI built around a fixed-arity 12-argument marshalling trampoline driven by a format string. It is now the embedded variant used in OLPC's OpenFirmware and in PlatformIO targets including RP2040, Teensy, ESP32, ESP8266, and STM32: https://github.com/MitchBradley/cforth OpenFirmware even has its own song: https://www.youtube.com/watch?v=b8Wyvb9GotM More on Mitch, OpenFirmware, and CForth: https://news.ycombinator.com/item?id=21822840 https://news.ycombinator.com/item?id=33681531 https://news.ycombinator.com/item?id=38689282
In Bytecode VMs in surprising places (2024)

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.