Coral Calero Muñoz and Félix García

SE Radio 597: Coral Calero Muñoz and Félix García on Green Software

Coral Calero Muñoz and Félix García, professors at the University of Castilla-La Mancha, speak with host Giovanni Asproni about green and sustainable software—an approach to software development aimed at creating software systems that consume less energy and produce less CO2 during their entire lifetimes with minimal impact on their functionality and other qualities. The episode starts by describing why green software matters, particularly in the context of global warming, and introducing the key concepts. Continues discussing the current status of the field, in both academia and industry, and finishes with hints and tips that can be readily applied by development teams to make their systems greener.

Show Notes

Related Episodes



Transcript brought to you by IEEE Software magazine and IEEE Computer Society. This transcript was automatically generated. To suggest improvements in the text, please contact [email protected] and include the episode number.

Giovanni Asproni 00:00:18 Welcome to Software Engineering Radio and I’m your host, Giovannia Asproni. And today we’ll be discussing green and sustainable software with two guests, coral Calero and Felise Garcia Coral is a full professor at the University of Castile Lamancha and she’s a member of the Larco Research Group where she leads the research on green and sustainable software. She’s the author and editor of several books among them. She the Greening Software Engineering and Sustainable Software, both published by Springer. Felix is a full professor in the Department of Information Technologies and Systems at the University of Cast Lamancha and he is a member of the LA Research Group and his a research interest include business and software process management, software measurement, agile methods, and of course software sustainability. Coral and Felix, welcome to Software Engineering Radio. Is there anything amiss that you’d like to add?

Coral Calero 00:01:08 I think it’s okay from now. . Let’s see at the end.

Félix GarcÌa 00:01:12 There’s only thanks for your kind introduction. It’s a pleasure for us to be here today.

Giovanni Asproni 00:01:17 Ah, it’s pleasure for us as well. So let’s get started then. What is green software about and why should we care?

Coral Calero 00:01:25 So basically it’s about defining the relationship between software and environment. Thus we can talk about green buy in, which software is used for environmental purposes. For example, an application to optimize the temperature of our house or greening in which the aim is to make software itself green, for example, to use a programming language that produces energy efficient applications. Now that it’s very important to use software that helps on environmental objectives, but it is fundamental to work on making the software green because there are studies that it estimates that by 2030 information technologies will require the 20% of global energy consumption. So of course it is more than software because it includes also hardware, but they both will be responsible of this huge necessity of energy. While there are a lot of initiatives on green, on green hardware, the worst on green software are just beginning maybe because it seems that software is something ethereal or something similar. But we must be aware that every software is executed in hardware. So the way the software has been built will determine how much energy it’ll require to run. Luckily there is more than one way to develop a software application and the green software aims to ensure that the one chosen is the one that obtains the least energy consuming product.

Giovanni Asproni 00:02:41 Let’s include, it’s a bit of terminology because you know when we talk about green software, the terminology can really be confusing. I read, well I found that a sustainable software green in software, green software, I think you mentioned coral green in and green. Maybe we can repeat that as well. But then there is also green software engineering software, green ability, green it . So can you give us at least find the main terms and help us understand them a bit?

Félix GarcÌa 00:03:08 Yes. Consider that sometimes is also confusing for us because there is a lot of terminology. There is some confusion on the terminology also is normal because the topic is relatively new and there is even no consensus on the fundamental concepts. Let’s start for the highest level concept that is so sustainability, if we use the definition of sustainable development given by our Uniting Nations Berlin report, which is meet the needs of the present without compromising the ability of Q2 generations to satisfy the round needs. So in this sense, software sustainability is related on how software can be developed while taking into consideration environmental, social and economic dimensions so as to meet the needs of the present without compromise in the future. So this is the general concept. So in this high level we are talking on more than just energy consumption, which is usually the focus we developed.

Félix GarcÌa 00:04:00 As a matter of fact, in the last year I studied to determine what software sustainability is and even to the conclusion that there are two different perspectives on the convergence between software and sustainability. The first, which is about making software itself sustainable, can be named software sustainability and its goal is to achieve what we can term as sustainability in software. In this approach, software sustainability has three dimension that correspond to the ones of sustainability, human economic and environmental or also known green shop. The green dimension has been traditionally the most explored, but we cannot forget the importance to take care of the other dimensions, for instance, in the human dimension. And Acton would be to support inclusiveness, ensuring that our software does not discriminate users because race or culture for example preventing the use of filter by race in dating apps or Russia or general algorithm is bias in social networks.

Félix GarcÌa 00:05:00 So we have where software also can have an impact on that. For example, on new and economic and coming back to the second perspective, we call this software as part of sustainability and it considers software as a new dimension of sustainability including the interaction of software with the other dimensions on sustainability. In this case, even we can find different proposal from four to seven dimensions in all the cases. The definition includes the theory I mentioned of sustainability, human economic, environmental, but depending on the study others are added. Of course. More details about this, can be found in one of our work, named so sustainability and in United Nation sustainability development goals. So sustainability has in any of the two approaches, one dimension devoted to green shop. We have already explained the difference between greening and green software, which is the other way to approach content. And of course we can also corresponding concepts related with hardware such as greening hardware. An example of this is to design for example a processor more energy efficient or green by hardware for example, to build a device that controls the water flow of a garden to optimize its use. So both software and hardware make up the information technology field. Also we can find there green information technology and green bay information technology.

Giovanni Asproni 00:06:22 And when we talk about the green software engineering is in this case is how we approach software engineering keeping consideration green

Coral Calero 00:06:30 Exactly.

Giovanni Asproni 00:06:31 Well green requirements if we can call them this way. So keeping the software green somehow or consuming fewer resources or there are other aspects on that,

Coral Calero 00:06:40 How to apply all the life cycle steps considering the green aspects of the final product.

Giovanni Asproni 00:06:47 So we are talking not so only the final product, the greenness of the final product, but also the greenness of how we produce the product. So I donít know exactly the energy consumed to run the CI bills.

