Live data from Hacker News

Python consumes 38x more energy than Java

stratoflow.com

101–110 of 142 posts

Re: Python consumes 38x more energy than Java

#101
There is a more recent paper by Pereira et al. from 2021 (see https://www.sciencedirect.com/science/article/abs/pii/S01676... ); if geomean is used (which is the correct method) instead of what they apparently do in the paper, there is yet a different order (see http://software.rochus-keller.ch/Ranking_programming_languag...).

Re: Python consumes 38x more energy than Java

#103
post #63

Earlier quoted context omitted.

I think you bring up a good point. Our economic system isn't designed to reward low energy consumption. In fact, GDP and energy usage are very tightly linked. And because we are seeking growth in GDP at a system level, we are doomed to use more energy.

Considering energy costs money, our economic system is literally designed to reward lower energy consumption.

Strange, and yet we keep using more energy every year. Fun fact, we burn as much wood for heating as we did 100 years ago. What ends up happening is we consume all available energy. Economic growth is limited by energy so the whole system is incentivized to GROW energy usage, not reduce it.

I suspect you are talking about per capita energy usage. Per capita energy usage has stayed around 80 mWh per person since 1965 in the US.

But what's important isn't the per-capita usage, but aggregate usage. Because guess what, the climate doesn't care about per-capita CO2.

You have to look at it from a system level, not individual actor level. Our whole political and economic system is designed to have exponential GDP growth. And because energy is a limiting factor in GDP growth, then our whole political and economic system is designed to extract as much energy as possible to keep growth from hitting that limit.

Re: Python consumes 38x more energy than Java

#104

Earlier quoted context omitted.

> GDP and energy usage are very tightly linked Correlation or causation?

Side effect. Energy consumption is a result of labor applied to tools and technology for production. It is not mere correlation, but it is also not the cause, it is one measurable downstream effect. China, in fact, used energy consumption as the measure for GDP reporting. For this reason, local leadership in cities and provinces would game the system by running the coal plants at peak and turning on all lights in a c…

Available energy is a limiting factor in economic growth. More available energy allows for more economic growth. While a decline in economic growth for other reasons (financial crisis, pandemic) reduces demand for energy. So it's both a cause and effect. It's a feedback loop! Asking it it's causation or correlation is the wrong question. Does the temperature in the room effect the thermostat, or the thermostat effects the temperature in the room? It's a feedback loop!

In other words, when potential economic growth buds up against energy supply, energy prices rise and they rise non-linearly. This causes a reduction in potential economic growth. If there is a decline in economic growth, then demand falls below supply and prices drop. As prices drop they enable more economic growth.

In other words, the economy grows as much as energy supply allows. A 10% decline in available energy means a 10% decline in GDP. It really is that linear.

Re: Python consumes 38x more energy than Java

#105
post #101

There is a more recent paper by Pereira et al. from 2021 (see https://www.sciencedirect.com/science/article/abs/pii/S01676... ); if geomean is used (which is the correct method) instead of what they apparently do in the paper, there is yet a different order (see http://software.rochus-keller.ch/Ranking_programming_languag... ).

ods ?

"How do you want to open this file?"

Re: Python consumes 38x more energy than Java

#106
post #3

The actual benchmark: https://benchmarksgame-team.pages.debian.net/benchmarksgame/... EDIT: fwiw, classic Fortran is twice as fast as java :P As is Rust, but that's less funny to me

No, this is "the actual benchmark" —

"Source: Energy Efficiency across Programming Languages, SLE’17"

and google finds —

https://greenlab.di.uminho.pt/wp-content/uploads/2017/09/pap...

Re: Python consumes 38x more energy than Java

#108
post #105
post #101

There is a more recent paper by Pereira et al. from 2021 (see https://www.sciencedirect.com/science/article/abs/pii/S01676... ); if geomean is used (which is the correct method) instead of what they apparently do in the paper, there is yet a different order (see http://software.rochus-keller.ch/Ranking_programming_languag... ).

ods ? "How do you want to open this file?"

It's OpenOffice format; you should be able to open it with MS Excel too in case you prefer that.
Post reply on HN