SPITBOL Featured in “This 70-Year-Old Programmer Is Preserving an Ancient Coding Language on GitHub”

Jordan Pearson has written an article for Vice’s Motherboard site about my work on SPITBOL:
“This 70-Year-Old Programmer Is Preserving an Ancient Coding Language on GitHub”

It makes reference to an article about SPITBOL that appeared on Hacker News a couple of weeks ago: Hacker News.

SPITBOL 360 Now Available

The original implementation of SPITBOL, for the IBM 360, has been available in source form under the GPL license since 2001, from www.snobol4.com/spitbol360.

The SPITBOL Project has just republished these files in a GIT repository: github.com/spitbol/360

With the publication of this version, the source for implementations of SPITBOL produced over a period of over forty years, for the IBM/360 mainframe, MS-DOS for 8088 through Pentium chips, unix for i386, and unix and osx for x64 (amd64), are all now available from github.com/spitbol.

SPITBOL 88 Now Available in Binary and Source Form

Mark Emmer kindly provided the source for SPITBOL 88 soon after we posted SPITBOL 88 in binary form, so both forms are now available:


SPITBOL 88 Binary Distribution, executable binaries, along with documentation,  test and demonstration programs,


SPITBOL 88 Source Distribution, executable binaries, along with documentation,  test and demonstration programs, This version also includes all source files needed to build the system.

SPITBOL-88 Now Available

The SPITBOL project is pleased to announce the availability of SPITBOL-88.

This is a “micro” version of SPITBOL-386 with all its functionality but with a much reduced memory capability.

It generates EXE files and is useful in situations where you wish to distribute a program that is capable of running on all MS-DOS platforms, from 8088 through Pentium.

The files were supplied by Mark Emmer, proprietor of Catspaw, Inc, in the form of the file SPIT88.ZIP, with file dates from the early 1990’s.

The program source for this version of SPITBOL is not available. Only executables are provided to compile and execute SPITBOL programs.

Demonstration and sample programs are included, licensed using a two-clause BSD license.

SPITBOL for OSX is now available

The SPITBOL project is pleased to announce that an implementation for OSX is now available, and can be found at github.com/spitbol/spitbol.

SPITBOL now supports the use of the gas (GNU as) assembler to translate the MINIMAL source code. This is now the default translator used for Unix and OSX.

Executable binaries:

./bin/sbl_osx OSX SPITBOL (64 bits)

./bin/sbl_unix Unix version (64 bits)

./bin/sbl_unix_32 Unix version (32 bits)


./docs/green-book.pdf The SNOBOL4 Programming Language, Griswold, et. al.

./docs/spitbol-manual.pdf SPITBOL User Manual, Emmer and Quillen

./demos demonstration programs from the SPITBOL User Manual

SPITBOL is licensed under the GPL (v2 or later) license. All code needed to build the system is included in this repository.

To build spitbol (./sbl):


make osx

make test_osx

make unix

make test_unix
See readme.txt for instructions on interpreting the test output.

SPITBOL file suffix .sbl now allowed: In Memory of Anthony P. “Tony” McCann

The original version of Macro SPITBOL, created in the early 1970’s, was the joint work of Robert B. K. Dewar and Anthony P. “Tony” McCann.

At Robert’s suggestion, I spent two weeks in March 1976 in Leeds, England, where Tony was a professor at the University of Leeds, to learn more about Macro SPITBOL, mainly to see if we could apply some its technology to help in porting SETL to new machines. I was accompanied by my wife Karin and daughter Alison.

Tony and his wife Olga were wonderful hosts.

Working with Tony was a memorable experience. He was a very modest and soft-spoken gentleman.

As long as I can remember, the default extension for SPITBOL source files has been “spt,” pronounced, as one might guess, as “spit.”

