Green software: Best practices for a sustainable future
12 MINS READ
Efforts toward net-zero
The information and communication technology industry contributes about 2.1–3.9% of the total global greenhouse emissions. Though the current contribution of software to global carbon emissions is lower than other sources, it is expected to exponentially increase in the coming years given the rapid growth of digital transformation and artificial-intelligence-based applications.
Organizations must therefore broaden the scope of their sustainability initiatives to include software and measure its energy impact across the development, deployment, operations, and maintenance stages. Organizations can leverage tools and technologies, like measurement frameworks and energy profiler tools, to enhance their decarbonization initiatives to meet net-zero-emission goals. These technologies also help to improve efficiencies of the software development process and overall operations.
Decarbonization is a key strategic objective for organizations that have embarked on the journey to achieve net-zero goals. They are examining every aspect of their carbon footprint, including that of application software, a major driver behind energy consumption. Measuring the energy consumption of software has inherent challenges as it can only be indirectly gauged in terms of power used by the accompanying hardware. Moreover, the carbon footprint of software must be analyzed in its entirety, across the development, delivery, and deployment phases.
Organizations can leverage technologies, to improve efficiencies of the software development process and overall operations. They can incorporate reusable components to reduce the application development time. This point-of-view discusses different facets of greening software and highlights a software carbon footprint measurement framework backed by recommendations and best practices to help organizations achieve their emission goals.
Widening the scope of sustainable IT through green software
With the increased enterprise focus on sustainability, and a general shift towards responsible environmental, social and governance (ESG) practices, organizations have succeeded in identifying the problems. The benefits of sustainable practices are well documented and known. However, there are not too many viable and long-term solutions that can help organizations achieve their carbon reduction goals.
The scope of sustainable IT has so far been limited to reducing the energy consumption of data centers, optimizing heating and cooling requirements, minimizing travel, and managing carbon offsets and e-waste. It is imperative to include energy used for software development and related operations to get a holistic view of the organization’s carbon footprint. Today, IT may not be considered one of the larger contributors of carbon emissions, but the situation may change in a few years given the rapid increase of digital transformation initiatives and AI-based applications. The Information and Communication Technology’s (ICT) true proportion of global emissions could be around 2.1–3.9%, as opposed to the earlier estimated 1.8–2.8%. Organizations must widen their outlook and study the end-to-end impact of IT operations, including that of application software.
Facets of green software
Building “green” software involves improving efficiencies across the development process, deployment, usage, and maintenance. Organizations must put a framework in place to measure the carbon footprint and energy optimization throughout the software lifecycle.
Making the development process green: ‘Greening’ the development process involves improving the efficiency in development and measuring it during the development phase itself. Automation plays a role at every phase of software development and contributes majorly towards greening the development of traditional applications. Moreover, it cuts development time and reduces carbon footprint by optimizing the use of IT systems and human resources. Model reuse and sharing of prebuilt models, model compression techniques, and methods such as meta learning can help in case of AI-based applications.
Organizations must understand the level of accuracy demanded in each case and strike the right balance between accuracy and energy consumption. Using configurable (domain-specific) software products and platforms provides a jump start to the development process. Identifying components in traditional applications that can be converted to AI-based models will help in leveraging energy-efficient accelerators. The ideal way to improve energy efficiency would be to apply energy benchmarking right from the early phases of development. Tools such as TPC-Energy and MLPerf highlight energy efficiency and help in optimizing the application’s energy consumption.
‘Greening’ the software: Framing guidelines and coding practices during the development stage is important to deliver high-performing, energy-efficient software. Best practices and assessment tools will help large teams deliver greener software. One of the key areas to consider is resource optimization—reducing the use of processors, storage, network bandwidth, and time. Resources, especially disk space, are often taken for granted throughout the software lifecycle. Batching multiple work items could be a good strategy to conserve energy, provided it does not violate latency constraints.
Organizations must also consider moving away from cloud to edge computing wherever possible to minimize interactions with a central server and thus, reduce network traffic. Neuromorphic architectures are an emerging area which minimizes energy consumption, since it requires low latency, real-time processing of inputs. It is estimated to be at least 1,000 times more beneficial in terms of energy efficiency.
User experience is another aspect in greening software products. Doing a customer-journey analysis to look at various paths taken by a customer and optimizing individual paths is a good starting point for carbon-footprint reduction. Demand shaping strategies that create demand based on existing resources also help in optimal usage of network bandwidth.
Making operations green: Operations contribute significantly to an organization’s carbon footprint, mainly through the infrastructure and human effort involved. Dynamic shifting of workloads to green hosting data centers using automated algorithms is an efficient way of distributing load across multiple data centers. Shared hosting also helps reduce the overall carbon footprint.
Software maintenance increases the carbon footprint because of the time and resources deployed over long durations. Greening maintenance involves reducing carbon footprint across activities, namely upgrades, fixes, and enhancements.
Organizations must analyze trade-offs when more resources are used to accelerate operations. They must consider efficient utilization of hardware and dynamic provisioning of resources during deployment, without deviating from service-level agreements.
Creating a carbon footprint measurement framework for software
Software indirectly consumes energy through hardware and data transfer. Hence, measuring its carbon footprint is challenging. Getting power logs from virtual environments by isolating individual virtual machines (VM) from large VM farms is difficult. Moreover, cloud deployment does not enable estimation of carbon footprint at an application level and the adoption of serverless architecture further amplifies this problem. Abstraction of predicted power based on resource utilization helps to a certain extent but there are hidden factors which need to be accounted for, such as network transfer and disk input/output transfer. Measuring human effort can bring other supporting resources and logistics into consideration, further adding to the complexity.
Figure 1 depicts a draft framework that encompasses measurement of energy consumption at different levels to arrive at an application-level carbon footprint. The framework uses a predictor to estimate energy consumption using data collected across the software lifecycle. Using a geo-specific grid emission factor and fine-grained data converts total energy consumption to carbon footprint.
Predicting energy utilization at an early stage helps in developing an action plan and reducing the application’s carbon footprint. The framework would be underpinned by a set of best practices and recommendations for adopting greener options. It would also include a mechanism to record baseline measures and set improvement targets. The framework includes:
Data analysis across factors such as time, complexity, methodology, platform usage reuse etc., to get energy consumption during the development process
An application profiler that optimizes the software for energy utilization in terms of design and construction helps setting up energy budget for applications
Evaluation of deployment and maintenance methodologies, including hosting rules, optimum configurations, and resource utilization
Progressing towards greener software
When organizations embark on the path towards zero carbon emissions, it is important to first measure and assess where they stand and then build strategies for a sustainable future. The measurement framework is the first step in creating an action plan. While it helps to understand key contributing factors at every level in the software value chain, organizations must perform causal analysis and consider greener alternatives to reap the full benefits. With the fine-grained view obtained during the measurement stage, organizations will be able to recognize areas where greener energy sources can help and where energy-efficient applications will work better.
Qualitatively bringing down carbon footprint creates a positive impact on the metrics that govern ESG scoring and additionally, reduce operational costs. Consolidating enterprise-wide energy usage is important to estimate the overall footprint as most of the data on scope 2 and scope 3 emissions is available at an aggregate level. Most importantly, standardizing energy measurement at an industry level is a critical step in improving energy efficiency. The knowledge gained will help in benchmarking the process for industry reference and contribute towards global decarbonization.