I’ve been spending a lot of my research time playing with my PIDP8. This is a replica of the PDP8 (slightly smaller form factor) complete with blinking lights and operational switches, but using a Raspberry Pi as the processing engine. The actual simulation of the PDP8 is handled by Simh, a remarkable ‘ancient tech’ simulation package.
I’ve been resurrecting all my old Engineering grad school FORTRAN programs and getting them to compile and run on the PiDP8. It’s been a blast!
The PiDP8 runs OS8 as the nominal operating system, and the version of FORTRAN IV available is quite old and a bit quirky. The limits include no double precision, no lower case (at all!), strict adherence to column placement of code and strict 6 character limits on both file names (OS8) and variable names (FORTRAN IV). The quirks come when these limits are violated. Sometimes you get a compile error, sometimes a run-time error, but some times nothing except a hung program. As they say, “the lights are flashing, but no-one’s home”.
Some quick examples. Although there’s no double precision, the compiler accepts “DABS” and “DEXP” library function calls. No error messages anywhere, but the program will just hang waiting for the non-existent library. Using too-long variable names results in compiler error messages that have no apparent meaning until you ‘fine tooth’ the code and realize a variable name is longer than 6.
FORTRAN IV also does not allow free-format read & writes. “read(5,,end=9999,err=9999) x,y,z” is just full of not-allowed stuff. You need a proper format statement for every read & write.
In the end it took quite a while to get all of my programs running; around 35 in total. These include various matrix solvers, mass transfer and heat transfer programs, wellbore programs and flash calculations. As I said, much fun.
There were some differences in output between the original 1980’s runs (on a Honeywell MULTICS system), runs on a modern 64 bit PC running the GNU fortran compiler (f77) and the 12-bit PiDP8. However, with the exception of a couple of programs that I have not had time to scrutinize, all results were well within expected ranges given the differences in word size for single-precision calculations. The two cases that were substantially different were cases where the original program was double-precision on a 32-bit machine and convergence of the iterative solution was difficult, even in the original cases.