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.107.102.21 with SMTP id a21mr11601304ioc.27.1508306188456; Tue, 17 Oct 2017 22:56:28 -0700 (PDT) X-Received: by 10.157.45.110 with SMTP id v101mr593789ota.12.1508306188432; Tue, 17 Oct 2017 22:56:28 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!news.unit0.net!peer02.am4!peer.am4.highwinds-media.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!l196no969236itl.0!news-out.google.com!p6ni649itp.0!nntp.google.com!k70no972227itk.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 17 Oct 2017 22:56:28 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2003:6c:cd5d:2f01:e5c2:c553:36a9:aa43; posting-account=Md_OIgoAAAAkZyQ6nYoc3WBIThMpPfV7 NNTP-Posting-Host: 2003:6c:cd5d:2f01:e5c2:c553:36a9:aa43 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Why does Ada compile slower than Python? From: olivermkellogg@gmail.com Injection-Date: Wed, 18 Oct 2017 05:56:28 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Received-Body-CRC: 2110118999 X-Received-Bytes: 2461 Xref: news.eternal-september.org comp.lang.ada:48498 Date: 2017-10-17T22:56:28-07:00 List-Id: On Tuesday, October 3, 2017 at 11:08:59 PM UTC+2, Victor Porton wrote: > Victor Porton wrote: > [...] > According this test (valid only for very short programs) compiling Ada is= =20 > slower only two times. >=20 > Maybe I was under a wrong impression, because I got this impression when = I=20 > compiled tens of Ada files in a row and my brain was focused on total=20 > compilation time rather than compilation time for one file? >=20 > Is GNAT really much slower than Python? or was it a false impression? When compiling many interdependent packages GNAT is definitely slower than = it could be. This has to do with the fact that GCC/GNAT can only handle one= file at a time. E.g. if you provide 100 files on a single gcc command line= then gcc loads and compiles each file separately as though you were provid= ing 100 commands with one file per command. Some years ago I had started an experiment to add AST (abstract syntax tree= ) caching to GNAT and had gotten as far as the Ada frontend (GNAT trees); h= owever, the major effort for making this work is in the later stages of the= compiler (GNU trees, etc). Oliver