Coral Calero 00:06:59 Yeah, not only this but for example the methodology that we use for the development or the programming language or this kind of things. So it’s not only to take care on the consumption that the final product will have, but also how this product has been developed during all this, the lifecycle phases. Okay, and

Félix GarcÌa 00:07:17 This is but how also has an impact on the environment exactly. For example, in highly automated environments,

Giovanni Asproni 00:07:24 Do we have an estimate on how much energy we could save with, using green software engineering principles? Are there any estimates out there?

Coral Calero 00:07:33 We cannot say this final figure just for software because all the numbers that we have is, is related to information technology as a whole. Okay. And the problem also when we talk about green software is that we don’t have just a kind of software or, so it’s very difficult to generalize to try to have this final number. So depending on what we focus the software engineering principles and the practices to safe energy, we need to adapt what we want. Okay. So I’m going to explain you a couple of examples that we have related to this and the fact that really to do the things in a given manner impact on the final consumption of the product resulting. Okay, so the first case I’m going to explain is about data compression algorithms is related with one of the big problems we have, now with the software is the data.

Coral Calero 00:08:27 Okay? So data compression, the algorithms has an objective to compress the data, the collection of data in order to have to save space. Okay? So you can have the same data but with less space. We have worked with the people from here in Spain because they define algorithms for compressing data, but with the particularity that you can use this data in its compressed form. So it’s not necessary to decompress the data to use them. Okay? Of course this implies savings in size and also in time to access the data. But what we wanted to know is to evaluate if the difference of energy efficient of the energy needed to access the compressed data were similar to the savings in time. Okay. Compare with the collection, not compress it. So we evaluated the difference needed to search on an original text and compressed and in the same text but compressed using one of their algorithms called end target dense code.

Coral Calero 00:09:31 Okay? So what we did was to to search to do searches on both collections and as a result we found that of course the consumption was lower when the text was compressed. This is logical, we have less data to access so the consumption is lesser, but the important thing is that mingle the size savings when the compressing data was around a 30%, the energy savings arrive until the 50% of energy. Okay? So the percentage of savings in consumption are greater than the savings in the desserts in the size. And this is very important because it’s a way to explain people that it’s good to find how to manage the data and maybe the data compression algorithms can be a solution because there are a lot of savings on of consumption having the same functionality. Of course

Giovanni Asproni 00:10:25 That’s interesting because it’s also really you save on consumption but also you save on time as well. So well on space at least. So there is a kind of, there is an incentive somehow to use that outside being greener.

Coral Calero 00:10:40 Yeah, of course you are saving space, you are saving time, you are saving energy, all these are saving some money. This is clear and you are not losing functionality, which is very important also because you can do exactly the same that you do with the uncompress data. So these kind of recommendations are the one that we want to explain the people that there are other ways to do the same things, but taking into account this the consumption. I can also present you another example. This time is with spring. Spring is a server site Java development framework. The thing of spring is that it reduces the time to market of new applications, helps developers to save a great deal of development time and improves the productivity of the, of the developers. At least they say that this, this is why , spring is very, very used.

Coral Calero 00:11:27 So the study we did, our objective was to discover whether all the advantages of spring were also AC combined by good energy consumption behavior. So we have developed three different applications with same applications with the same functionality in both cases developed with Java. But in one case we used also spring and in another no we used just Java. So from the point of view, the execution time, it seems to be better to avoid the use of spring. Okay? So the execution time is worse in the applications developed by using spring. If we focus on the energy consumption, the use of a spring is not positive neither for the hard disk and nor for the computer, the whole computer. But it’s especially negative from the point of view of the processor what the consumption of the spring version is greater, much greater than that of the non-spring version in all the applications we developed.

Coral Calero 00:12:21 And this is very important because this put on the focus, something very important is that the software industry must take into account not only the benefit of using these kind of frameworks, only thinking on developing time of the time to market. They need to also consider the negative aspects. For example, this case the consumption of the final solution. And of course for the people that develop the ki this kind of frameworks, it’s mandatory to make them aware that they need to work on these platforms and consider for example, green aspects when they evolve in their products. So there are a lot of lines of work.

Giovanni Asproni 00:12:57 Yeah, that’s interesting. That’s interesting. Definitely interesting because bring, you know, and other frameworks may be similar, ones are widely used in the industry but people don’t necessarily realize what the other, the side effects of doing that. Thank you for that is I think our, listeners will be really interested in knowing this .

Coral Calero 00:13:15 Maybe they don’t like this butÖ

Giovanni Asproni 00:13:19 I’m sure there could be some people that like spring and they are be disappointed and some others that don’t like and say I told you so. Developers, you know how programmers, how we are.

Coral Calero 00:13:28 Yeah, yeah.

Giovanni Asproni 00:13:29 What are the metrics that of standards that are commonly used in the industry to measure the impact of software from a green perspective? Are there any,

Félix GarcÌa 00:13:39 For us this is a critical point. You know, one of the basic principles in software quality and measurement is that we cannot control and therefore we cannot improve what we cannot measure. So this is for us key. So if we look at the market and we can find approaches to software, energy conception measurement, which are mainly of two types. Hardware based is to say using hardware, measuring instrument like for example a power. Of course with this you can provide more accurate and realistic conception measurements, but you have other possibility as, which is to use, estimation models mainly supported, by software tools. So of course these last are more accessible for users who intend to conduct energy evaluation of software. But in the counterpart, they provide the less reliable and accurate results on of energy conception as compared with the hardware devices. One well known software tool for this for estimation is rappel, which takes advantage of the capabilities of modern intel processors to estimate the energy conception and to obtain different values about the overall, the different course the memory included also in the processor. So you can obtain a lot of data about that but it’s estimation.

