Synchronous/Asynchronous, one more try. [djg31]

Gary D. Duzan duzan@udel.edu
Fri, 04 Jun 93 07:31:23 -0400


In Message <2c0ee3fd.davgar@davgar.arlington.va.us> ,
   David Garfield <david@davgar.arlington.va.us> wrote:

=>Well,
=>
=>-------------------------
=>
=>I have looked over the QNX paper.  I was very surprised to learn that
=>its send() call blocked until after the reply was done.  OK, so QNX is
=>synchronous.  That does not mean that all modern OSes are synchronous,
=>just that one 11 year old OS is.
=>
   IPC in QNX was discussed on comp.os.research a few weeks back. It
seems that Dan Hildebrant (sp?) and the folks at QNX generally don't
have a need for the asynchronous primitives for the class of programs
that they deal with (real-time applications.)

=>I fully agree that either the standard library (or whatever we call
=>it) or the kernel should include a synchronous communication layer,
=>but still assert that the kernel must include an asynchronous
=>communication layer at at least as low a level.  I agree that
=>programmers should be encouraged to use the synchronous forms unless
=>the applications calls for something else.
=>
   Ok, so we do both, with synchronous being primary, with asynchronous
being equal or secondary, depending on architecture and implementation.
Good enough?

=>Peter, my challenge stands.
=>}} All right, try this:  under Unix, write a program that reads data from
=>}} two data sources and does different things with the data, such that:
=>}}         1) only one process is used
=>}}         2) select() is not used
=>}}         3) either data source can produce data that will be processed
=>}}            imeadiately (sp?)
=>}}         4) the program does not eat CPU time
=>}}

   I think my point would be that the question is flawed. :-)  You
assume that #1 is bad, while I would say that multiple processes
might be a reasonable way of dealing with multiple streams. If the
processes (threads) are light enough, this shouldn't be a problem.

                                        Gary Duzan
                                        Time  Lord
                                    Third Regeneration
                         Humble Practitioner of the Computer Arts