OCaml running on a 1960s UNIVAC 1219B

Hi!

I’ve been meaning to post a recent-ish project of mine where I ran OCaml (and much more) on a 1960s UNIVAC 1219B! The demo I chose to run was a sudoku solver. In short, this was done by compiling OCaml to C, C to RISC-V, and then emulating RISC-V on the UNIVAC.

Full UNIVAC toolchain: Writeup, and source. Please see the my comment below for the other links! I’m unable to post more than two links in a post.

I also ran an OCaml program submitted by a friend that computed factors of numbers. At one point we thought the program crashed, but we were delighted when the program resumed ~5 minutes later. Turns out garbage collecting is slow on this machine :slight_smile:

Oh, and it works with OxCaml too!

Enjoy! Below are some pictures. (Disregard the earlier output, that was a run of ELIZA :slight_smile:)

13 Likes

OCaml to C: Writeup, and source

4 Likes

Sudoku solver source: OCaml, and compiled to C

4 Likes

Very cool to see OCaml on retro hardware like this!

2 Likes