Giovanni Asproni 00:14:50 Okay. And so I guess this looks like is, we are a bit at the initial stages of creating this instrument because I could imagine that a usefulness would be not that much on the PC, but maybe in data centers machines that, and with the ability to maybe measure not only the processor but also split by which virtual machine is using how much and then maybe within the virtual machine, which processes. So from what I hear since that there is a lot of ground to cover to get there.

Félix GarcÌa 00:15:17 Yeah, data center is even other field in the sense that there are a lot of advantages, specific advantages in order for example to measure data center and there are specific metrics for data centers, but in this case even it’s difficult to isolate the specific , conception of a software application which is running a data center. So our idea with this kind of experimental laboratories is to help, software practitioners also to try to understand better the specific impact of the pieces of software they are testing there.

Giovanni Asproni 00:15:45 Okay. This interesting because I guess these, make kind of exciting times for searches on this because seems to be pretty much at the beginning.

Coral Calero 00:15:53 Yeah, yeah. In fact another problem is that usually most of the solutions that say that they are measuring consumption, they are really estimating. So this is a little bit dangerous because they don’t provide real consumption, real measurement. So you are taking decisions in data that are not as really reliable as desire. And also we have the problem of the standardization because we don’t have a standards of course we don’t know how to measure, imagine to have a standards . So maybe the standards, the most similar standards must be the one of the ISO related to software quality because there is a kind of relationship between the energy efficiency of the software quality. So maybe this standard can be used in somehow something is not a standard. But this, generalizes is the blue Angel. Blue Angel is an initiative of the German government. It’s developed by some researchers, but what they want is to define an environmental label for resource and energy efficient software products.

Coral Calero 00:16:57 And they are working on this. They work also on the process that includes things like the choice of technology, the programming languages, databases, all these kind of things and idea behind the blue engines. A good idea is to award this label to software products that demonstrate to use hardware resources in a particular efficient manner. In any case, we are not so convinced about the label because we think the topics is not mature enough and there are a lot of things to take into consideration before be able to define this echo label. But we think it’s, it’s a good point of start and these initiatives are necessary to add advance on the topics. We have also Green Software Foundation, the Green Software Foundation is a nonprofit organization based on the USA. This foundation has a objective, the creation of an ecosystem of people, standards, tooling, best practices to green software.

Coral Calero 00:17:49 They have not still proposed standards, but at least they have specific working group on it. So taking into account the people that is here in this green software foundation, they are 58 member organizations like Accenture Global and Microsoft Entity data and a lot of people more so we think they are on the way to have these standards, but maybe we can use them as a first step as a industry proposal to use them as basis for the creation of general standards by used by the regulatory organization. So we have not the standards, we have not a final model to be used to label software products, but at least they start to be initiatives, and this is very important.

Giovanni Asproni 00:18:33 Okay. Now you mentioned, we already mentioned cloud computing data center. So what is the role that data centers and cloud computing play into, you know in green software engineering?

Félix GarcÌa 00:18:44 Yeah, this is a very interesting point which is of great importance nowadays, you know, even the increasing demand of cloud computing resources. So now many business businesses which are being digitalized in cloud and need hosting in data centers and the users, of course the users have to access to these services or to these business functions by using a large variety of devices, laptops, tablets, smart phones, so on. So the resulting energy conception has to be analyzed from all the perspectives. If we go to the data center site one key point here is that obviously if you optimize your data centers, you can reduce its carbon footprint and cloud solutions providers are expected to be specialized in a suitable management of their data centers to achieve the same. So for many companies, moving to cloud solutions would imply a positive impact on the green dimension.

Félix GarcÌa 00:19:37 Let’s for instance, think about a company managing its own data center or more to the cloud. So traditional data center management implies that it must be planned and implemented the computing storage and other resources in unanticipated way to support the spec’d workload demand. Usually this can involve providing and deploying more resources than actually you need, which also involves cost or runs. So companies are seeking to reduce this by moving to the cloud with the models as for instance payo. That is to say you only pay for the resources you’re consuming, which of course you can configure in a responsible way. And then the cloud providers also can give you the needed flexibility to satisfy the workload demand. So the results from an environmental perspective can be positive as companies are better tailoring the cloud services to their needs. And on the other side, specialized cloud providers can manage their data centers from energy impact viewpoint.

Félix GarcÌa 00:20:37 So even some solutions offered by providers use artificial intelligent algorithms, for example, to do vertical and horizontal scaling depending on the real time application demand. So as a result they needed visual machines, containers, databases and storage are always appropriately sized to this demand. So these providers have the specific knowledge, the specialized knowledge needed perhaps to obtain also great improvements in energy. And, of course also there are some efforts now to reduce the impact of cloud providers. For example, Amazon or Microsoft are part of the climate plate a commitment to reach net zero carbon emissions by 2040. Another relevant example of course is Google, which has the sustainability initiative among others for poor wind net zero emissions across the Google operations and value chain by 2030. So in this sense, Google plans to operate their data centers and office campuses on 24 7 carbon free energy for example by using solar and wind energy. Moreover, Amazon services cloud has an emissions calculator that allows, its customers to see their impact on what they upload at and use of a on cloud infrastructure. And other providers of course also offer similar solutions.

Coral Calero 00:21:53 But let me please Giovanni to put I now the bad cop because yeah, Felix has called about all the good,

Félix GarcÌa 00:22:00 This is the happy view now ,

Coral Calero 00:22:03 But it’s not as I situation because despite all the advantages of data centers that Fells has already mentioned and all the efforts to reduce the electric electricity needs and the zero emissions and the alternative energy resources and all these things, there is an estimation that quantifies the electro usage in data centers growing 2030 to almost 3000 terabytes hours, three times more than right now this year. Okay, so seven years, three more times or energy requirements for the data centers. So we have a problem and it’s because there is a, a DIGITALIST magazine that claims that we can cut huge amount of emissions but moving to digital. But all those digitized services still require electricity to run. They can be greener. But what about all those that centers that are not worry about their consumption because there are a lot of data centers that they don’t thinking on alternative energy sources and all these kind of things.

