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,e0e1d3b3f7c994b8 X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!a70g2000hsh.googlegroups.com!not-for-mail From: gpriv@axonx.com Newsgroups: comp.lang.ada Subject: Re: Robert Dewar's great article about the Strengths of Ada over other langauges in multiprocessing! Date: Wed, 12 Mar 2008 17:34:02 -0700 (PDT) Organization: http://groups.google.com Message-ID: <9906033a-eaf2-46a7-9ec4-b1e2b30b9e15@a70g2000hsh.googlegroups.com> References: <13t4b2kkjem20f3@corp.supernews.com> <89af8399-94fb-42b3-909d-edf3c98d32e5@n75g2000hsh.googlegroups.com> <47D39DC8.20002@obry.net> <114f711c-9cf8-4fdb-8f11-77667afb8719@c33g2000hsd.googlegroups.com> <604214ee-fc78-47ae-bf2f-fa7c84971918@i29g2000prf.googlegroups.com> NNTP-Posting-Host: 69.250.188.114 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1205368442 28209 127.0.0.1 (13 Mar 2008 00:34:02 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 13 Mar 2008 00:34:02 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: a70g2000hsh.googlegroups.com; posting-host=69.250.188.114; posting-account=YaY8rAoAAAAAnFXOECY3BGVJsrvFJCgy User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.8.1.12) Gecko/20080201 Firefox/2.0.0.12,gzip(gfe),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:20330 Date: 2008-03-12T17:34:02-07:00 List-Id: On Mar 12, 11:22 am, Vadim Godunko wrote: > On 12 =CD=C1=D2, 17:41, gp...@axonx.com wrote:> > In C++ destructor can be= inlined *always*, unless the object is > > > deleted via pointer to base. In other words, objects with automatic or= > > > static storage duration (local, static and global) objects can have > > > inlined destructors - no matter whether it is virtual or not. > > > Yes if compiler can make that determination at compile time. If not > > it will dispatch via VTab. My point was to compare make all the > > conditions equal. After all you may consider generic model for Ada > > which eliminate all the dispatch overhead. > > QString is not a polymorphic class - it don't have any virtual > functions. Its constructor, copy constructor, destructor ar inlined. > Its assignment operator not inlined. > > Ada program use tagged but not class-wide type, thus compiler never > dispatch any call. I compile all Ada modules with -gnatn (frontend > inline enabled). > > Both program are comparable from this point of view. :-) > > PS. I have replaced protected type by i386 specific atomic increment/ > decrement and have only 1.2 overhead. ;-) That makes sense. Protected objects are guarded by some sort of system wide mutexes and overhead is unavoidable. 20% overhead is only 3 months of computer evolution, I can live with that. George