Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!att!dptg!pegasus!mpl From: mpl@pegasus.ATT.COM (Michael P. Lindner) Newsgroups: comp.unix.questions Subject: Re: higher priority to more in "XXXX |more" Message-ID: <4883@pegasus.ATT.COM> Date: 29 Jun 90 17:31:08 GMT References: <772@teslab.lab.OZ> <1777@necisa.ho.necisa.oz> <807@ehviea.ine.philips.nl> <4879@pegasus.ATT.COM> <809@ehviea.ine.philips.nl> Reply-To: mpl@pegasus.ATT.COM (Michael P. Lindner) Organization: AT&T Bell Labs NJ USA Lines: 27 In article <809@ehviea.ine.philips.nl> leo@ehviea.UUCP (Leo de Wit) writes: >In article <4879@pegasus.ATT.COM> mpl@pegasus.ATT.COM (Michael P. Lindner) writes: >|I've got a proposal that stdio flush output buffers if there is something in >|the buffer for longer than X, where X is some amount of time. Thus, programs deleted >However, assuming that you don't mess around with timers and signal >handlers (which is at least tricky in combination with stdio), I can >see two disadvantages: deleted Ah, but I DO mess around with timers and signal handlers. The overhead is about 2 instructions per putc/fwrite/printf/whatever, with an extra function (and possibly a system call every X seconds). This may or may not be acceptable, but I think it'll work. I haven't actually written the code and tried it, but yesterday Andrew Koenig wrote me and pointed out all the problems I would encounter (and some of the solutions to them) and I am convinced after thinking some more that it could be done. Whether or not it would be a win or a loss is left as an exercise to the reader. I don't want to waste net time on this, but if someone is really interested, they're welcome to try implementing it and reporting to the net. My thanks to Andrew Koenig, who was able to debug my ideas in his head (I guess that's what you get from writing such excellent books as "C Traps and Pitfalls"). As to whether or not the proposal would be conformant to ANSI or anybody, I don't know, but I do think it's useful in quite a few situations. Mike Lindner