Coral Calero 00:23:05 And here we have a problem, we need to make people aware of these people of the data centers. Okay, I want to remember the data that we gave before that in 2025, every day 463 exabytes of data will be created daily and of course all this data must be stored and managed and this go mainly to these data centers. So we have a real problem with the consumption, so we need to take this into consideration and then when deciding for local cloud solution to consider also the consumption derive of the network traffic, if they have good, solutions for the energy consumption and all these kind of things. Because with data we have a problem despite all the positive things that we have mentioned.

Giovanni Asproni 00:23:51 So a question now since we are introducing, we are talking about, so companies maybe that care about power consumptions. So for example the, I can imagine Microsoft, Google and these companies Amazon caring a lot because basically that is also business. I mean the less they consume, the more money they make to provide the same services. So they have a big incentive to actually act on that. Yeah, so I think in the news we often read Google or Amazon putting data centers in places where they have access to greener energy or we use less of it because the place is really cold. So they can actually cool down the data centers using less power and things like this. But then, you know, for other companies, let’s say they use these data centers. Yeah, what would be the advantages of investing in green software for them? Because I think this is a crucial point. It’s like if they have to spend money to make the software greener, I don’t see any incentive there to actually go green. Yeah. So what could be good incentives for that?

Félix GarcÌa 00:24:52 Yeah, many times also we discover that companies are greener because they are trying to save money and when they save money as a result, also the solution is greener. So this is a typical scenario also. And what about the other side is okay, I try to be green and as a result I’ll try to save money also because I have to invest, but also I can perhaps do a better use of resources more efficiently and as a result can find some incentives to do that. For example, we can find the number of clear advantages for software companies to invest in green software. The first is that, if they make their processes green, they’ll directly obtain savings in their energy. So in addition, if they develop energy efficient software products and solutions, they will be positioning themselves against competitors, offering the users something different.

Félix GarcÌa 00:25:42 And this different will go hand in hand with an aspect of great concern to society, which is to protect the environment. So at the end also companies need to move towards obtaining greener solutions and sometimes also they can be obtained by option or for cloud solutions. Sometimes it’s related. If I move to cloud, perhaps I also obtaining some advantages in order to create a greener products as a result. So this also connect with a fair advantage, which has to do with the company reputation. So it’s clear that with the sensitivity that assist today with environment promoting environmentally friendly products and services make the brand clean and increase the reputation. So there are many reasons for example for a company to be green and of course in the how and also in the what in the result in the service as a result. And this contribution imply an increase in production costs which probably be reflected in the final price of the product or service.

Félix GarcÌa 00:26:38 As a consequence, however, we’re convinced that this is a profitable investment. If you go for green, you are making a good investment. Why for example, let’s consider when a user goes to buy a refrigerator in addition to the functionalities and the price. Many times we look the information about energy efficiency of the refrigerator and also because it’s affecting to our consumer conception as user. So my final decision to buy a refrigerator in not only the cost or the price, I consider other variables and I try to obtain or to seek a balance between all the information provided to take the decision. So this ecolab is an important part also of my decision. So we should also advance in this sense in for software products because this will also help companies to invest in a stronger way in order to be greener in the in the solution.

Giovanni Asproni 00:27:31 Okay. So in a way this is also a contribution that users can give. It’s like they know that some software solution that solves their problem is greener than an equivalent one that might become parameter in the choice is the example in the fridge. Let’s say that you are asked to give some advice to software developers and development organization that want to look to prioritize sustainability in the software practices. How should they get started with that?

Félix GarcÌa 00:27:57 We have to start from requirements from the solicitation of the requirements. So there we have to include our specific requirements related with, for example, a power conception or energy conception. So as much as possible, and generally speaking, all the software lifecycle states must incorporate decision driven by these green requirements. For instance, choosing the best combination of compiler programming language to fulfill these green requirements adopting suitable solar architecture. We think into account these green aspects or applying the green design patterns or apply green refactoring or optimize my code consider and also the impact on energy of course, and these are only a few examples, but the most important thing is to be aware that green requirement or more in general even sustainable requirements must be also fulfilling decisions must be also in accordance with it. But we have to take decisions in accord with the requirements.

Félix GarcÌa 00:28:52 Of course this also requires a suitable infrastructure and tools in order to help developers to make better decisions and be informed about their impact. As engineers also we have to measure, and as we mentioned earlier, the engineers has to be aware of the impact of their decisions. So they need data, they need data about the energy so they can try, they can test their solutions in order to build greener ones. And in this case also perhaps in, in our opinion, it can be interesting to follow kaizen principles like in process improvement is I try to do a small change, I evaluate and I see there are improvements in energy. So you don’t have clear guidelines to do that perhaps I can find something I can check, I can try measure and then improve. So we’re starting also with that. And then in the research community there are a lot of studies in which is to provide developers with some guidelines. For example mentioned some studies also, for example, if we talk about design patterns, there are some studies which demonstrate, we design pattern can be better from energy point of view than others or patterns in the code that can also affect to the energy consumption. For example, duplicated code for duplicated code sometimes involves also impact on energy. So developers, we can provide developer with this kind of guidelines, but there are a lot of things also a lot of knowledge to discover it.

Coral Calero 00:30:15 Yeah, I think I have another comment here that it’s very important to have the developers involved on this green software, but if we want to have real results, we need that the developers are AC by the company. I mean green must be part of the business processes and the companies must to bet for them and like this, they will provide the developers with these tools that Felix mentioned and the specific measures for the software they develop. So it’s a whole, we need everyone involved on this. We need all the people that can have a responsibility into the software development to be aware and to want to go for the green software.

Giovanni Asproni 00:30:54 Okay. There are some, Felix mentioned all you know, engineering and we need to measure this, but is there a way that for example, we can use something today, I donít know, we mentioned before, estimating consumption somehow. I think that in the green software foundation there is also formula for to kind of estimate the carbon impact that is based on numbers that usually can be taken from somewhere. I mean is still an estimate so there is no precision there. But would be that a good starting point because I’m asking this because I can imagine, you know, having a formula that gives me a reasonable estimate and something I can test my software against would be actually helpful to me as a software engineer to at least maybe not have the most green software ever, but at least to do software that is greener than it used to be and also have something that I can actually use in my requirement process and engineering process to as a reference.

