Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!princeton!allegra!alice!dmr From: dmr@alice.UUCP Newsgroups: comp.unix.wizards Subject: Why u. Message-ID: <6909@alice.UUCP> Date: Wed, 20-May-87 04:31:45 EDT Article-I.D.: alice.6909 Posted: Wed May 20 04:31:45 1987 Date-Received: Fri, 22-May-87 01:19:47 EDT Organization: AT&T Bell Laboratories, Murray Hill NJ Lines: 17 The real reason the u area doesn't move is simply that it contains the kernel stack, and moving it would require relocating addresses in the stack, and possibly other u variables. Given that you don't want to move its virtual location during a swap, on many machines (including the 11) it is better to access it as `u.' rather than as `up->'. On the standard Cray version of Unix the u area is referred to as u-> and moves, but the stack part is exchanged to a fixed location when context switches occur. (The copy uses vector moves, copies only the active stack, and is pretty fast). The people of Chippewa told me that they had a version that did not copy the stack, but instead traced it back and fixed up the frame pointers. They said they found only a few places where stack-relative automatic pointers occurred and the code was readily fixed to avoid the problem. I guess I believe them, but I'm surprised it was so easy. Dennis Ritchie