Tony preferred the extension “sbl”, pronounced like the name “sibyl.” (I just looked up the meaning of ‘sybil’ and learned that it means “a woman in ancient times supposed to utter the oracles and prophecies of a god.”

Soon after I started working on SPITBOL in 2009, I was able to track down Tony’s email address, and received the following letter in reply in May, 2009:

Hi dave,

I am still living where I was when you visited Leeds all those years ago, when SPITBOL was still a new and needy product! However Olga my wife died from a heart attack 6 weeks ago so I am planning to sell and move next summer to the nearby village of Menston where two of my daughters and their families live.

I have been retired for 7 or 8 years from the software company with which I worked after leaving Leeds University in 1988 – I wanted to program for the last part of my working career rather than be a senior departmental administrator and it all turned out very well.

I hope you are well and presume that you may have reached retirement or thereabouts.

All the best

I learned not long after from Tony’s son that Tony had passed away.

He was a wonderful man, just wonderful.

I have just extended SPITBOL so that the suffix ‘sbl’ can also be used for SPITBOL source files.

From now on, whenever I run an existing SPITBOL program, or write a new one with the suffix “sbl,” I hope that will remind me of Tony.

If you have read this post, I hope you will be so reminded.

Anthony P. “Tony” McCann: May his Memory be a Blessing.”

Preprocessor in Fifty Lines of SPITBOL

As part of the conversion of SPITBOl to generate gnu assembler (gas) instead of NASM format, I learned that the GAS assembler is less powerful than that of NASM. For example, in NASM I could
use ‘define’ to map a register name to ‘eax’ in 32-bit mode, or ‘rax’ in 64-bit mode.

No problemo … SPITBOL to the rescue.

Here is the simple preprocessor I wrote in about twenty minutes:

*	rename registers according to word size

	target = host(0)
	target break('_') . os "_" rem . ws

	prefix = (eq(ws,32) '%e', '%r')

	word = (eq(ws,32) 'dword','qword')
	defines = 'M_WORD ' word ' '
	defines = defines 'D_WORD' ' ' (eq(ws,32) '.long', '.quad') ' '

	define('a(ref)')			:(a.end)
a	ident(os,"osx")				:s(a.err)
	a = '[' ref ']' 			:(return)

	define('m(ref)')			:(m.end)
m	ident(os,"osx")				:s(m.err)
	m = (eq(ws,32) 'd', 'q') 'word ptr ' ref ']' :(return)

	rmap = table(20)

	s = 'XLsiXRdiXSspXTsiWAcxWBbxWCdxW0axIAbp'
rinit	s len(2) . min  len(2) . reg = 		:f(rdone)
	rmap[min] = reg				:(rinit)
	rpat =  'IA' | ('X' any('LRST')) | ('W' any('ABC0')) 

	line = input				:f(end)

aloop	line breakx('A') . first 'A(' bal . ref ')' rem . last = first a(ref) last	:s(mloop)
	defs = defines

	defs break(' ') . key ' ' break(' ') . val ' ' =	:f(mloop)
dloop.1	line key = val				:s(dloop.1)f(dloop)

mloop	line breakx('M') . first 'M(' bal . ref ')' rem . last = first m(ref) last	:s(mloop)

rloop 	line rpat . reg = prefix rmap[reg]	:s(rloop)
	output = line				:(next)
err	output = 'error '

SPITBOL Status Report: NASM to GAS conversion complete

The conversion of asm.spt to generate gnu assembler (gas) code instead of nasm format is complete.

For those who know of such matters, I now generate att syntax, as it’s easier to generate from a program than intel syntax.

A few hours ago I finally got a compile with no errors, so I could run the executable.

It’s still dying early on. The good news is that with the use of gas I can now use ‘-g’ for debugging and get useful information from the ‘ddd’ debugger.

Simply put, I have debugging resources at hand that should suffice, so it’s just a matter of slogging along until its done. I don’t think it’ll take that long.

If you want to follow the details, or track my work, checkout branch ‘gas’.

I’ll keep you posted.

  • Pages

  • October 2015
    M T W T F S S
    « Sep    
  • RSS The Wayward Word Press

  • Recent Comments

    Daniel Boulet on SPITBOL for OSX is now av…
    Clay on On being the maintainer, sole…
    daveshields on On being the maintainer, sole…
    daveshields on On being the maintainer, sole…
    daveshields on On being the maintainer, sole…
  • Archives

  • Blog Stats

  • Top Posts

  • Top Rated

  • Recent Posts

  • Archives

  • Top Rated