Coral Calero 00:31:46 Of course it’s better something than nothing. So yes, there are not only in the Green Software Foundation, there are also some industries that use these kind of indicators that are mainly user on estimate. The problem is that what you have said, this is very, very strange things for me. It’s difficult to have a general indicator for the green software in general. It’s dangerous. So maybe it can be a good point of start, but we need to go on and of course it cannot be the only thing we need to measure to have real measurements because if we want to improve a software, we need to know which part of this software is the most consumer in all the code, for example. And to reengineer this part and have it greener the thing in the requirements is one of the parts most develop it into the green silverware topic.

Coral Calero 00:32:34 Maybe because the intuitive idea to align energy efficiency with something related to the quality of the software and relating the energy efficiency with enough functional requirement of software. So in fact, one of the first workshops that that was on this topic was exactly, precisely about sustainable requirements for software into the requirements in engineering conference. So this is a data, so it’s possible to find in the literature a lot of approaches to classify and relate quality and measures define catalogs of sustainability requirements, interactions between quality and energy efficiency. A lot of works, but most of them are , very focused. I mean some of them are general but in the sense of analysis but not as a, a catalog of general software sustainable requirements and we need to work on this. Even the concept of ecological depth has been defined based on the technical depth but related to the energy consumption of software. So yeah, there are efforts but I think that again more in a research step than in a production step. So it’s necessary to systematically eliciting, analyzing and document the green requirement, including the energy consumption as in the green software process, the software engineering process, I think we are on the path we’ll arrive, but every industry need to work on their own requirements and the catalogs of sustainability requirements.

Giovanni Asproni 00:34:04 Okay, so what I’m understanding is there isn’t really a good way yet to measure that, at least a way that is precise. We have some ways of estimating this, they are not very precise, but maybe even if we start from there, at least we start somewhere, we can start improving the situation. So I guess at least we have an indication that you’re going the right direction. The reality is that we don’t know how much we are going into that direction at the end because it’s an estimate, there is no precision then as you say coral, you cannot really have one measure for everything because of the complexity of of the field. So there is a lot of work to do, but we can start doing something at least.

Coral Calero 00:34:43 Yeah, I think it’s good to start estimating at least as a first point of view start and to know your systems and to way of work. Where are your weak points in the development and in the consumption you don’t have the real information but at least you have some indications and if you want to use some kind of indicator, maybe it’s good to try to adapt to your reality because these general indicators for me are a little bit dangerous. But yes, you can use it if you don’t have another thing just to have a first impression on how you are where you are. And from there trying to go to advance on the on the way.

Giovanni Asproni 00:35:23 But I think that is really important to know that there is something we can do now and start doing at least it’s not going to be perfect, it’s not going to give us accurate information, but at least it’ll give us a trend if you’re improving or not. And then since we’re talking about engineering and cold quality and all this stuff, and now a question that for me is actually quite an interesting one. It’s researching for around green software and sustainability. So I found out that some software design architecture and development practices that are good in general, you know for cold quality somehow or for systems probability are good for green ability. You know, things like caching data close to users, good for both delete and use resources. Yeah. So instead of leaving queues and things hanging around, clean it up, it’s not only save money from, your cloud provider but also you save energy.

Giovanni Asproni 00:36:16 All these kind of things that seem to be kind of obvious but then reading some studies, some of good practices seems to be at odd with green ability and this is where the engineering bit start to become interesting. So for example, redundancy of systems to improve availability. Yeah, so it’s basically a bit over provisioning. So the system does not go down and it’s, it’s more available but then consumes a lot more energy or a coding level. Good code practices like modularizing a god class. So God class, A class that does a lot of stuff too much. I found one study in, I think in one of the books I think in the green software engineering book and an article in green software maintenance when they run an experience said let’s see if having this gold class thing will refactor it into a proper modular code that is much better for maintainability what happens from a power consumption point of view. And they said, oh gosh, how is consuming much more energy? So these are the aspects that I find interesting because it’s where the engineering decisions need to be made. And I found also in other books saying, well actually modularity is good because on the process side we’ll make it easier to maintain code and make changes. So somehow consuming, fewer resources from another angle. So what should we make of it? what a developer on day-to-day work, what should they do? Yeah.

Félix GarcÌa 00:37:35 Yes indeed. This is something that the software engineers and developers have to deal with constantly. You know, even not considering energy in the software quality field. Sometimes if we improve usability, perhaps you’re decreasing the, the security for example. And of course if we now include energy in the equation, now the situation, the complexity also increases. So this is what we know as straight off at the end when we are working also our quality and now considering energy also we have to make trade of decisions. This is the point. And what we can have to do is to try to analyze these interactions that can analyze half the different requirements. For example, as a matter of fact, some years ago we conducted a atory study about possible interactions between software quality characteristics and sustainability. This in this context we must understand interaction as a type of dependence between two or requirements that , have to be satisfy simultaneously.

Félix GarcÌa 00:38:34 Simultaneously in product. As for instance, for example, I have to fulfill security and usability and as I commented before, perhaps if I have to promote one, I’m getting worse in the other one, of course green ability should be also part of it. And in our studies we analyze these interactions between quality and sustainability. For example, we analyze two dimensions, the how and the what. So the process and the product, for example, from process perspective, many researcher studies they the process perspective only considering the facts or bags of fixing. For example, in the sense if I eliminate more bags in my software, perhaps the quality of my process is better quality. So if we also extrapolate this to energy con conception, these studies report that the correction of major packs usually lead to lower power consumption. What is logical and, but is common that energy related code chains tend to be larger than fees.

