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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!news.glorb.com!Xl.tags.giganews.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!nntp.earthlink.com!news.earthlink.com.POSTED!not-for-mail NNTP-Posting-Date: Sat, 25 Oct 2014 12:25:24 -0500 From: Dennis Lee Bieber Newsgroups: comp.lang.ada Subject: Re: confusion about message passing between the tasks Date: Sat, 25 Oct 2014 13:25:31 -0400 Organization: IISS Elusive Unicorn Message-ID: References: X-Newsreader: Forte Agent 6.00/32.1186 X-No-Archive: YES MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Usenet-Provider: http://www.giganews.com NNTP-Posting-Host: 108.79.218.175 X-Trace: sv3-DGpPOm4tkADfkz7I/RVZJN73Vb+rYxq/26wnwwdpgpyTS0tgyV3awcpvalU6YpPXYXwD4EKDBieGhS9!4UyzsznntP82c/LYKjjj5UhX+hwC5P9dZjt97Hl6f2DhZhmH23jCddGqaOoycS58RMuBDQbF4Yq4!MXjKHg8QW3JrLNVdY6wtex7XLHgX X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 2304 Xref: news.eternal-september.org comp.lang.ada:22731 Date: 2014-10-25T13:25:31-04:00 List-Id: On Fri, 24 Oct 2014 09:44:08 -0700 (PDT), compguy45@gmail.com declaimed the following: >I am really kind of lost with tasks and message passing. Would anyone show me an example where 2 tasks would be created by environment task...each task has same body and one entry...so for example one task waits at entry while the other one completes the entry block and on the exit lets waiting task that's its done. If they are the "same body and one entry" there is NO WAY to do what you want. Either both tasks will be waiting on their entry for another to rendezvous, or both tasks will be blocked waiting to rendezvous on a called entry. First case (pseudo code): accept theEntry() -- both blocked waiting for some task to call it -- note that it can't restrict which task calls do stuff end theEntry other.theEntry() Second case: other.theEntry() -- both blocked waiting for known other task to accept -- you'll have to initialize each task with the -- knowledge of the other accept theEntry() do stuff end theEntry -- Wulfraed Dennis Lee Bieber AF6VN wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/