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,470860aa3e635a7 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!t-online.de!storethat.news.telefonica.de!telefonica.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail Newsgroups: comp.lang.ada Subject: Re: concurrent access to containers (was: GNAT for MS Visual Studio) From: Georg Bauhaus In-Reply-To: <1191590746.132231.277960@r29g2000hsg.googlegroups.com> References: <13f6eg0te46m2a3@corp.supernews.com> <4xsl4zw3bp.fsf@hod.lan.m-e-leypold.de> <1191357491.860178.230380@22g2000hsm.googlegroups.com> <4702ADCC.7080209@obry.net> <1191439439.120567.172630@g4g2000hsf.googlegroups.com> <4703F02D.3030207@obry.net> <1191442124.099242.282130@57g2000hsv.googlegroups.com> <1191529107.233474.287380@o80g2000hse.googlegroups.com> <47054B4B.7080609@obry.net> <1191590746.132231.277960@r29g2000hsg.googlegroups.com> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-ID: <1191667841.7261.30.camel@K72> Mime-Version: 1.0 X-Mailer: Evolution 2.12.0 Date: Sat, 06 Oct 2007 12:50:41 +0200 Organization: Arcor NNTP-Posting-Date: 06 Oct 2007 12:50:43 CEST NNTP-Posting-Host: 7b277178.newsspool3.arcor-online.net X-Trace: DXC=U9E=S0COWofPKPPVf;4hUjMcF=Q^Z^V3h4Fo<]lROoRa^;5]aA^R6>b@eiPY3A=egePCY\c7>ejVhd=Q1;G0Cm]l5O; On Fri, 2007-10-05 at 06:25 -0700, Maciej Sobczak wrote: > On 4 Pa , 22:21, Pascal Obry wrote: > > > >http://www.adaic.org/standards/05aarm/html/AA-A.html > > > > > 3/2: > > > > > "The implementation shall ensure that each language- defined > > > subprogram is reentrant in the sense that concurrent calls on the > > > same subprogram perform as specified, so long as all parameters that > > > could be passed by reference denote nonoverlapping objects." > > > > Fine but we are speaking about "reading" only the parameters. This does > > not apply. > > I understand you, but I don't see this exclusion in the paragraph > above. > > What I see is "subprogram", "calling", "parameter" and "overlapping". > I don't see *any* distinction between reading and writing. > > I other words, the obvious guarantee [...] I don't think it is obvious that something of this sort should be guaranteed (read-only access from multiple tasks is possible, and trouble free). For example, algorithms used by search engines or by distributed databases do not necessarily shy away from copying shared data. So nothing is physically shared in these systems and algorithms at the level will be free of concurrent access even though the system is concurrent. It still works on exactly one virtually shared set of data... Should standard container design assume it makes sense to restrict implementers by assuming one specific computer architecture like shared memory with multiple CPUs? Or should standard container design assume that multiple copies of data will be ubiquitous given current hardware options? Can an Ada standard library assume that there is a compare and swap operation available on typical 8bit or 16bit CPUs? What if there isn't?