Félix GarcÌa 00:39:30 A back for example is I try to change my code in order to turn into greener. Perhaps my effort is higher as compared for example the typical process of defect or back fixing because energy effect or can affect to not only a specific module for example in which I discover the back, but energy is spread across different software models. The impact on energy can be explained by the fact that every, asset of models which interacting are affecting to this energy. And from product quality perspective for example, we also analyze this possible interaction. For example, let’s compare functionality and energy is expected. That functionality of application is directly proportional to energy conception in the sense more functions as software product provides more conception. So other example is privacy. Privacy perhaps will have a negative influence on sustainability because I have to add more components, more code in order to support usually these privacy requirements.

Félix GarcÌa 00:40:29 So as a result, perhaps worse in the energy. So at the end, this is an example of trade off. I have my application has to fulfill its privacy, but how much privacy in the sense that the needed privacy in order also for example to be greener. So this is a trade of decision I have to find good balance between, for example the privacy my system has to have with regards to the energy as consequence. So there are a lot of examples in this sense. For example, as you mentioned Giovanni refactoring, refactoring is not always good for an energy viewpoint. In some studies central factor techniques have a negative impact on energy efficiency. For example, simply due to the fact that if I have to add new methods and new classes for something, I increase as a result the number of messages between objects and as a result my system may consume more but only applying refactoring.

Félix GarcÌa 00:41:22 So what we can do provide guidelines and to help to make these tradeoff decisions in the best way in the sense that okay, take care, take care if you apply the refactoring technique, take care about the number of messages or take care about the number of , new classes you’re included in your system. So at the end, this is the point we have to find a right balance. So what this would also is that in community research and, even practitioner community, yes there are some refactoring techniques and some mechanisms are , being proved to be useful. For example, ization with what we commented about the cache or to store the results of, highly computational functions. So instead of calling a function which is very heavy, very energy demanding several times perhaps I include the results in a cat and when I have to go back to this function, perhaps I can retrieve the result from the cat and avoid necessary calls to these heavy energy functions. So we can find what is good of this is that, we can find good mechanisms and we can evaluate them and at the end as engineers and as I told before, I could, make the best decision but the tradeoff is present always.

Giovanni Asproni 00:42:34 This looks like some of the work that I saw in the Green Software Foundation where the patterns page basically evaluating some ways of doing things that are considered good ways but then at attaching the green warnings about the cost to me looks like that we have to somehow reevaluate the good practices or what they are considered good software engineering practices in the eye of green ability and green software and sustainability I guess you know in a way that is perhaps similar also to, I donít know security, security we know a lot about what is good or bad because it’s been the focus of a lot of research and lots of grief also for many companies. And I guess we need to do something similar in the green space.

Coral Calero 00:43:14 Exactly. This is the point. We need more research and we need more practicing industry to have these guidelines, general guidelines that can be used by anyone who develops software and use this kind of technology. Of course at the end, if you have these guidelines, these good practices, green good practices, then you can make your decisions when you are the developing. And this is the point, we are not there but we are going because

Giovanni Asproni 00:43:41 Yeah, but there are, I’ve seen already some recommendations. Yes, not for everything but we’re starting again.

Coral Calero 00:43:47 Yes, yes, yes.

Giovanni Asproni 00:43:47 It seems to be a very young field at the moment. Yeah. Even if it’s been around for a few years, but probably not with the strong focus that you have now.

Coral Calero 00:43:55 Yeah, but you know also because we had not the devices to measure not estimators. So in a lot of years of the topic have been just for defining the things and to understand the things and now we have the estimators and some devices to measure and this is a point of inflection let’s say. I think in our studies we try always to, as a result to provide this kind of guidelines to generate this guidelines to later, be used in the software industry because if we are measuring having conclusions, it’s also to have lessons learned and these lessons learned and this guidelines we think we can give something important and interesting to the software community.

Giovanni Asproni 00:44:40 Okay, now my next question is something I must ask because it’s, part of a programs favorite if you like. So about programming languages there languages that are better than others for green software.

Coral Calero 00:44:53 Before going to the answer, do you have any idea of which language can be the worst or

Giovanni Asproni 00:45:00 Not good enough? Surely not the ones I use. .

Coral Calero 00:45:05 Okay, maybe Felix can explain. Sir.

Félix GarcÌa 00:45:10 I hope we’ll have no new haters after our answers to this, to this question because now there are studies about that. But this for which is very good for programmers is that they have choose among a white variety of programming languages to meet their objectives. Sometimes the programming language to be used perhaps is a constraint of the project. Perhaps it’s imposed by the company or by the client. But many other times you can choose and the choice of one language or another can affect also the green aspect. And what are the criteria? There are a lot. For example, we can distinguish between technical and non-technical factors in order to choose a programming language such as the structural level is important, the structural level because as we’ll discover usually the best languages are lower structural level. So at the end for program is not easy to apply them for productivity for example.

Félix GarcÌa 00:45:58 So a structural level project domain for example is your programming the front end, the backend or your project is of data science. So another factors of course are related with a learning curve. The system documentation of the language, the supporting libraries included the language for their purpose and even a lot of factors. So this choice of a suitable programming language or a set of them because you know some projects are not composed only of components of implementing in only one programming language is an important decision that can impact productivity quality and of course the green dimension. So if we focus on the green dimensions in the same way programmers are choosing a language for performance requirements, these energy conception requirements should we also included in the selection criteria. So this is important again awareness. So when I have to choose a language, let’s consider also the energy impact. So of course on our site, what is our work to provide programmers with the studies in different scenarios of application so they can make the decision supported by evidence.

Giovanni Asproni 00:46:59 And so have we got any languages you can mention?

