From: Paul Ruizendaal <email@example.com>
To: "firstname.lastname@example.org" <email@example.com>
Subject: [TUHS] Re: when did v8 or later get networking?
Date: Fri, 11 Aug 2023 11:05:21 +0200 [thread overview]
Message-ID: <6EA66356-0C94-4802-81B6-1CF891EF6EC2@planet.nl> (raw)
> Date: Thu, 10 Aug 2023 03:17:25 +0000
> From: segaloco
>>>> TCP/IP, not datakit
> All of the files that have timestamps at the top list 83/07/29, except ip_input.c which has 83/08/16 instead. The V8 version has _device (device driver) and _ld (line discipline) components that the 4.1cBSD code does not have. Many other files have analogs between the two. The byte ordering subroutines have been copied into a file, goo.s, from their home in 4.1cBSD in the C library (/usr/src/lib/libc/net/misc). When this work originated someone else would need to answer, [...]
As far as I can tell the history of this code line goes back to 1977, when Jack Haverty at BBN wrote a TCP/IP library (porting earlier work written in PDP-11 assembler) for a slightly modified 6th Edition Unix. Fighting with 64KB core limits, throughput was horrific and he concluded that a bigger PDP-11 was needed. Mike Wingfield then did a re-implementation in C for a PDP-11/70. This worked in early 1979 and is arguably the first Unix TCP/IP stack that can still interoperate with current IPv4. However, it was still mostly a proof of concept user mode design (it was funded as a test vehicle for the later abandoned Autodin-II fork of TCP).
BBN then got a contract to write a kernel mode TCP/IP stack for 4BSD (“VAX TCP” in the old BBN doc’s). This work was performed by Rob Gurwitz under supervision of Jack Haverty. This stack - although all new code - still showed its heritage: it was designed as a loosely bound kernel process providing the NCP-Unix API. Some sources seem to imply that it was developed first as a user mode process and once working in that context changed into a kernel process / thread. Beta releases were available in 1981. It worked (and interoperates with modern IPv4), but in my experiments a few years back it turned out that it is difficult to get the scheduling for this kernel process right at higher system loads.
Bill Joy of CSRG concluded that the BBN stack did not perform according to his expectations. Note that CSRG was focused on usage over (thick) ethernet links, and BBN was focused on usage over Arpanet and other wide-area networks (with much lower bandwidth, and higher latency and error rates). He then in 1982 rewrote the stack to match the CSRG environment, changing the design to use software interrupts instead of a kernel thread and optimising the code (e.g. checksumming and fast code paths). It was a matter of debate how new the code was, with the extremes being that it was written from scratch using the spec versus it being mostly copied. Looking at it with a nearly 50 year distance, it seems in between: small bits of surviving SCCS suggest CSRG starting with parts of BBN code followed by rapid, massive modification; the end result is quite different but retained the ‘mbuf’ core data structure and a BBN bug (off-by-one for OOB TCP segments).
The shift from the NCP-Unix API to sockets is separate from this and was planned. CSRG had the contract to develop a new API for facilitating distributed systems with Unix and this gelled into the sockets interface. The first prototypes for this were done in 1981.
Nearly all of the above source is available in the TUHS online Unix Tree (Wingfield, VAX-TCP and two early versions from CSRG - one in 2.9BSD and one in 4.1cBSD).
next reply other threads:[~2023-08-11 9:05 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-11 9:05 Paul Ruizendaal [this message]
2023-08-12 5:08 ` Warner Losh
2023-08-12 5:41 ` George Michaelson
2023-08-12 9:06 ` Paul Ruizendaal
2023-08-12 10:29 ` Paul Ruizendaal
2023-08-12 15:20 ` Warner Losh
2023-08-12 15:24 ` Dan Cross
2023-08-12 16:12 ` Paul Ruizendaal
-- strict thread matches above, loose matches on Subject: below --
2023-08-12 15:05 Noel Chiappa
2023-08-12 18:00 ` Paul Ruizendaal
2023-08-10 1:09 [TUHS] " Larry McVoy
2023-08-10 2:38 ` [TUHS] " segaloco via TUHS
2023-08-10 2:45 ` Warner Losh
2023-08-10 3:17 ` segaloco via TUHS
2023-08-10 3:18 ` Rob Pike
2023-08-10 5:44 ` John Cowan
2023-08-10 12:41 ` Douglas McIlroy
2023-08-10 14:00 ` Jonathan Gray
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).