Green software: Why efficiency and clean energy won’t cut it

One of the hopes of ‘solving’ the climate crisis is digitalization. The idea goes that as we move away from physical resources like printing paper and activities like in-person meetings, we’ll be producing less waste and pollution. Since we think of digital devices as requiring nothing but electricity (and ‘the Internet’) to function, we can eventually move the digital tech industry to use ‘green’ energy and achieve complete decarbonization*, right? Add to that the belief that renewable sources of energy have nearly zero impact on the environment and it looks like we’ve got ourselves a neat solution.

* decoupling of productivity and economic output from greenhouse gas emissions

But the reality is not that simple. Digital is not ethereal. The Cloud is not in the sky. It’s the servers in computing facilities, the optic fiber cables, the rare metals used in production of computers, the mines they come from, and the violence and exploitation their extraction funds. It’s the water-thirsty and energy-hungry data centers which take away these resources from local communities. It’s the toxic e-waste we leave in landfills when we pronounce the hardware we use—being incapable to keep up with the bloated software that consumes more and more resources to perform the same tasks—not efficient enough.

What is green software, then?

Green software is a movement towards decarbonizing computing—and the information and communications technology (ICT) industry at large—by making the software and hardware more efficient and switching to clean or low-carbon energy sources. While there’s no official definition, most organizations and key figures in the movement agree on these goals. Most stress the importance of reducing the carbon intensity, not simply offsetting emissions.

The premise of these goals sounds reasonable. It provides software companies with a clear pathway towards decarbonization of their businesses:

  1. Move services to cloud providers that run on clean energy and provide carbon-aware resource usage options.
  2. Use more resource-efficient hardware and share computing resources between services to minimize idle time (by moving to the cloud).
  3. Optimize software code in various ways—using more efficient programming languages, microservices, reducing web assets size, efficient caching and data compression, among others.
  4. Focus on measuring the environmental impact of software by employing metrics such as the Software Carbon Intensity specification.

Does it mean we have it all figured out and we just need to get to work and make these changes to achieve a net-zero future for the tech industry? Let’s take a deeper look at these components of green software.

"Premature optimization is the root of all evil"

American computer scientist Donald Knuth addressed this statement to the programmers who are "worrying about efficiency in the wrong places and at the wrong times". While he meant it in the narrow sense of focusing too much on computational complexity, this attitude can be applied more generally to how we think of software and computing in the context of sustainability. It makes sense to use more efficient hardware, compress images better, tree-shake JS assets before sending them to the client. We can and should reduce software bloat, trim down the amount of unnecessary data being sent, and think critically about our technology stack, systems architecture, and IT infrastructure.

But how many times has improvement in efficiency actually reduced our energy and material resources consumption? You might be surprised to learn that the answer is "practically zero." Making the use of available resources as optimally as possible has been at the forefront of the tech industry ever since the first computers came into existence, yet the energy demand of the ICT sector is still growing between 6 and 9% year on year. This phenomenon is so ubiquitous (in a growth-oriented economy) that it's got its own name—the Jevons paradox.

We focus all our attention on trimming down the unnecessary bits, on achieving the same results with fewer resources used. However, by doing so, we’re avoiding the big question—what do we deem necessary and why? Do we need to develop better compression for streaming music, or can we (re)learn to download it once and listen to it offline? Shall we monitor and optimize the performance of our application running in a Kubernetes cluster on a carbon-aware cloud computing platform, or can we make do with a static webpage running on a small, off-grid, solar-powered homeserver? These questions might seem frightening, but they are essential if we want to understand where to invest our very limited time and resources in trying to address the environmental impact of the software industry.

One might say, “It’s just not possible in our modern world, we cannot go back to the Stone Age. Humans like convenience, they like comfort, and we’ll seek it whether we want it or not. Rather than reducing our energy consumption, we should focus on transitioning towards clean energy.”

It is a tempting thought—can we just keep doing what we do now, but greener?

(C)lean energy use

Moving away from fossil fuels towards clean energy sources is a non-negotiable step towards decarbonization, no matter which sector of the economy is in question. Yet, what’s usually missing in these discussions is just how much energy we consume compared to how much we can produce using renewable sources of energy alone.

The terms ‘clean’ and ‘renewable’ are quite misleading in how they dematerialize the resources it takes to produce the energy. Solar panels require extraction of aluminum and production of silicon semiconductors, wind turbines are made of steel and petrochemical materials. Production of clean and renewable energy technologies requires environmentally polluting and harmful extraction of non-renewable resources, and involves energy- and carbon-intensive processes. Even if we manage to completely move our electric grids to renewables, we’ll have to continue to extract more and more minerals, since both solar panels and wind turbines have a lifespan of about 25 years. With that in mind, how much energy do we need to satisfy our current and future demand?

It is estimated that in 2022, the world produced around 3,400 TWh, or ~11.9% of all electricity from wind and solar. The percentage goes up to 29.6% if we include hydropower, biomass, and other renewables. The ICT sector alone is estimated to be responsible for up to 10% of the worldwide electricity consumption now, and this share is projected to grow significantly in the future, along with rising total demand for energy worldwide. Contrary to popular belief, digitalization does not decouple economic growth from energy consumption.

While it’s convenient to think that we can move all data centers to use renewables or run workloads when the grid is ‘cleaner’, the reality is we just cannot satisfy our growing hunger for energy without inflicting great damage to the environment and people. No matter if it’s solar power or nuclear fusion, the problem isn’t that we need more or better technology. We need to rethink our priorities and drastically lower our total consumption.

Finishing thoughts

There is no source of energy free of resource extraction. There is no way for the software industry to grow indefinitely and not use more energy. Sustainability means knowing what is necessary and what is wasteful, it means having a holistic view of our environment and our interaction with it, and it means understanding its limits and knowing when enough is enough. As long as our economic system necessitates growth at all costs, we cannot sincerely speak of green software and sustainability.

FacebookTwitterPinterest

Serge Korzh

Full Stack Developer

I like building light and robust websites. I'm constantly on the lookout for new ways of approaching common challenges in software development. In my work, however, I put people first and technology last.