作者: Bruce.
日時: 2008/3/17(00:02)
Bruce. です。

PLNews経由で知ったのですが、CDC 6000というコンピュータ向けの(たぶん最初
の)Pascalコンパイラの
ソースコードが公開されたようです。
ただしプリントアウトされたものをスキャンしたpdfデータです。

http://www.standardpascal.org/CDC6000_Pascal_Compiler_Pascal.pdf


Though the existence of CDC/Cray computer history presentation projects
on the web, we can now display several scans and other material from the
original CDC 6000 Pascal compiler, the first Pascal compiler in existence.

The following listings were scanned from listings provided by Mr. John
Dykstra.

Main compiler code in Pascal

Runtime library code in Pascal

Runtime library code in Compass, the CDC 6000 assembly language

An error translation routine

The compiler listing is dated 1976. The scans were taken from a greenbar
listing direct from a CDC 6000 series computer, and bear some unique
features to such a listing. The name and line number appears at the
right of the listing. Because the listings were wider than a 8 1/2 inch
sheet of paper, the limit of my scanner, the line numbers to the right
have one or more digits cut off. The listings have a 6 digit page number
stamped on them at the upper left, which was done by me with an
incrementing stamp. This was done so that I would have a positive
indication of the page number while performing the automatic feed scan.
(以下略)

ページ数で言うと80ページちょっとですのでボリュームとしてはたいしたことは
ないですが、いかんせん画像としてスキャンされているpdfなので読みやすいとは
いえないかもしれません。

ざっと眺めてみたのですが、中間言語コードを吐いているのかどうかは
ちょっとわかりませんでした。CDC 6000のアーキテクチャがわかれば判別
しやすいのでしょうけど。
#レジスタ割り当てでごにょごにょやってればまず確実にネイティブコード出力


The layout of the compiler is similar to the P4 project, which is not an
accident. The P4 system was derived from this compiler.

P4の元になったというと中間言語出力っぽいですが。

時間を見つけて読み進めて何かあったらまた書きます。


-- 
木村浩一/KIMURA Koichi
 I thought what I'd do was, I'd pretend I was one of those deaf-mutes or
shoud I?
 mail kbk at kt.rim.or.jp
 web  www.kt.rim.or.jp/~kbk/zakkicho/index.html