Coral Calero 00:47:03 . Yes, yeah. In fact there is a complete study did by people from Portugal. They have made, they analyzed the energy consumption of 27 programming languages of algorithms that they took from a benchmark. So with the results of the consumption they elaborated the ranking. Okay. Before the results, just to give some more emotion, they used an estimator. I think they used rap L for the results. So in the top, the best programming languages are C++ and Java and Bacal. These are the more respectful. On the other part, the languages we higher consumption are Ruby, Python, and Pearl. So in general the interpreted languages are more consumer than the compile in general. Okay. So we have another interesting result of this study is that not always the fastest solution is the most energy efficient. So the energy consumption is not related with time.

Coral Calero 00:48:00 This is very important because usually people think, okay, less time, less consumption. And this is not always true, okay? In this case for example, it’s not. So we have replicated this study, the people from Portugal, but using our measurement device and we have the same classification, more or less different values for the consumption, but the same for the ranking. Let’s say there is another aspect to that we must take into consideration and is the compiler the use of compilers and interpreters. Okay? So these are the results. This means that the people that uses Python need to change to another programming language. So maybe it is not the solution, but maybe they can start to change and try to know if they have very high computational problems to solve, maybe they can move to other programming language. Okay. So it’s not to close the industry and to start from now from scratch everything, but to evolve to another programming language.

Giovanni Asproni 00:49:01 It’s also fair to say that I know that for example, Python is used a lot in, data analysis in ai, but also Python has a very good interface with C. So there are plenty of libraries that are actually very efficient in Python because they’re written in C and they’re used very easily from Python. So it’s one of those situations where actually the context matters. Yeah. So you can write lots of your code in Python. Yeah. But then the computational intensive bits are done by native libraries. So at the end of the day in practice, your code might be actually quite green. Yeah. In the sense that the bits that you’ve written in Python don’t have such a big impact overall. Yeah. So I think that it’s interesting to know this thing about the languages, but it’s also interesting, important to know that is a, the test is a specific context. So some algorithms in the language and the context of using different projects may be different. And so it is important to know that so people can make informed judgment. Yeah.

Félix GarcÌa 00:49:59 In fact, in our experiments we noticed that for example, there was not the same energy efficiency of the programming language on all the algorithms we tested. So perhaps in one algorithm, programming language was better than another from an energy point of view. So at the end’s very important to consider the context and of course also it’s not only just about the programming language, you have also to consider the compiler or interpreter also mentioned because sometimes I need python because um, for example, I’m not an expert in C or in C++. And for productivity my project, I’m using Python because I have the libraries. I need to fulfill my requirements. So at the end what I can do perhaps Python in our results only the results from the study of port, our study is one of the worst. So at the end, perhaps, okay, I need Python, what can I do? Let’s choose a good compiler in order to mitigate this effect on energy. So this again is a combination programming language with, effective compilers in order also to yeah,

Coral Calero 00:51:01 The

Félix GarcÌa 00:51:02 Solutions, yes. Context, environment and so on. And also I like to remark one of the points mentioned by time because in the certain communities, very usual for us because for example, when we analyze studies from 10 years ago or more than that in which they mention green, sometimes they mention green, but at the end they are not measuring the energy because they only mention, okay, my solution is faster in time, so it’s greener. So at the end of course, many solutions which are faster in time are greener because in the equation we have energy consumption owners equal to, time, multiplied by the energy. Of course, yes, time is important in the equation, but this not only the only variable, there are a lot of other studies, especially in concurrency systems in which in short time perhaps you’re doing a very intensive usage of resources, which at the end is producing, more energy, more energy than slower, programs.

Giovanni Asproni 00:51:58 Yeah. So you can basically be saving energy by going parallel, consuming a lot, but for a short time. So the time saved is so much that actually that overall energy is less. I guess that is the kind of one of those rules where if I’m faster, I’m greener is kind of a lot of time is correct, but not all the, all of the time and people make the mistake of considering it correct. Always.

Coral Calero 00:52:21 Yeah. Because if not we have the solution, it’s just a matter of time.

Giovanni Asproni 00:52:26 True. Yeah, true. Wouldn’t be so difficult. , you know, just make, now I want to ask something big that is obviously mandatory nowadays and I know that you have something to say about it is about ai Yeah. The impact of AI on green software and sustainability. At the beginning you mentioned a bit about that. So the fact that AI is actually a large consumer of energy and let’s see. So we know that can consume a lot, so we can talk a bit about this, but also I’m particularly interested in knowing how we can use AI to actually overall reduce the consumer of energy if it’s possible.

Coral Calero 00:52:58 Yeah, this is a good point because artificial intelligence can be used to help to reduce the consumption of any aspect. So in that case, we are talking about green by ai, okay? But we have also degree in AI is how to program and how to work with the artificial intelligent algorithms in order to make, , good solutions from the energy efficiency point of view. So these are two perspectives, very important. The thing is that there are a lot of efforts in Green Bay artificial intelligence because it’s a good solution. Of course it’s a very computational solution to solve problems, to manage a lot of data and have this kind of learn knowledge, but we cannot make the artificial intelligence the problem if we want to use it as solution. We must to be sure that artificial intelligence is not contributing to the problem. So that’s why it’s important to work on the green in artificial intelligence.

Coral Calero 00:53:59 There is a study which estimate that training computers to learn human speech generate five times the level of CO2 emissions of an average car during its entire lifetime. One training algorithm, five lives of a car, just one algorithm, just the training. So we have a problem here and the thing is that again, we go to the trade off, we’re asking the artificial intelligence to solve almost of our problems today. They are able to manage a lot of data and they can go to good solutions for a lot of problems, more or less important. So the artificial intelligence community is to solve the problems, but they are not aware of the consequences on how they are doing it because they are trying to maximize the accuracy. For example, to maximize the accuracy means to increase a lot of the computation. To increase the computation means more energy efficiency.

Coral Calero 00:54:58 So if I am recommending a film to watch on Netflix, maybe it’s not important to have a precision of the 99% on the recommendation. So just to go down two or three points on this recommendation may save three times of energy consumption. Okay? Of course, if I’m trying to help the doctors in the health system, in that case, I need to be very accurate because the result is important to be applied. Okay? So here is where we need to play with this balance between the accuracy and the amount of resources that I put on the algorithm of artificial intelligence to give the solution that way is how we can avoid to make the artificial intelligence to also be a problem.

