Energy Wasting Rate a Metrics for Green Computing and Static Analysis Jérôme Rocheteau Institut Catholique d’Arts et Métiers, Nantes, France 2 nd International Workshop on Measurement and Metrics for Green and Sustainable Software Monday 5 th October 2015 Energy Wasting Rate MegSus | 2015-10-05 1 / 17
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Energy Wasting Ratea Metrics for Green Computing and Static Analysis
Jérôme Rocheteau
Institut Catholique d’Arts et Métiers, Nantes, France
2nd International Workshop onMeasurement and Metrics for Green and Sustainable Software
Cleansing: removing disturbed measurements ... before
Energy Wasting Rate MegSus | 2015-10-05 10 / 17
Measurement Protocol
Cleansing: removing disturbed measurements ... after
Energy Wasting Rate MegSus | 2015-10-05 10 / 17
Measurement Protocol
Pruning: removing disturbed measurements ... during
Energy Wasting Rate MegSus | 2015-10-05 10 / 17
Data Model
Measure• timestamp• amount
Instrument• identifier• version
Category• identifier• unit
Test• identifier• method
Unit• identifier• type
Implements
Platform• identifier• version
Environment• architecture• operating system• version
parent
class interface
Energy Wasting Rate MegSus | 2015-10-05 11 / 17
Statistical Analysis
List Interface Energy Consumption Analysis Requestselect uc.identifier, t.method, avg(m.amount), std(m.amount)from Measure minner join Test t on t.identifier = m.testinner join Unit uc on uc.identifier = t.unitinner join Implements ur on ur.class = uc.identifierinner join Unit ui on ui.identifier = ur.interfaceinner join Instrument i on i.identifier = m.instrumentwhere i.category = ’energy’and ui.identifier = ’java.util.List’group by uc.identifier, t.method with rollup
Energy Wasting Rate MegSus | 2015-10-05 12 / 17
Statistical Analysis
List Interface Energy Consumption Analysis Results
class method avg stddevArrayList add 16.45 6.33 %ArrayList get 13.49 2.48 %ArrayList new 17.46 4.48 %ArrayList 15.80 4.43 %LinkedList add 28.42 5.62 %LinkedList get 27.05 9.95 %LinkedList new 25.22 5.02 %LinkedList 26.89 6.86 %
Energy Wasting Rate MegSus | 2015-10-05 13 / 17
Case Study
LinkedList vs ArrayList Fibonacci’s Sequence
1 p u b l i c L i s t <I n t e g e r > f i b o ( i n t n ) {L i s t <I n t e g e r > l i s t = new L i n k edL i s t <I n t e g e r >() ;
/∗ L i s t <I n t e g e r > l i s t = new Ar r a yL i s t <I n t e g e r >(n ) ; ∗/f o r ( i n t i = 0 ; i < n ; i++) {
5 i f ( i < 2) {l i s t . add ( i ) ;
} e l s e {i n t x = l i s t . ge t ( i −1) ;i n t y = l i s t . ge t ( i −2) ;
Fine-Grained Measurements & MetricsInstrumented & (Semi) Automatized Process
Perspectives
Energy Wasting Rate Metrics ValidationTest-Case GenerationCross Analysis for Measurement of |e|Dependant Code Refactoring
Energy Wasting Rate MegSus | 2015-10-05 16 / 17
References
• Jérôme Rocheteau, Virginie Gaillard, et Lamya Belhaj.How Green are Java Best Coding Practices?Barcelona, Espagne.Markus Helfert, Karl-Heinz Krempels, et Brian Donnellan.Proceedings of the 3rd International Conference on Smart Grids andGreen IT Systems,pages 235–246.Barcelona, Espagne, Avril 2014.