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.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,41967527237c1aa2 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!wns13feed!worldnet.att.net!attbi_s22.POSTED!53ab2750!not-for-mail From: "Jeffrey R. Carter" User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Fun with Tasking References: <1175097196.113031.259000@r56g2000hsd.googlegroups.com> <1175100948.580216.145940@r56g2000hsd.googlegroups.com> <1175104396.231171.125360@e65g2000hsc.googlegroups.com> In-Reply-To: <1175104396.231171.125360@e65g2000hsc.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 12.201.97.213 X-Complaints-To: abuse@mchsi.com X-Trace: attbi_s22 1175144363 12.201.97.213 (Thu, 29 Mar 2007 04:59:23 GMT) NNTP-Posting-Date: Thu, 29 Mar 2007 04:59:23 GMT Organization: AT&T ASP.att.net Date: Thu, 29 Mar 2007 04:59:23 GMT Xref: g2news1.google.com comp.lang.ada:14664 Date: 2007-03-29T04:59:23+00:00 List-Id: mhamel_98@yahoo.com wrote: > > Thank you Adam. While making this sample program a sneaking suspicion > started to creep up that I really didn't know what I was doing, and > you helped verify that suspicion. What's really going on is I have a > number of tasks I'm going to run, and while themselves completely > independent of one another, they send updates to a single listening, > or collating, task. That is the task at the heart of my initial > post. My approach was to start up this collating task and give it's > pointer (or address) to the processing tasks. This works fine if the > collating task definition is in the acc_add_test procedure and the > Control_Block has a pointer to that task within it. However, I would > like the collating task definition to reside with the "exec" procedure/ > package as the sample has it. How would one declare and start up that > task, without any visibility into the package, just a procedure > pointer with a mode argument? My (terribly flawed) idea was the > PreProcess element of the procedure would set that up, but as you > pointed out, the procedure would never exit while the task is > running. So how to define the task and put it on "hold" until the > processing tasks can utilize it? I don't expect it's possible without > incurring as much ugliness as the program has already, but I thought > I'd give it a try. Thanks again =) Tasking /is/ fun. I seem to be unusual in that I don't find it difficult. I'd like to be able to show off and solve all your problems, but I still have no idea what you're trying to achieve. I've got a lot of information about how you're trying to implement it, but no idea what "it" is. If you can describe the problem, there's probably an elegant way to implement a solution in Ada. -- Jeff Carter "All citizens will be required to change their underwear every half hour. Underwear will be worn on the outside, so we can check." Bananas 29