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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.66.65.109 with SMTP id w13mr11798189pas.21.1399124584739; Sat, 03 May 2014 06:43:04 -0700 (PDT) X-Received: by 10.140.49.234 with SMTP id q97mr1946qga.22.1399124584633; Sat, 03 May 2014 06:43:04 -0700 (PDT) Path: border1.nntp.ams3.giganews.com!backlog3.nntp.ams3.giganews.com!backlog3.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!feeder.erje.net!us.feeder.erje.net!news.glorb.com!c1no941497igq.0!news-out.google.com!du2ni21233qab.0!nntp.google.com!ih12no157704qab.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Sat, 3 May 2014 06:43:04 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=206.53.78.59; posting-account=ShYTIAoAAABytvcS76ZrG9GdaV-nXYKy NNTP-Posting-Host: 206.53.78.59 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <7403d130-8b42-43cd-a0f1-53ba34b46141@googlegroups.com> Subject: Re: Safety of unprotected concurrent operations on constant objects From: sbelmont700@gmail.com Injection-Date: Sat, 03 May 2014 13:43:04 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Original-Bytes: 1757 Xref: number.nntp.dca.giganews.com comp.lang.ada:186195 Date: 2014-05-03T06:43:04-07:00 List-Id: On Friday, May 2, 2014 4:42:56 AM UTC-4, Natasha Kerensikova wrote: >=20 > Is it safe to have many tasks performing operations concurrently on >=20 > constant objects? >=20 In the general case, no. Suppose your constant object is of a private type= T, which contains an access value to something else. Some operation O mig= ht read and write to the other object in a non-task safe manner, and so inv= oking O from two different tasks might cause any number of fun shenanigans. -sb