Path: utzoo!mnetor!uunet!mcvax!ukc!its63b!simon From: simon@its63b.ed.ac.uk (ECSC68 S Brown CS) Newsgroups: comp.unix.wizards Subject: Re: SVR3.0 vs BSD4.3 Message-ID: <1145@its63b.ed.ac.uk> Date: 7 Apr 88 18:07:47 GMT References: <12414@brl-adm.ARPA> <4361@megaron.arizona.edu> <7499@brl-smoke.ARPA> <7542@brl-smoke.ARPA> <445@vsi.UUCP> Reply-To: simon@lfcs.ed.ac.uk (Simon Brown) Organization: LFCS, University of Edinburgh Lines: 45 Keywords: layers, sxt, job-control In article <445@vsi.UUCP> friedl@vsi.UUCP (Stephen J. Friedl) writes: >>In article <7542@brl-smoke.ARPA>, gwyn@brl-smoke.ARPA (Doug Gwyn ) writes: >< In article <2050@munnari.oz> kre@munnari.oz (Robert Elz) writes: >< >But that's not job control. Job control is when I notice that /foobar >< >is 98% full, and some cretin has a job running that's half way through >< >extracting 160Mb from a tar tape .. "kill -STOP " is job control. >< >Shell layers do not involve any kind of signals. When ^Z is hit, >the sxt driver gives control back to channel zero, which is >usually the layer manager (here, /usr/bin/shl). When a user >command to shl asks that a child layer be run, the layer manager >issues an ioctl to the multiplexor to give control to the child's >layer (there is no SIGCONT). One result of this implementation >is that I know of no way for a layer to suspend itself, certainly >not with signals. If your layer manager keeps the desciptor for channel zero open in it's subprocesses (and provides some method to allow these children to find out what descriptor it is - such as reserving a known descriptor for this use [Yeauch!]), then the subprocesses can do ioctls on this, so they can issue the ioctl to switch the current layer to zero, just as if ^Z had been typed. >Nevertheless it is not incorrect to equate job-control with shell >layers in a general kind of way -- kre's way just may be more general >than mine :-). Well, the only ESSENTIAL difference is that BSD job-control is cpu-control whereas SysV layers is io-control (you control what jobs can/cannot do input and/or output, rather than what jobs can/cannot be actively running). It's quite possible to put job-control code into a shell using layers that looks pretty close to BSD job-control - except that you can't control jobs that aren't doing terminal io. --Simon -- -------------------------------------------------- | Simon Brown | | Laboratory for Foundations of Computer Science | | Department of Computer Science | | University of Edinburgh, Scotland, UK. | -------------------------------------------------- UUCP: uunet!mcvax!ukc!lfcs!simon ARPA: simon%lfcs.ed@nss.cs.ucl.ac.uk JANET: simon@uk.ac.ed.lfcs