From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ab2ba9c5d12b0f12 X-Google-Attributes: gid103376,public From: red@satcom.whit.org (Robert Dunn) Subject: Re: Concurrency in Gnat 3.05? Date: 1996/07/18 Message-ID: <19960718.082642.172@satcom.whit.org>#1/1 X-Deja-AN: 169609675 references: <4sjqte$3mu@masala.cc.uh.edu> organization: Manassas News Server newsgroups: comp.lang.ada Date: 1996-07-18T00:00:00+00:00 List-Id: In article <4sjqte$3mu@masala.cc.uh.edu>, on 17 Jul 1996 22:53:34 GMT, Spasmo writes: >Hey all. > >Is Gnat 3.05 (for DOS) truly concurrent when executing tasks? I'm >asking because I've written some tasking code (finally got it >to link) and when I ran the code, the tasks didn't run >concurrently at all. I'm running in a Win95 DOS box. One task >runs to completion before the other task starts up. I've also >tried some sample code including Feldman's Twotasks program >and they exhibit the same behavior. Is there a way to get >tasks to run concurrently, or would I have to look for a >GNAT that's native to something like WinNT/95 that can >handle multi-tasking? > > Ok, here is how you answer that question. Go get yourself both a phillips and a t-15 screwdriver. Now, remove the cover from your Win95/DOS7.0 Box. Count the number of processors. If you counted one, you are absolutely correct. Now, ask yourself, how many operations can run on one processor at a time. If you answered one again, you now have two points. ;> Now, for the big question? Can one processor run two (or more) tasks concurrently? If you answered no, you have just won the grand prize. The question that now remains is, How do you make a single processor seem as if it is doing more than one thing at a time. Did you say time slicing? Well, that is correct. And what is time slicing synonomyous (ok so I can't spell) with? OVERHEAD!!! The logical conclusion therefore is to save the overhead by allowing a task to run until a natural break (eg completion, accept, call, etc). Yes, it would be nice to have true multi-tasking. Sorry if this sounds harsh, it is designed to entertain. Of course, I have yet to meet a programmer who didn't have a unique sence of humor.