/Conways-Squasher-Coroutine

Reimplementation of Conway's asterisk squasher coroutine in modern assembly.

Primary LanguageAssemblyOtherNOASSERTION

Conway's Squasher Coroutine

According to Donald Knuth, Melvin E. Conway coined the term coroutine in 1958 when he applied it to the construction of an assembly program. He first published it 1963 in his paper Design of separable transition-diagram compiler (local copy). The paper introduces the coroutine together with its implementation in assembly for the Burroughs model 220, a late vacuum-tube computer.

This is a reimplementation of Conway's code example, the asterisk squasher subroutine, in modern assembly. Read my analysis of the code for more explanations.

See also the follow-up blog post by Dmitry with 64-bit assembler and Kotlin.

General Setup

  • GNU make to run build script
  • NASM to compile
  • a linker
  • Smoke to run tests

Setup Windows

Setup Linux

License

BSD License, see LICENSE.txt in repository.