Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!ucsd!ucbvax!usenix!jsq From: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) Newsgroups: comp.std.unix Subject: Re: Standards Update, IEEE 1003.4: Real-time Extensions Message-ID: <544@usenix.ORG> Date: 25 Sep 90 23:09:38 GMT References: <539@usenix.ORG> <541@usenix.ORG> <543@usenix.ORG> Sender: jsq@usenix.ORG Organization: IR Lines: 37 Approved: jsq@usenix.org (Moderator, John Quarterman) X-Submissions: std-unix@uunet.uu.net Submitted-by: brnstnd@kramden.acf.nyu.edu (Dan Bernstein) In article <543@usenix.ORG> henry@zoo.toronto.edu (Henry Spencer) writes: > In article <541@usenix.ORG> brnstnd@kramden.acf.nyu.edu (Dan Bernstein) writes: > >In the filesystem abstraction, you open a filename in one stage. You > >can't do anything between initiating the open and finding out whether or > >not it succeeds. This just doesn't match reality, and it places a huge > >restriction on programs that want to do something else while they > >communicate. > Programs that want to do two things at once should use explicit parallelism, > e.g. some sort of threads facility. In every case I've seen, this yielded > vastly superior code, with clearer structure and better error handling. I agree that programs that want to do two things at once should use threads. However, a program that sends out several connection requests is *not*, in fact, doing several things at once. open() forces it into an unrealistic local model; surely you agree that this is not a good semantic match for what actually goes on. That example shows what goes wrong when locality disappears. As another example, NFS (as it is currently implemented) shows what goes wrong when reliability disappears. Have you ever run ``df'' on a Sun, only to have it hang and lock up your terminal? Your process is stuck in kernel mode, waiting for an NFS server that may be flooded with requests or may have crashed. Programs that use the filesystem for IPC assume that their files won't just disappear; this isn't true under NFS. I am not saying that networked filesystems are automatically a bad thing. Quite the contrary: a distributed filesystem with caching and other forms of replication can easily be local and reliable, and I'll gladly see standard UNIX make provisions for it. But something that's not local, or not reliable, or not static, is also not necessarily appropriate for the filesystem. ---Dan Volume-Number: Volume 21, Number 132