To Home Page
Table of Contents
- Hal Fischbeck to ... - April 12, 2020 - COBOL Compiler on a 4K IBM 1401
- Roberto Sancho Villa to Van Snyder - Mar 14, 2017 - I now have COBOL running well in i1401 simulator.
Hal Fischbeck to ... - April 12, 2020
Subject: Re: COBOL
From: Hal < email@example.com >
Date: Sun, Apr 12, 2020 9:13 am
COBOL Compiler on a 4K IBM 1401 When in technical places like computer repair shops I sometimes remark that I did a COBOL compiler for IBM that ran in 4K. I am starting to get a look like “No way” First, nothing fits in anything that ridiculously small. Then what is a Compiler or COBOL. So I checked Google and found that they verified that such a system did exist. So now I can say “Check it out on Google”.
In 1961 I was moved by IBM from Rochester MN to Endicott, NY. I worked in Programming Systems to develop a program to convert English language COBOL computer programs into internal form that would execute them on the 1401 Computer.
In retrospect the 1401 was dubbed “the Model T of the computer world.” It formed a bridge between the punched card processes and the coming computer world. The goal was to compile COBOL programs on 4K to 16K machines, 4 tape drives and no disc while taking advantage of any additional memory to reduce processing time.
I was responsible for the first phase of the compiler. It read in a COBOL program on punched cards and converted it into an internal format for later compiler phases to process. It included establishing Data tables, producing error messages, and converting commands into internal symbols meaningful to following phases.
To meet those specifications I developed an internal programming language to process the input stream. It ran on a “virtual computer” that performed the need steps. Each COBOL statement syntax processing was encoded and included in a table. The Virtual Computer processed the input stream using the tables. The table size varied by memory size and smaller machines required repeated tape to tape passes to complete processing of all statements.
I am sorry but after 58 years I can’t remember what I called the language or specific commands and Gerry Fuller, it’s only programmer has passed on. However the command set would include commands like Getnext, Dataname, puterror”….”, IfkeywordGo”…”, or setswitch.
This same process was used later on the follow on 360 COBOL D compiler.
Roberto to Van Snyder - Mar 14, 2017 - I now have COBOL running well in i1401 simulator.Subject: RE: IBM 1401 COBOL - now running From: "Sancho Villa, Roberto" < firstname.lastname@example.org > Date: Tue, Mar 14, 2017 7:23 am To: W Van Snyder
, "email@example.com" Cc: Robert Garner , "Stan Paddock, " Hi Van Thanks to your help I now have COBOL running well in i1401 simulator. I send you the results. There are fully automated ready to run scripts that - generates the compiler and Autocode tape from IBM distribution tape - compiles and runs a little Hello World program Just drop the i1401 executable and run the .bat file Please feel free to post any file(s) in your site so it can help anyone to taste COBOL in an easy way. Best regards Roberto i1401-Cobol.zip i1401-Cobol-Generation.zip
From: W Van Snyder < firstname.lastname@example.org > Date: Thu, Feb 23, 2017 12:34 pm To: email@example.com Cc: "Sancho Villa, Roberto" < firstname.lastname@example.org >, Robert Garner
, "Stan Paddock, " On Thu, 2017-02-23 at 04:14 -0700, email@example.com wrote: > Sorry - back to COBOL - I think it would be fun to be able to compile > and run real (probably small and not fully featured) COBOL. It > would be interesting if the SORT verb in COBOL is coded and > working ;-)) (Maybe it makes control cards for SORT7 instead ??? ) > > Anyway, let us know how you are doing, and maybe someone else can > be helpful. I am happy to post your COBOL efforts and code and > results :-)) This might interest other people into your COBOL > effort. I have the 1401 COBOL distribution "tape" number adc00223 from Paul Pierce. It includes source code for the compiler. I have another Cobol directory but I don't remember why. The contents of both directories are attached, as just a pile of disorganized stuff. Sorry for not sorting it out today. 1401 COBOL didn't have the SORT verb. I had programs as big as 1000 cards. These took 40 minutes to compile on a 360\30 with its newer faster-than-729 tape drives, running 1401 microcode, and much longer on a real 1401 with 7330 tape drives. The compiler produced Autocoder, which took another 20 minutes to assemble. The generated code was remarkably good. COBOL pictures mapped trivially to edit masks. It was interesting how it catered for PERFORM. Each paragraph began with an SBR that stored the address of the next paragraph in the last instruction of the paragraph. PERFORM was done by the usual subroutine-linkage method of storing the return address there instead. So a paragraph typically began something like fallin sbr exit&3,nextp b *&4 perfin sbr exit&3 where PERFORM would branch to PERFIN and falling in from the previous paragraph landed at FALLIN. Van [ the two .zip files that were attached to this e-mail have been expanded into the following directory pictures/000COBOL ]
From: "Sancho Villa, Roberto" < firstname.lastname@example.org > Date: Wed, Feb 22, 2017 11:13 am To: Robert Garner
Cc: ... Hi Everybody I don't know how to reach Suzanhud. I've tried to post a comment on the blog but it is not working. Maybe it is a Unicode issue with my Win7 and the Korean language blog server. I'm just beginning with old IBMs, so not enough knowledge of assembler to be able to figure out what is the problem. But the fact is that COBOL compiler is working, so the issue maybe is not hard to fix by someone with experience on the 1401. The problem id that SimH stops on: Unimplemented instruction, IS: 761 (DCW @0|99@), related to the presence of DISPLAY verb. Best regards Roberto
From: Robert Garner < email@example.com > Date: Wed, Feb 22, 2017 10:35 am To: "Sancho Villa, Roberto" < firstname.lastname@example.org > Cc: ... Roberto, It�s great that someone ("Suzanhud�) is running the recovered COBOL tape in SimH! Do you know how to reach/communicate with �Suzanhud�? > I�ve searched on the site, found some references on COBOL, but nothing about > running it on real HW or SimH Have you tried running/debugging with ROPE? http://ibm-1401.info/1401SoftwDevel.html#Intro - Robert p.s. The COBOL tape was part of the 1401 system recovered from a home in Darien, Connecticut that Paul Pierce later graciously read-in and posted on-line.
From Suzanhud�s blog posting: > 2016?09?03? > IBM1401 COBOL (on Tape) Summary > I tryed to post to the IBM 1401 Software Discussions ML. > But I can't post the message. > So I wrote this page. > My english is very poor, sorry(^^; > ---------- > Hi IBM1401 Fans. > > http://ibm-1401.info/PPierceMirror/adc00223.bcd is a COBOL (on Tape) > VER 2 MOD 11 distribution tape image. > So you can make a operational COBOL compiler tape image from the bcd image. > I tryed to make it that can execute with simh emulator and made a simh compiler > tape image from the above bcd image with some patch that is available from > the following site. > http://blog.livedoor.jp/suzanhud/IBM1401/COBOL/cobol.zip > > It's have some limitations. > > 1. PERFORM verb does not work at Compilation. > 2. DISPLAY verb does not work at Runtime. > 3. Exponentiation expression does not work at Runtime. > and more !? > > You must place COBOL subroutines in the Autocoder Library. > My updated Autocoder is available from the following site > http://blog.livedoor.jp/suzanhud/IBM1401/COBOL/autocoder.cobol.tap.zip > > The following is a sample COBOL listing and simh commands. > > Enjoy it!
> On Feb 22, 2017, at 2:04 AM, Sancho Villa, Roberto < email@example.com > wrote: > > Hi > > I�m Roberto, an old computers fan. > Great Web on IBM 1401. I�ve discovered this machine with SimH. > > Did you aware on this page? http://blog.livedoor.jp/suzanhud/ > It has references for running COBOL and FORTRAN IV. > > Nevertheless COBOL�s DISPLAY verb is not working. COBOL compiler generates > an Autocode program, that in turn compiles Ok, but does not runs so well. > > Maybe someone on the i1401 interest group could find fun/interesting/worthwhile > to make this compiler works again. I�ve searched on the site, found some > references on COBOL, but nothing about running it on real HW or SimH > > All my stuff/progresses on SimH available on demand. > > Best regards > Roberto >