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: a07f3367d7,6ca5f0d94d4c145 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!nntp.TheWorld.com!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Distributed Computing in Ada Date: Fri, 28 Aug 2009 15:57:49 -0400 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <7f8194ed-26d1-4a38-841b-6cb910b10ce4@j9g2000prh.googlegroups.com> <7ea2b1c2-a011-456e-9ec2-10c4ab75ee05@r38g2000yqn.googlegroups.com> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: pcls6.std.com 1251489469 26660 192.74.137.71 (28 Aug 2009 19:57:49 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Fri, 28 Aug 2009 19:57:49 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:m95KHSD2I/VZ/oWZiXf0dmgrUXk= Xref: g2news2.google.com comp.lang.ada:8043 Date: 2009-08-28T15:57:49-04:00 List-Id: "Jeffrey R. Carter" writes: > Robert A Duff wrote: >> Now we have a bunch of tasks accessing shared variable Global, >> all correctly synchronized by the rendezvous. > > The accesses look unsynchronized to me. Yes, you're right (assuming the entries can be called simultaneously). Thanks for pointing out my sloppiness. What was I thinking? :-( I don't think it affects my main point, though, which is that the compiler doesn't know which variables are shared. Of course, if they are shared, we would hope they would be properly synchronized. So change my example so they are: e.g. have a single task or protected object that calls P.Q. And have lots of tasks that call that. In which task's address space should Global be allocated? The environment task creates and initializes it, so... - Bob