Giovanni Asproni 00:55:46 Okay. And then now another thing that I think is important, I mean, what are educational institutions, maybe also the industry, if you know, what are they doing to actually educate software engineers on green software, green software engineering in all these aspects? Is there anything happening in that respect?

Félix GarcÌa 00:56:04 Unfortunately, for the moment, we don’t know this special efforts in academy right now to incorporate these skills. Of course one part, this is normal because, you know, as we have been talking now sustainable always feel relatively new with many challenges to face. So for, for instance, it’s more difficult now in in careers or in academics to introduce green software design or coding in the curriculum. If there are not the required guidelines, we don’t have the required supporting tools and so on. So it’s more difficult. But of course we have to start to promote this also. So it’s positive for example, that sustainability is being incorporated more explicitly in relevant bodies of knowledge. For example, computing curricula. For instance, the ACM software engineering curricula version of 2014 only mentions sustainability as a general outcome, but it’s not included explicitly. But for example, if we look now at the current be version of 2023 of computer science curricula sustainability proposed to be part of a knowledge area, which is named society ethics and professionalism.

Félix GarcÌa 00:57:08 So what we can expect here is that perhaps the curriculum also for solar engineers will give this importance to sustainability in the next update. So we noticed certain movement in this direction, which is wood and how to incorporate this knowledge in our curriculum. In our opinion, we have at least to take all the management and technical perspective management in the sense that you have to manage your projects considering sustainability. And for example, well-known the bodies of knowledge like PM book, the project management body of knowledge also recognize sustainability as an important part in the, in the management of a project. And on the other side, from the technical perspective our opinion is that perhaps this is not a question of, for example, designing a new curriculum about green software. The point is, for example, to include this green concept of green techniques and tools in the necessary knowledge areas. For example, in design, if our students are, learning about how to design to build a software which is more maintainable in the same sense we have to educate them to build this software in a greener way. This is only an example. So at the end is to incorporate these techniques and these tools when they are more mature in the curricular, in a normal way, not creating new contents or in this sense or new subject or something. Of course, what is needed is the same subject specific on the fundamentals. This is important.

Giovanni Asproni 00:58:35 Yes. And then I guess the last question I have, so the future of greens and sustainable software perhaps maybe mentioning is also some projects you are involved in. What do you see happening say in the next five to 10 years,

Félix GarcÌa 00:58:47 Considering the advantages now and this movement we’re talking about? Perhaps we witness that the main challenge to be addressed in the next years can be the following. First of all, the standardization. So we need, for example, to talk about even terminologies that are not standardized. So we need standards in order to create this harmonization and to join forces in order to advance in the field. So perhaps ISO and IEE are expected to do some work on that in order to help every person to move towards sustainable software and specifically also to green software. The second one, we talk also about that measurement. We mentioned the maturity of the measurement of, for example, energy consumption is relatively low. We can say even perhaps we measure with hardware instruments. You need specialized infrastructure and specialized knowledge. And of course we measure with where is the measure even you need also specialized knowledge.

Félix GarcÌa 00:59:40 So at the end we have to work on that direction and also to provide developers with easier ways or for example, to automate these, for them to provide the results automatically for them, avoiding them this effort in the same way, for example, a programming language with high structural layer abstracts from developers. A lot of things. So perhaps our efforts also should be in that direction. Of course, when we advance with the measurement, also we can advance with the advance with the guidelines in the sense that more empirical studies are conducted. Practitioners even also can have real cases of application of different in order to see if they’re greener or not. So in the end, this empirical body of knowledge is expected also to grow. And it can be useful. As we also remark in this talk. There are not alls or solution for all, but perhaps we can build this empirical evidence in different contexts in order to help, in order to, we have to also advance in this sense. And finally, and not the least, we need the effort of the governments and efforts from professional and communities to the development of a green certification. And we need associated legislation for that. So this perhaps is, would have a great input for companies, especially in order to be more aware of the importance of building green solutions. And also to help in this sense.

Coral Calero 01:01:05 I think that little bit, more pessimistic than Felix, I think that if we don’t have legislation, we have a problem because to invest in green is to invest money. We have already talked about this. And if the industry don’t see the benefit in the short term, I think they will resist to the change. So we need this legislation and the European Union is doing efforts in this line also in the United States are doing things of related to the emissions of the technology and the software. So I think it’s mandatory to have this legislation and to put the industry to must do the things. It’s very important. And also another, for me, very, very important challenge for now right now is to give the green and sustainable software, its room. Educating the people, spreading the world, making the people from the industry aware of this problem and add the impact of the software to the discourse. We have a problem, and we need to handle.

Giovanni Asproni 01:02:09 Okay. Thank you very much. I hope it doesn’t sound too much of a kind of pessimistic closing. I think there is a lot of optimistic stuff we can think of, you know, with the progress he’s making. But I agree with you that it’s important that government do something to provide the appropriate frameworks and incentives for

Coral Calero 01:02:24 Yeah, we need to fight against the greenwashing, and we have a lot of greenwashing in industry. A lot of greenwashing. Yeah.

Giovanni Asproni 01:02:31 That is always the case with anything. Yeah, I think, yeah. Well anyway, I think at the end of the interview, I think we’ve done quite a great job to introduce greener and sustainable software. I hope that our listeners will come out with something they can do. Thank you very much Felix, and thank you for coming to the show. It’s been a real pleasure. Yes,

Coral Calero 01:02:51 Thank you. An invitation.

Félix GarcÌa 01:02:53 Thank you very much. We, we have enjoyed, enjoyed, we have enjoyed a lot of this
Speaker 0 01:02:57 .

Giovanni Asproni 01:02:58 Thank you. So, and this is Giovanni Asproni for Software Engineering Radio. Thank you for listening.

[End of Audio]

More from this show