comp.lang.ada
 help / color / mirror / Atom feed
From: "G.B." <bauhaus@notmyhomepage.invalid>
Subject: Re: Comparing languages wrt energy, speed, and memory use
Date: Thu, 24 Feb 2022 08:42:40 +0100	[thread overview]
Message-ID: <sv7cth$ob6$1@dont-email.me> (raw)
In-Reply-To: <20220222211015.1cdb2a27@linux.fritz.box>

On 22.02.22 21:10, Fernando Oleo Blanco wrote:
> Hello everybody,
> 
> I am going to leave a few comments regarding this paper that I believe
> everybody should know. Most if not all of these points are known and
> have been discussed pretty much everywhere; but a lot of people still
> don't know them or decide to not know.
> 
> The programs are taken from the Programming Language Benchmark Game. It
> is a really cool place that has been providing relevant performance
> data for a lot of languages and comparisons between them.
> 
> Here are a few issues:

One issue is Isaac Gouy's clever approach. (Not complaining. I sometimes
didn't see the point, though, of adopting another new thing. For example,
when a new regex library was introduced (at some point) that wins hands
down by using optimization techniques you'd associate with JIT compilers
or with data based optimization. Worth knowing about, but how does it
help comparing languages when all you can do is link it to your program?)


> 1. Quite a few languages are not using heavily optimised code. Ada is
>     one of them. Some of those programs are written as direct
>     translations from other languages from people that did not know the
>     target language.

Can you be specific? For example, at least one program currently
leads by making extensive use of x86 intrinsic ops.

Some use OMP with intrinsic 128bit ops. Does GNAT have a similar parallel
loop in the language yet?

  
> 2. Quite a few of those implementations have not been touched in years.

Yet, some Ada program versions #N+m used to run faster than #N. They now
have their speed difference wiped out or even reversed...
I see -march=ivybridge now, so the hardware has likely changed.

>     Some of the improvements that may have taken place in the
>     language/compiler/tools may not be taken advantage of. For example,
>     the Ada examples are compiled with -gnatNp. Can anybody say what
>     that flag does? x)

GNAT User's Guide explains. (su-p-press and front end i-N-lining)

> 3. C/C++/Rust program are competing on getting the best results. Other
>     languages are lagging behind. For example, Fortran could do much
>     better.

How would Fortran do much better? Can Ada learn from that?

> 4. There are a few controversies. Some languages are not allowed to use
>     higher performance libraries while others are allowed their stl or
>     equivalent that do actually use the same tools as those libraries.
>     Thre are a few other examples.

Controversies add to the management's keeping this a lively benchmark.

> Ada has
> been left behind since very few or nobody is actually taking a look at
> the code and optimising it...

Care to be specific how it is not optimized? There is always room for
better algorithms. Looking at fasta, the leading programs all use threading
now, with the exception of the one at the top, which has an introductory
comment.


  parent reply	other threads:[~2022-02-24  7:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-20 22:59 Comparing languages wrt energy, speed, and memory use Jerry
2022-02-22 20:10 ` Fernando Oleo Blanco
2022-02-22 20:49   ` J-P. Rosen
2022-02-24  7:42   ` G.B. [this message]
2022-02-24  9:13     ` Fernando Oleo Blanco
2022-02-27  3:31 ` 25.BX943
2022-02-27  8:05 ` Robin Vowels
2022-02-27  8:56   ` Jeffrey R.Carter
replies disabled

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