Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
GreenDroid:A Tool for Analysing Power
Consumption in the Android Ecosystem
Marco Couto*¶, Jácome Cunha*§, João Paulo Ferna...
Going Green
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
2
+ =
Green Computing
 Caught the attention of many companies allowing them to save:
Informatics ‘ 2016 – Poprad greenlab.di.um...
Green Software
 Reducing energy consumption through software analysis and optimization
 Problem:
 How to analyze
 How ...
GreenDroid
 Power consumption model oriented
 Consumption per execution and program trace
 Predicts possible power-expe...
GreenDroid: Basic Workflow 6
Source
Code
Tests
Instrument
Source
Code
I
Tests
I
Build
APP
Tests
. Execution Trace
. Consum...
Power Consumption Model – Power Tutor
 Hardware components have states
 e.g., CPU has different percentages of usage
 E...
The Model as an API
 Power Tutor is an Android application
 Problem: cannot be invoked in other applications
 Solution:...
Instrumentation: Source Code
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
9
Source
Code
public class C1{
...
public v...
Instrumentation: Tests
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
10
Tests
public class TestSuite1{
...
public void...
Result Analysis
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
11
Power Consumption Graphics
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
12
Power Consumption Graphics
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
13
Power Consumption Graphics
Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
14
 Method classifications and analysis
tech...
Conclusions
 GreenDroid Tool
 Analyze power consumption of Android apps
 Detect possible power leaks
 Plan to extend G...
GreenDroid:A Tool for Analysing Power
Consumption in the Android Ecosystem
Marco Couto*¶, Jácome Cunha*§, João Paulo Ferna...
Upcoming SlideShare
Loading in …5
×

GreenDroid: A Tool for Analysing Power Consumption in the Android Ecosystem

510 views

Published on

Presentation @ Informatics 2015

  • Be the first to comment

GreenDroid: A Tool for Analysing Power Consumption in the Android Ecosystem

  1. 1. GreenDroid:A Tool for Analysing Power Consumption in the Android Ecosystem Marco Couto*¶, Jácome Cunha*§, João Paulo Fernandes‡, Rui Pereira*¶, and João Saraiva*¶ 1 Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt * HASLab/INESC ¶ Universidade do Minho, Portugal ‡ RELEASE, Universidade da Beira Interior, Portugal § Universidade Nova de Lisboa, Portugal {mcouto, ruipereira, jas}@di.uminho.pt, jacome@fct.unl.pt, jpf@di.ubi.pt
  2. 2. Going Green Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 2 + =
  3. 3. Green Computing  Caught the attention of many companies allowing them to save: Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 3 “close to 50% of the energy costs of an organization can be attributed to the IT departments” - [Harmon and Auseklis, 2009] “up to 90% of energy used by ICT hardware can be attributed to software” - [Standard, 2013]
  4. 4. Green Software  Reducing energy consumption through software analysis and optimization  Problem:  How to analyze  How to interpret  How to improve  In mobile devices, the interest is quite large  Battery lifetime is critical! Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 4
  5. 5. GreenDroid  Power consumption model oriented  Consumption per execution and program trace  Predicts possible power-expensive methods Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 5
  6. 6. GreenDroid: Basic Workflow 6 Source Code Tests Instrument Source Code I Tests I Build APP Tests . Execution Trace . Consumption . Execution Time *For each Analyzer Power Consumption Model Build Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt
  7. 7. Power Consumption Model – Power Tutor  Hardware components have states  e.g., CPU has different percentages of usage  Each state implies different consumptions  Idea: assign consumption to each component state  When monitoring consumption:  Check the components’ states;  Determine consumption using the power model Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 7
  8. 8. The Model as an API  Power Tutor is an Android application  Problem: cannot be invoked in other applications  Solution: transform the model into an API Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 8 1. traceMethod() 2. config() 3. start() 4. stop() Program trace Initializes Power Consumption Model Starts the power monitoring thread Stops the power monitoring thread
  9. 9. Instrumentation: Source Code Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 9 Source Code public class C1{ ... public void m1(){ Estimator.traceMethod(“m1”, “C1”); ... } ... } public class C1{ ... public void m1(){ ... } ... }
  10. 10. Instrumentation: Tests Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 10 Tests public class TestSuite1{ ... public void setUp(){ ... } public void tearDown(){ ... } ... ... } public class TestSuite1{ ... public void setUp(){ Estimator.config(“package”, _______android.os.Process.myUid(), this.getContext()); Estimator.start(); ... } public void tearDown(){ Estimator.stop() ... } ... ... }
  11. 11. Result Analysis Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 11
  12. 12. Power Consumption Graphics Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 12
  13. 13. Power Consumption Graphics Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 13
  14. 14. Power Consumption Graphics Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 14  Method classifications and analysis technique based on prior research  “Detecting Anomalous Energy Consumption in Android Applications” – SBLP’2014
  15. 15. Conclusions  GreenDroid Tool  Analyze power consumption of Android apps  Detect possible power leaks  Plan to extend GreenDroid approach to analyze other applications  Download at: https://github.com/greensoftwarelab/GreenDroid Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt 15
  16. 16. GreenDroid:A Tool for Analysing Power Consumption in the Android Ecosystem Marco Couto*¶, Jácome Cunha*§, João Paulo Fernandes‡, Rui Pereira*¶, and João Saraiva*¶ 16 Informatics ‘ 2016 – Poprad greenlab.di.uminho.pt * HASLab/INESC ¶ Universidade do Minho, Portugal ‡ RELEASE, Universidade da Beira Interior, Portugal § Universidade Nova de Lisboa, Portugal {mcouto, ruipereira, jas}@di.uminho.pt, jacome@fct.unl.pt, jpf@di.ubi.pt

×