Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!mcvax!ukc!its63b!simon From: simon@its63b.ed.ac.uk (Simon Brown) Newsgroups: comp.unix.wizards Subject: Re: No more signals Message-ID: <492@its63b.ed.ac.uk> Date: Sun, 21-Jun-87 18:07:03 EDT Article-I.D.: its63b.492 Posted: Sun Jun 21 18:07:03 1987 Date-Received: Fri, 26-Jun-87 03:46:39 EDT References: <48300005@hcx1> <1714@munnari.oz> Reply-To: simon@its63b.ed.ac.uk (Simon Brown) Organization: Computer Science Department, Edinburgh University Lines: 45 In article <1714@munnari.oz> kre@munnari.oz (Robert Elz) writes: >In article <48300005@hcx1>, tomp@hcx1.SSD.HARRIS.COM writes: >> a mask of the signals and checks it in such places as system call entry/exit. >> ... the signal mask is checked in critical places. > >I think you'll find that the vast majority of the checks (executed) >are actually "is there a signal", the code doesn't care which signal >is pending, only whether one is. > >You could implement the signal pending and mask stuff anyway that >you like from this point of view, only the signal sending, and delivery >code care about this part of things, and they're not time critical, >so indexing into an array of bits would be reasonable. One really nasty bug that really needs fixing fast is that the so-called "safe signal" mechanism is anything but! If I send 5 SIGINT signals to a process, there is no guarentee that that process will receive them all - ok, it will certainly receive at least one, but whether it receives 2,3,4 or 5 is pretty much left to chance! > >However, there's a problem with any change here .. he user interface >assumes that the signal bits can be implemented by a bit mask of 32 >bits (actually an "int" which we hope like hell has NSIG (32) bits >in it). > Yes, but you can always build a little backward-compatibility library to allow people to still use bitmasks if they want to. Also, if your "int" doesn't have 32 bits, then you should be using a "long" instead, for this - like 2.9BSD does. %{ Simon! %} -- ---------------------------------- | Simon Brown | UUCP: seismo!mcvax!ukc!its63b!simon | Department of Computer Science | JANET: simon@uk.ac.ed.its63b | University of Edinburgh, | ARPA: simon%its63b.ed.ac.uk@cs.ucl.ac.uk | Scotland, UK. | ---------------------------------- "Life's like that, you know"