From owner-freebsd-questions@FreeBSD.ORG Tue Jun 13 10:21:37 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 81E9116A46F for ; Tue, 13 Jun 2006 10:21:37 +0000 (UTC) (envelope-from bqt@update.uu.se) Received: from GW.SoftJAR.SE (205.225.216.81.static.spa.vf.siwnet.net [81.216.225.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9657E43D6A for ; Tue, 13 Jun 2006 10:21:33 +0000 (GMT) (envelope-from bqt@update.uu.se) Received: from [10.0.0.13] (213-65-173-246-no96.tbcn.telia.com [213.65.173.246]) by GW.SoftJAR.SE (Postfix) with ESMTP id B48E26274E; Tue, 13 Jun 2006 12:21:32 +0200 (CEST) Message-ID: <448E91A8.4040809@update.uu.se> Date: Tue, 13 Jun 2006 12:21:28 +0200 From: Johnny Billquist Organization: Update Computer Club User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Marcus Watts References: <200606130645.CAA16535@quince.ifs.umich.edu> In-Reply-To: <200606130645.CAA16535@quince.ifs.umich.edu> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Tue, 13 Jun 2006 11:50:51 +0000 Cc: =?ISO-8859-1?Q?H=E1morszky_Bal=E1?=, John Nemeth , misc@openbsd.org, Otto Moerbeek , Ted Unangst , Ted Mittelstaedt , freebsd-questions@freebsd.org, =?ISO-8859-1?Q?zs?= , netbsd-users@NetBSD.org, Nikolas Britton Subject: Re: wikipedia article X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Jun 2006 10:21:37 -0000 Marcus Watts wrote: > Various wrote: > >>From: Otto Moerbeek >>To: Ted Mittelstaedt > > ... > >>What's more, iirc the MMU of the pdp11 isn't what we call a MMU today, >>it could not even do paging. > > The pdp-11 mmu could handle program relocation, segmentation (after > a fashion) and memory protection. I'm not sure what more you > could expect from an mmu. What you mean by "paging" is > probably "demand paging", which means the ability to run a program > without requiring that it be entirely resident. The key > feature you need for that is a guarantee that any instruction fault > caused by missing memory can be either restarted or continued. > In most architectures that's a question of cpu design not mmu. True. But it's mostly a combination of MMU and CPU. The MMU needs to either abort or trap the offending instruction, and the CPU needs to know how much side effects had been done so that they can be undone before a restart. The PDP-11 MMU can either abort the instruction, or do a trap after the instruction completes. The CPU have a register telling of register modifications done, as well as the pre-fetch PC. In additions to this, the MMU have both an expansion direction, a modified bit, and an accessed bit. And that is in addition to the protection field and size field of the page (and the address relocation). So I can't really imagine anything that you cannot do with the PDP-11 MMU. Heck, there is even the funny "bypass cache" bit. Useful for multiprocessor systems... Since the PDP-11 have a different page table for I- and D-space, you can even have execute-only pages. > In the case of the pdp-11 that's mostly a moot point. The pdp-11 only > provides for mapping the 64k of memory space into into 8 segments > (addressable on 64-byte "clicks") and there's just not much win to > demand paging 8 "pages". (actually 6 x 8 pages; there was kernel, > user, and supervisor mode, & each had separate instruction and data > spaces, but supervisor mode was rarely used in Unix environments, and > only a few large user mode programs ran using split I/D space.) 2.11BSD uses supervisor mode for the networking parts of the kernel. And the kernel is all I/D-space, and a bunch of programs are as well. The development is still contiuing. :-) > For > what it's worth, though, I *think* it was possible to restart most > instructions on the /45 and /70, which were the "big" machines and the > primary target of most later pdp-11 work. I don't think there is a single instruction that you can't restart. Some small, older machines missed a few registers needed for proper restarts however, and on those things were a bit more of a gamble if you wanted to go that path. > In fact, some use was made > of this feature -- automatic stack growth. If you look through ancient > Unix source, you'll find interesting bits of kernel code that manage > this. > > There's actually a cheesy way to do demand paging with microprocessors > that don't support demand paging (such as the original 68000--another > "16 bit" machine). The way to do this is to run two processors in parallel > but skewed by one instruction. If the first one does a bad memory fetch, > then the second one will not have fetched the instruction causing the > fault so contains restartable machine state. Masscomp sold a machine > like this once. Didn't the first Apollos do this? Johnny -- Johnny Billquist || "I'm on a bus || on a psychedelic trip email: bqt@update.uu.se || Reading murder books pdp is alive! || tryin' to stay hip" - B. Idol