Live data from Hacker News

Energy Efficiency Across Programming Languages

sites.google.com

31–40 of 143 posts

Re: Energy Efficiency Across Programming Languages

#31
post #5

A real shame that Forth wasn't included in the tested languages. Chuck Moore has been an advocate for more energy efficient computation for a while now.

The tests come from the benchmark game. If you want to see Forth, implement the tests in Forth:

http://benchmarksgame.alioth.debian.org/

Re: Energy Efficiency Across Programming Languages

#32
post #28
post #2

According to their normalized "global" results, something interesting i see: 1. Pascal, surprisingly, the most memory efficient of all. I should take a look at the implementation they used. 2. Rust a good alternative to C which leads in "energy efficiency" and speed. 3. Common Lisp most energy-efficient and fastest and smallest memory footprint of all the dynamic programming languages in the list -- like Python, Ruby…

> 5. I wonder which implementation of Lua they used. There is a table with the versions they used¹, but they don't mention the implementation – in can be inferred for some: e.g. for Pascal they used the Free Pascal Compiler. ① - https://sites.google.com/view/energy-efficiency-languages/se...

Ouch, they used Lua 5.3

LuaJIT is at least an order of magnitude(10x) faster.

Re: Energy Efficiency Across Programming Languages

#33
post #20

Earlier quoted context omitted.

> Those benchmarks don't reflect real-world workloads at all… That's a very definite claim, for which you provide no supporting evidence ;-)

Maybe we could get away with a couple smaller claims: - It would be weird to expect programs specifically optimized for a performance benchmark, to also be optimal for energy usage or memory. Maybe less weird for energy, if runtime is the biggest factor in how much energy gets used. But I'd expect there to be huge tradeoffs between runtime and memory usage, once we start really optimizing for memory. - Running the Be…

performance usually == energy efficiency on modern cpus. race to shutdown.

Re: Energy Efficiency Across Programming Languages

#35

I can't believe they used the Computer Language Benchmarks Game. Those benchmarks don't reflect real-world workloads at all, and the contest has fairly arbitrary rules about implementations and widely differing implementation quality between languages. This should have been rejected by peer review.

they reflect a number of different real world workloads.

Re: Energy Efficiency Across Programming Languages

#36
post #13
post #2

According to their normalized "global" results, something interesting i see: 1. Pascal, surprisingly, the most memory efficient of all. I should take a look at the implementation they used. 2. Rust a good alternative to C which leads in "energy efficiency" and speed. 3. Common Lisp most energy-efficient and fastest and smallest memory footprint of all the dynamic programming languages in the list -- like Python, Ruby…

> 1. Pascal Pascal is a "hidden" gem in the area of languages. Sadly not enough pus for it, but imagine if it have the push that other languages have...

Ruby also has gem.

Re: Energy Efficiency Across Programming Languages

#37
post #7

I see they monitor a complete process lifetime, not just the active workload. A quick grep of the paper didn't turn up anything discussing this. And it would seem to hurt dynamic languages and runtime-JIT languages a lot. Perhaps the active workload takes long enough that the transient is washed out. Anyone have insights?

If you want to tease the startup out, then you can run the game with a null or extremely small input set and then discount the time it takes to run a small/null workload from the actual run.

But really, if they hurt, then they get hurt. There's only so many knobs you can turn and so many runs you can run before you have to assemble a table and submit your paper. They put all the code online so you can try it yourself.

Re: Energy Efficiency Across Programming Languages

#38

On of the things with the C set is they didn't use Intel's icc. On our main application (which involved a lot of heavy duty number crunching) it speeds up our application by 100% over the best we can get out gcc.

I've seen 20% speedups with icc over gcc; but not a doubling. Is this including mkl over some other numeric library as well?

Re: Energy Efficiency Across Programming Languages

#39
post #20

Earlier quoted context omitted.

> Those benchmarks don't reflect real-world workloads at all… That's a very definite claim, for which you provide no supporting evidence ;-)

Maybe we could get away with a couple smaller claims: - It would be weird to expect programs specifically optimized for a performance benchmark, to also be optimal for energy usage or memory. Maybe less weird for energy, if runtime is the biggest factor in how much energy gets used. But I'd expect there to be huge tradeoffs between runtime and memory usage, once we start really optimizing for memory. - Running the Be…

Maybe we should look at "4 Threats to Validity" section of their paper and ask whether they have really done enough to suggest that their results should be considered general rather than specific.

Re: Energy Efficiency Across Programming Languages

#40

Earlier quoted context omitted.

Maybe we could get away with a couple smaller claims: - It would be weird to expect programs specifically optimized for a performance benchmark, to also be optimal for energy usage or memory. Maybe less weird for energy, if runtime is the biggest factor in how much energy gets used. But I'd expect there to be huge tradeoffs between runtime and memory usage, once we start really optimizing for memory. - Running the Be…

performance usually == energy efficiency on modern cpus. race to shutdown.

Does your comment agree or disagree with what they measure?
Post reply on HN