From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from minnie.tuhs.org (minnie.tuhs.org [45.79.103.53]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 48651938 for ; Sat, 8 Feb 2020 21:51:34 +0000 (UTC) Received: by minnie.tuhs.org (Postfix, from userid 112) id B81A69CCBF; Sun, 9 Feb 2020 07:51:32 +1000 (AEST) Received: from minnie.tuhs.org (localhost [127.0.0.1]) by minnie.tuhs.org (Postfix) with ESMTP id 428F39CCAA; Sun, 9 Feb 2020 07:51:03 +1000 (AEST) Authentication-Results: minnie.tuhs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="uQV48y+S"; dkim-atps=neutral Received: by minnie.tuhs.org (Postfix, from userid 112) id 659099CCAA; Sun, 9 Feb 2020 07:51:00 +1000 (AEST) Received: from mail-vs1-f46.google.com (mail-vs1-f46.google.com [209.85.217.46]) by minnie.tuhs.org (Postfix) with ESMTPS id C49C19CCA9; Sun, 9 Feb 2020 07:50:59 +1000 (AEST) Received: by mail-vs1-f46.google.com with SMTP id x123so1847914vsc.2; Sat, 08 Feb 2020 13:50:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Etch49xdJc0bcNYahvGvxF8whW7SX3PrQAK7ydKnymI=; b=uQV48y+SepjpVTBfgC8BXz9EGhilQQWcuQie2Lqwz3yulTXA6M6eRYVE5Ya4Dlypkb 3uctiWP69EV4xHn8MFDjBik1bI8ptDuqmgykJznkf6TTDxdjmVJ88az6h2Eav4Au7wue jswbaQ7mW8UzazwbES8LrTdbiUHQS+uHzqSqhQP4Ptyr1M27S6disHJFdMN73fPYaVBS REjHE13nvRwlk24VmBVT+e/2DxoRwyWLWWNcLxnKgwkRuCGe7/8fCsmloD05LyDsAHfl BPx4VPwbHUQqM3xUxUwsMBFKtw7ZeUU5vNfWgYWllOEg/3E/XjJmaCP0nhf61JW+cwWF ZPDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Etch49xdJc0bcNYahvGvxF8whW7SX3PrQAK7ydKnymI=; b=CtdwoO6Ogz0Zfz+7tDlFw+LHfMXDDaI2dU3eW/z0aAlQZf411KL0NGmumf8QW19a4b 4sBIKJdpVx/WLYQkxRu9xJ+0b9Yv1mryFhDvfBWumu+CP6ziCmgH333Q0WW/8x7NsdoX 8pwwmmJywYp8H1EkjpBvi80m4PKl4zCHqRtxUO6JUVN+VcwyMo7hrCi1gQr6poJkEnWO o3nFg7ycUuXDWIVCq3qjzeE2DYE0lRtvqrqJJmpz28D0lUjyFidn+cLOQSaS7hagX3Lx Vw9WB51MvXuFp37xdyeREt/E1Ivh/n6WXn62u0x6NHoiM887uuXgV6SQMJLZCA+262IW g7Yw== X-Gm-Message-State: APjAAAV2UkhwDSdCfXTLR2tju14xnZYkJXDWJVR2N/tFQfI5N39XMyA4 DERPUrXvi6pIL92itWJKpe4LLJjO7+T1mlHf5Pg= X-Google-Smtp-Source: APXvYqxHJw29zCxF3Egba2C5ZGGsz7pVFapZwj0JryveCBV8OJ1E2bXzJhqTiNXSDKZ35dv/JLG4iliZFQ0cHgBEJQw= X-Received: by 2002:a67:c90d:: with SMTP id w13mr2638825vsk.164.1581198658609; Sat, 08 Feb 2020 13:50:58 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Rob Pike Date: Sun, 9 Feb 2020 08:50:47 +1100 Message-ID: To: Warner Losh Content-Type: multipart/alternative; boundary="0000000000005da8de059e178030" Subject: Re: [TUHS] Warner's Early Unix Presentation X-BeenThere: tuhs@minnie.tuhs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: The Unix Heritage Society mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: The Eunuchs Hysterical Society Errors-To: tuhs-bounces@minnie.tuhs.org Sender: "TUHS" --0000000000005da8de059e178030 Content-Type: text/plain; charset="UTF-8" > > > Yes. I'd only mean that pwb enabled people to start writing real, > non-trivial shell scripts. There's other scripts in the tree prior to > Bourne Shell... There's several 'runit' scripts that look to build things > pre-make. There's also sources to 'goto.c' which implemented 'goto label' > by rewinding stdin until it finds the label then exiting (I presume the > older shell would then start reading again from stdin). Or maybe I've > totally missed the point of s1/goto.c... there's no comments in it. It is a > bit of a stretch, though, you're right. > That's how goto worked, yes. The flow from PWB back to the main research line was a trickle at best. We >> had bad NIH in 1127. >> > > That matches other sources I've seen: bug fixes flowed into research > relatively easily. Performance fixes sometimes (though often not). Some > drivers did. And only the occasional program. It's my belief that this slow > level of flow is why AT&T shifted from the Research line to the Unix/TS > line and merged Unix/TS and PWB into Unix/TS 3.0 (System III was 3.0.1) and > roped other internal lines into Unix/TS 4.0 and/or System V. > I think the SysV/Research split is just another variant of NIH and separate organizations. The development folks did what they did because it helped them (or perhaps just to have fun?). Features in CB Unix bothered us (like the way init worked) and although we were pressured to take them, we resisted. USG was more accommodating. They (USG, Unix Support Group) were just that: a support group, and they were under immense pressure from their users in the Bell System to add features. There was outright mockery from us at how complex stty became, and then the ultimate insult arrived, ioctl. So System V was theirs, managed by them, owned by them. Occasionally we'd go to meetings there to try to convince them to do something differently. I remember a meeting where I tried to talk them out of some truly awful shared memory or IPC thing, but the details are hazy. I'm sure they ignored me anyway; in general they didn't listen to us unless their users were asking for something we had. > I also now wonder if we got the Bourne Shell because of NIH or because > there was some clear technical defect in pwbsh that Steve Bourne was > correcting... There were no env vars before V7, and I haven't looked at the > pwb sh to see how that issue was handled. I'll have to also include the > 'pump' operator in future talks. > Mashey's shell was better than the v6 shell, no question, but it was still pretty clunky and undisciplined. If I remember right, it was a hacked up v6 shell, but I'm not sure. Steve Bourne, who understands formal languages and was (clearly!) a fan of Algol 68, decided a more structured approach was necessary. People malign the look of the code, but his research shell was lovely. For v8 I ripped the IF ELIF macros out; they were just sugar I could scrape off. I put in shell functions, which Steve had wanted to do anyway, made them exportable (fought for that hard at a POSIX meeting, with Ken) and did some cleanups to the printing etc. so it worked well when you cut and paste from the terminal. All that was easy to do because the code was so clean. I learned a lot working on that program. The parser is a jewel. I still think it's a great piece of code, and I miss the v8 shell every day. The GNU "Bourne again" shell is missing all that stuff I did. Unfortunately, Steve's memory allocation trick, mallocking on faults, isn't portable, and I suspect the code will never run on a modern OS. Tom Duff's rc was done as a reaction to the shell being, despite its other glories, still a macro language. But that's another story. -rob --0000000000005da8de059e178030 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Yes. I'd only mean that pwb enabled people to start writing rea= l, non-trivial shell scripts. There's other scripts in the tree prior t= o Bourne Shell...=C2=A0 There's several 'runit' scripts that lo= ok to build things pre-make. There's also sources to 'goto.c' w= hich implemented 'goto label' by rewinding stdin until it finds the= label then exiting (I presume the older shell would then start reading aga= in from stdin). Or maybe I've totally missed the point of s1/goto.c... = there's no comments in it. It is a bit of a stretch, though, you're= right.

That's how go= to worked, yes.

The flow from PWB back = to the main research line was a trickle at best. We had bad NIH in 1127.

That matches other sources I'= ve seen: bug fixes flowed into research relatively easily. Performance fixe= s sometimes (though often not). Some drivers did. And only the occasional p= rogram. It's my belief that this slow level of flow is why AT&T shi= fted from the Research line to the Unix/TS line and merged Unix/TS and PWB = into Unix/TS 3.0 (System III was 3.0.1) and roped other internal lines into= Unix/TS 4.0 and/or System V.

=
I think the SysV/Research split is just another variant of NIH and sep= arate organizations. The development folks did what they did because it hel= ped them (or perhaps just to have fun?). Features in CB Unix bothered us (l= ike the way init worked) and although we were pressured to take them, we re= sisted. USG was more accommodating. They (USG, Unix Support Group) were jus= t that: a support group, and they were under immense pressure from their us= ers in the Bell System to add features. There was outright mockery from us = at how complex stty became, and then the ultimate insult arrived, ioctl. So= System V was theirs, managed by them, owned by them. Occasionally we'd= go to meetings there to try to convince them to do something differently. = I remember a meeting where I tried to talk them out of some truly awful sha= red memory or IPC thing, but the details are hazy. I'm sure they ignore= d me anyway; in general they didn't listen to us unless their users wer= e asking for something we had.
=C2=A0
I also now wonder if we got the Bourne Shell because of NIH or becau= se there was some clear technical defect in pwbsh that Steve Bourne was cor= recting... There were no env vars before V7, and I haven't looked at th= e pwb sh to see how that issue was handled. I'll have to also include t= he 'pump' operator in future talks.

Mashey's shell was better than the v6 shell, no = question, but it was still pretty clunky and undisciplined. If I remember r= ight, it was a hacked up v6 shell, but I'm not sure.

Steve Bourne, who understands formal languages and was (clearly!) a = fan of Algol 68, decided a more structured approach was necessary. People m= align the look of the code, but his research shell was lovely. For v8 I rip= ped the IF ELIF macros out; they were just sugar I could scrape off. I put = in shell functions, which Steve had wanted to do anyway, made them exportab= le (fought for that hard at a POSIX meeting, with Ken) and did some cleanup= s to the printing etc. so it worked well when you cut and paste from the te= rminal. All that was easy to do because the code was so clean. I learned a = lot working on that program. The parser is a jewel. I still think it's = a great piece of code, and I miss the v8 shell every day. The GNU "Bou= rne again" shell is missing all that stuff I did.

=
Unfortunately, Steve's memory allocation trick, mallocking on faul= ts, isn't portable, and I suspect the code will never run on a modern O= S. Tom Duff's rc was done as a reaction to the shell being, despite its= other glories, still a macro language. But that's another story.
=

-rob

--0000000000005da8de059e178030--