comp.lang.ada
 help / color / mirror / Atom feed
From: olivermkellogg@gmail.com
Subject: Re: Why does Ada compile slower than Python?
Date: Tue, 17 Oct 2017 22:56:28 -0700 (PDT)
Date: 2017-10-17T22:56:28-07:00	[thread overview]
Message-ID: <e0ab497d-c1cd-4997-93b5-e32d787cfc3e@googlegroups.com> (raw)
In-Reply-To: <or0u97$1hot$1@gioia.aioe.org>

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 
> slower only two times.
> 
> Maybe I was under a wrong impression, because I got this impression when I 
> compiled tens of Ada files in a row and my brain was focused on total 
> compilation time rather than compilation time for one file?
> 
> 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 providing 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); however, the major effort for making this work is in the later stages of the compiler (GNU trees, etc).

Oliver

  parent reply	other threads:[~2017-10-18  5:56 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-02 23:01 Why does Ada compile slower than Python? Victor Porton
2017-10-03  0:05 ` Leff Ivanov
2017-10-03  1:11 ` gautier_niouzes
2017-10-03 11:31   ` Brian Drummond
2017-10-03 20:14   ` Randy Brukardt
2017-10-03 21:23     ` gautier_niouzes
2017-10-03 13:07 ` bartc
2017-10-03 13:41   ` G.B.
2017-10-03 21:08 ` Victor Porton
2017-10-04 15:00   ` Simon Wright
2017-10-18  5:56   ` olivermkellogg [this message]
2017-10-18  6:38     ` Paul Rubin
2017-10-18  7:13       ` Dmitry A. Kazakov
2017-10-18  7:34         ` Björn Lundin
2017-10-18  8:02           ` Dmitry A. Kazakov
2017-10-20  6:25             ` gautier_niouzes
2017-10-04  0:21 ` Mace Ayres
2017-10-04  1:51   ` Andrew Shvets
2017-10-04  1:54 ` Andrew Shvets
2017-10-04 15:47 ` gautier_niouzes
2017-10-04 16:03   ` Victor Porton
2017-10-07 11:47     ` Blady
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox