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,8147e9052e4bc0df X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII Path: g2news2.google.com!postnews.google.com!q36g2000prg.googlegroups.com!not-for-mail From: Adam Beneschan Newsgroups: comp.lang.ada Subject: Re: Child vs nested package : efficiency matter Date: Tue, 1 Jun 2010 11:35:02 -0700 (PDT) Organization: http://groups.google.com Message-ID: <4281c262-d761-4373-930a-39c973f1fb48@q36g2000prg.googlegroups.com> References: NNTP-Posting-Host: 66.126.103.122 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1275417302 7315 127.0.0.1 (1 Jun 2010 18:35:02 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 1 Jun 2010 18:35:02 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: q36g2000prg.googlegroups.com; posting-host=66.126.103.122; posting-account=duW0ogkAAABjRdnxgLGXDfna0Gc6XqmQ User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; WOW64; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.21022; .NET CLR 3.5.30729; .NET CLR 3.0.30618),gzip(gfe) Xref: g2news2.google.com comp.lang.ada:12176 Date: 2010-06-01T11:35:02-07:00 List-Id: On May 29, 5:56=A0am, Yannick Duch=EAne (Hibou57) wrote: > Hillo, > > For some reasons, I've turned some nested package -- packages nested in = =A0 > the body of package -- into a set of child packages instead. > > I've noticed the application's execution time is now an average of 125% o= f =A0 > that of the old implementation. > > The implementation did not changed otherwise and is still the same. > > What can make invokation of subprograms slower when the subprograms are i= n =A0 > a child package rather than in a nested package ? > > Note: this is with optimization enabled -- with -O -- and both old and ne= w =A0 > implementation was compiled with the same options. > > I can't explain that and can't imagine a reason why. That's a mystery to = =A0 > me. Something else that occurred to me: In the process of turning the nested packages into child packages, were there any global variables declared in the body of the parent package that you had to move to the spec (probably the private part) so that they would be visible to the child packages? -- Adam