[TUHS] mental architecture models, Anyone ever heard of teaching a case study of Initial Unix?

arnold at skeeve.com arnold at skeeve.com
Sun Jul 7 15:33:23 AEST 2024


"John Levine" <johnl at taugh.com> wrote:

> These days we write code and compile it for x64 or ARM or RISC-V and
> for the most part, it just works because the data formats and addressing
> are all the same.

I have to agree with this. My experience is that for most[1] user level
code, the architecture simply doesn't matter. I started working on gawk
on vaxen, moved to MC68010, then to Sparc, then to 32-bit x86, then to
64-bit x86, with a side segue to 32-bit PPC.  Other people compile it
on everything else: ARM, S/390, Alpha, Itanium, RISC-V, you name it. OS
differences matter more than architecutre differences.

This list's membership is heavily weighted with compiler writers and
OS porters, which is fine, but that's a very small percentage of the
number of people out in the world writing code. Those folks (including
me in my $DAYJOB) all work in C++, Java, Python, Rust, and Go, and the
architecture simply doesn't matter to them. (C# is nominally portable
as well, but hasn't caught on outside of Windows like the others.)

I *do* think that studying a nice architecture, like the PDP-11,
is important for people learning software development. In college I
took data structures and algorithms together with PDP-11 assembler,
and it was only when I saw how recursion worked in assembler with
the stack that I finally understood it. It was a real epiphany.

My two cents,

Arnold

[1] Architecture does come into play if you're writing _binary_
data, which is why RPC/XDR were invented for NFS and why Google
has it's RPC language and libraries.


More information about the TUHS mailing list